kando icon indicating copy to clipboard operation
kando copied to clipboard

Hide menu when shortcut is pressed while menu is visible

Open mway opened this issue 1 year ago • 1 comments

Description

Have been following this project for a while - it's looking great!

I think it would be nice if the shortcut toggled Kando's visibility. For example, given shortcut ⌃⌘R:

  1. Press ⌃⌘R, menu shows
  2. Press ⌃⌘R again (instead of selecting an item), menu hides

A really small thing but it's nice to not have to click the middle icon to dismiss the menu if I open it and then change my mind.

Affected Desktop Environments

All

Additional Information

No response

mway avatar Aug 03 '24 17:08 mway

Thanks for the suggestion! There are currently three ways for closing a menu without selecting anything:

  • Click the center item
  • Hit the Escape key
  • Right mouse button click

Especially the right mouse button is pretty convenient and gets into your muscle memory quite quickly. I guess we could add "pressing the hotkey again" to this list, but at the same time we would have to make sure that it does not interfere with Turbo Mode which may be quite challenging. So that people do not hide the menu by accident...

So it's pretty low on my priority list, but anyone is interested, feel free to add this feature! I can happily provide some pointers to the relevant source files.

Schneegans avatar Aug 04 '24 05:08 Schneegans

I thought a bit about this and I think that this is impossible to add without breaking turbo mode as it works right now. If you keep a shortcut pressed to use turbo mode, for Kando it looks like the shortcut was pressed again (as the initial shortcut was captured at OS level) and Kando now receives the key-repeat events.

Given all the other options to close a menu, it is also not that important, I guess.

Schneegans avatar Aug 23 '24 19:08 Schneegans