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

question on local leader maps #1

Open
klooj opened this issue Mar 29, 2021 · 9 comments
Open

question on local leader maps #1

klooj opened this issue Mar 29, 2021 · 9 comments

Comments

@klooj
Copy link

klooj commented Mar 29, 2021

First of all, thank you. I've been wanting to corral my which-key lua hacks into a plugin but never got it together. I'm going to be implementing this tonight.

My question is, does this allow having individual local leader which-key popups that are unique to each filetype? so no more of this:
image

@klooj
Copy link
Author

klooj commented Mar 29, 2021

turns out my hacks were almost identical to this plugin. setup took 2 seconds and already so much better.

i have not figured out the buffer specific localleader popup guide though. local leader descriptions persist across buffers, unless they're changed to something else. I used wk.register_keymap('localleader', llmaps, {noremap = true, silent = true, bufnr = 0}). is this expected?

@AckslD
Copy link
Owner

AckslD commented Mar 30, 2021

Hi @klooj! Nice to hear that we found the same solutions :)

Hmm, that's strange. Indeed the intention is that that would setup keybindings only in the current buffer. I have to check what goes wrong. I'm away from my computer until Thursday so will check it then.

@klooj
Copy link
Author

klooj commented Mar 30, 2021

No rush. It was so easy to setup that I haven't done a proper deep dive yet. I may figure it out before then.

@AckslD
Copy link
Owner

AckslD commented Mar 30, 2021

Cool, let me know if you do :)

@AckslD
Copy link
Owner

AckslD commented Apr 1, 2021

@klooj I now understand the issue, which is for the descriptions, i.e. not the keybindings themselves. Do you know how this is normally handled by whichkey actually?

@klooj
Copy link
Author

klooj commented Apr 2, 2021

i'm not sure. whichkey did not handle this at all but then the last time i checked, like 6 months ago, a feature a branch was added to handle this specifically. so, i don't know the state of affairs right now.

@klooj
Copy link
Author

klooj commented Apr 3, 2021

just so we're on the same page, I framed my initial post as a question because this functionality did not yet exist in the wild, as far i know.

@famiu
Copy link

famiu commented Apr 4, 2021

I love the nvim-whichkey-setup plugin but this issue is really quite annoying. Would love if it was fixed soon.

@AckslD
Copy link
Owner

AckslD commented Apr 4, 2021

@famiu I definitely agree but this is not something we can really fix here but should be fixed in which-key itself. As mentioned by @klooj there is an open PR for this but not yet merged. Hopefully this will get merged soon. Whenever that happens I'll make sure to do any updates needed here.

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