Skip to content
This repository has been archived by the owner on Aug 8, 2021. It is now read-only.

Word-jump with ctrl+cursor keys #21

Open
dromer opened this issue May 9, 2021 · 12 comments
Open

Word-jump with ctrl+cursor keys #21

dromer opened this issue May 9, 2021 · 12 comments

Comments

@dromer
Copy link

dromer commented May 9, 2021

What do you want

Jump words in the text-field

Why

Most text editors, terminals and chat clients allow this. And it allows for much easier editing.

@yellowsink
Copy link
Collaborator

Which terminal are you using?

@dromer
Copy link
Author

dromer commented Jun 16, 2021

Terminator, but I run the client on a remote server inside tmux.
I now realize that it does work outside of tmux. Interesting.

In tmux I use the set-window-option -g xterm-keys on setting to enable this. However it seems this conflicts with gord somehow?

@yellowsink
Copy link
Collaborator

Does your setup actually allow ctrl-arrows to reach Gord? I know for example that ctrl-shift-arrows to select words works on everything except Kitty - Kitty reserves ctrl-shift for its own shortcuts.

@dromer
Copy link
Author

dromer commented Jun 16, 2021

I use ctrl+arrows in irssi and my editors. I don't see why they wouldn't reach gord as well?

@yellowsink
Copy link
Collaborator

I wonder if tmux uses it for switching panels or something hmm.

Hold on imma do some testing.

@yellowsink
Copy link
Collaborator

ok i think i know whats happening - the terminal's escape codes for left and right are not understood by tmux?

image

@yellowsink
Copy link
Collaborator

I know I had issues with this exactly in zsh for a while. Perhaps that's the reason?

@dromer
Copy link
Author

dromer commented Jun 16, 2021

I don't use zsh, but regular old bash (5.0.3(1)-release)

@yellowsink
Copy link
Collaborator

Yeah but my point is that perhaps tmux is simply not understanding the word-left and word-right signals sent by the terminal. This is usually a localisation issue.

@dromer
Copy link
Author

dromer commented Jun 16, 2021

Hmm, well set-window-option -g xterm-keys on should fix this (which it does for everything else, like bash, vim, irssi)

@yellowsink
Copy link
Collaborator

Weird.

@dromer
Copy link
Author

dromer commented Jun 16, 2021

Hmm, I think that sends different key codes: https://github.com/SynologyOpenSource/tmux/blob/master/examples/xterm-keys.vim (<< not actual tmux source-code though)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants