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

Selecta could/should allow use of up/down arrows #81

Closed
purpleidea opened this issue Mar 3, 2015 · 7 comments
Closed

Selecta could/should allow use of up/down arrows #81

purpleidea opened this issue Mar 3, 2015 · 7 comments

Comments

@purpleidea
Copy link

Not sure if this is entirely within scope, but I think it would be quite natural:

When running selecta, allow up/down key presses to navigate up/down the list of displayed items. Useful to pop "down" one or two, and press enter to select.

HTH

@rschmitt
Copy link
Contributor

rschmitt commented Mar 3, 2015

#76
#71
#15

@purpleidea
Copy link
Author

@rschmitt woops. Sorry for the noise...
So after reading a bit... Is this supposed to work now or not?

@rschmitt
Copy link
Contributor

rschmitt commented Mar 3, 2015

No. I believe it was supported for a brief period, but that support was dropped due to inconsistent behavior on different platforms (sometimes it worked, sometimes it didn't). Ctrl-N and Ctrl-P have always worked, however. There is an open issue on a Selecta clone (felipesere/icepick#27) that has proposed the tab key as an alternative to the down arrow.

@purpleidea
Copy link
Author

@rschmitt Then this issue is valid :) The arrow key processing requires that you way a small delay to see if other chars come in. I haven't implemented this recently, but I can dig up some old python code if needed. If OSX is doing something dumb, then we should ignore that, or just switch based on $TERM or similar...

@rschmitt
Copy link
Contributor

rschmitt commented Mar 3, 2015

Are you also aware of the cursor mode issues discussed in #76 (comment)?

@purpleidea
Copy link
Author

@rschmitt I did see this yes. Sounds like there's a bug in here or rather in some lib somewhere... I don't have a patch to offer (sorry) but +1 to whoever fixes this :)

@garybernhardt
Copy link
Owner

The bug is in the design of the VT100 protocol. ;) ESC means multiple things and the only way to distinguish between them is by waiting and guessing. Selecta does VT100 for output, but not for input, because I don't want to (1) maintain code for input escape codes, or (2) depend on a giant library from the 80s. Fortunately, ^P and ^N work everywhere in Unix (even in Vim!), so switching to them is a good idea anyway.

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

3 participants