-
Notifications
You must be signed in to change notification settings - Fork 4
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
Keymaps #10
Conversation
Looks great! The problem you mention about some keys no longer working, like |
Never mind my remark about the native_key stuff. Just checked the issue you linked too. Need to figure out what I'll do with that :) |
@folke Yeah that settings indeed works for things like |
end | ||
local textmap = textmaps[leader_type] | ||
setup_keymap(mode, {key}, keymap, textmap, opts, bufnr) | ||
local textmap_key = initial_key..'_'..mode |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we probably should add in bufnr
here is well if it's defined in opts
. Will be needed once the upstream PR with buffer local which-keymaps is merged.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good point @folke! I guess in most cases people would set bufnr = 0
to use the current buffer. But I'm wondering how to handle other cases. Since if we store the buffer number in textmaps
then what if the buffers change? Or do buffer numbers persist in a session? Any thoughts?
Some changes based on PR #9 by @folke