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

Can we avoid reserving <F24>? #26

Open
wookayin opened this issue Jan 22, 2020 · 1 comment
Open

Can we avoid reserving <F24>? #26

wookayin opened this issue Jan 22, 2020 · 1 comment

Comments

@wookayin
Copy link
Contributor

wookayin commented Jan 22, 2020

In the plugin code,

" When Tmux 'focus-events' option is on, Tmux will send <Esc>[O when the
" window loses focus and <Esc>[I when it gains focus.
exec "set <F24>=\<Esc>[O"
exec "set <F25>=\<Esc>[I"

where we have a normal map

nnoremap <silent> <F24> :silent doautocmd <nomodeline> FocusLost %<CR>
nnoremap <silent> <F25> :doautocmd <nomodeline> FocusGained %<CR>

However, I would like to use <F24> for another mapping. In some terminals (e.g. xterm-256color) & neovim environments, <F24> is <Shift-F12>. As this plugin reserves for <Esc>[O, I cannot map custom commands to <Shift-F12>. Is the choice of or compulsory, or can we use another special key sequence?

@wookayin
Copy link
Contributor Author

wookayin commented Jan 22, 2020

In vanilla vim, <F24> and <Shift-F12> are recognized differently (this might vary depending on TERM). However in neovim they are treated same. So for neovim, I can currently work around by simply not using this plugin (See #1).

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

1 participant