Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shift up/down arrow does not slide rows #135

Closed
SteveJSteiner opened this issue Mar 20, 2018 · 2 comments
Closed

Shift up/down arrow does not slide rows #135

SteveJSteiner opened this issue Mar 20, 2018 · 2 comments

Comments

@SteveJSteiner
Copy link

shift left/right arrow slides columns the same as using H and L.
It would seem shift left/down/up/right arrow should be consistent with commands bound to uppercase H J K L.

From the help:
H J K L slide current row/column left/down/up/right

This was reproduced on a Mac, attempting to move rows in the column

@saulpw
Copy link
Owner

saulpw commented Mar 20, 2018

Hi @SteveJSteiner! Thanks for the report. This is a known issue, due to the Shift-Up/Down reporting inconsistent characters (on the Mac, I think they might even be indistinguishable from plain Up/Down). Which terminal are you using? If you can figure out how to get the terminal to emit any specific curses key for shift up/down (the last keypress is always displayed in the lower right status), you can put an alias() in your .visidatarc. Please comment again if you do find something that works, as you're not the only one with this issue.

@SteveJSteiner
Copy link
Author

Interesting. I'm using the default terminal. I think it is called terminal.app.
This worked for me:

https://github.com/google/terminal-app-function-keys provides mappings for a bunch of keys.
I added the shift up/down ones by hand in the 'preferences' for the terminal.app. (Took a second to realize I needed to hit ESC to get \033 in the UI.)
That changes what is emitted to 'Key_SR' and 'KEY_SF'.

Then following your suggestion above, I added this to .visidatarc:
alias('KEY_SR','K')
alias('KEY_SF','J')

saulpw added a commit that referenced this issue Mar 20, 2018
@saulpw saulpw closed this as completed Mar 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants