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

why I can't bind ctrl-j to other command, the ctrl-j can only be {open: } #469

Open
0xnofoot opened this issue Dec 9, 2023 · 4 comments

Comments

@0xnofoot
Copy link

0xnofoot commented Dec 9, 2023

截屏2023-12-09 21 22 49

the ctrl+j doesn't work

@DLFW
Copy link
Contributor

DLFW commented Dec 16, 2023

I can reproduce the problem.
Seems like a bug.

I configured

keymap = [
...
  { keys = ["ctrl+k"], commands = ["parent_cursor_move_up"] },
  { keys = ["ctrl+j"], commands = ["parent_cursor_move_down"] },
...
]

ctrl+k does what is expected, but ctrl+j really opens the file.

I also tried the older version v0.9.5, which cannot parse my current configuration, and it it also opens files with ctrl+j.

@0xnofoot
Copy link
Author

yes,hope author could fix it

@kamiyaa
Copy link
Owner

kamiyaa commented Dec 19, 2023

Did a bit of research online and it appears that Ctrl+J is handled differently by readline/bash etc.

So to joshuto, it looks like you pressed enter.

@JosefLitos
Copy link

There are many ways and good libraries to handle term input correctly. If joshuto isn't using one or is using ncurses, than that is just unfortunate. Notcurses is a good example of a modern lib intended for tui apps.

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

4 participants