p-e-w / plotinus

A searchable command palette in every modern GTK+ application
1.02k stars 22 forks source link

Make shortcut configurable #4

Closed ishouldbedany closed 7 years ago

ishouldbedany commented 7 years ago

Ctrl-Shift-P requires three fingers and P is really far away from the other two keys, it doesn't feel natural. Maybe Ctrl-Space or, at least, a customization option (although I believe in sane defaults).

I don't think Ctrl-Space is used as a keyboard shortcut in the default GNOME install or in any GNOME app (I may be wrong, though).

p-e-w commented 7 years ago

The same shortcut is used by both Sublime Text and Atom, so I think it makes sense to keep it as the default.

However, I do intend to make the shortcut configurable in the future.

jaszhix commented 7 years ago

You can change the accelerator by changing this line, and recompiling. Chrome still doesn't work, or any other applications that overrides CTRL+SHIFT+P that I tested.

lf-araujo commented 7 years ago

Nope, the shortcut makes TOTAL sense... Congratulations to the developer!

p-e-w commented 7 years ago

@jaszhix: Chrome is not a GTK+ 3 application, so it's not expected to work. There are experimental GTK+ 3 builds, but even if they became the default Plotinus would still be unable to display any commands because Chrome's widgets are all custom, so there is nothing that can be automatically extracted.

A solution going forward might be to eventually augment Plotinus with a DBus API that can be used to provide commands. Then, a Chrome extension would pipe Chrome commands to Plotinus via the API, allowing the UI and filtering logic to be reused.

jhasse commented 7 years ago

There are experimental GTK+ 3 builds, but even if they became the default Plotinus would still be unable to display any commands because Chrome's widgets are all custom, so there is nothing that can be automatically extracted.

How does Ubuntu's Unity make the global menu work?

furquan-lp commented 7 years ago

How does Ubuntu's Unity make the global menu work?

Unity's global menu works with several diverse types of UI toolkits. As it works with GTK+ apps like Gedit or Nautilus, it also works with a Qt application like VLC or Kate; heck it even works with Java (Swing) applications (with jayatana enabled).

I would also like to point out that the shortcut also conflicts with Eclipse (Ctrl + Shift + P is used to find the matching bracket). But I guess that's kind of a moot point because Eclipse already has such functionality built-in (the Quick Access feature) though I don't use it because it cannot be dragged to the left.

screenshot from 2017-04-18 21-36-22

But I'm a little bit confused about the GTK3 application requirement since Plotinus works with LibreOffice (which afaik uses it's own UI) but doesn't work with Firefox (which apparently works very closely like a GTK3 application).

ryanleesipes commented 7 years ago

Making it configurable would be great. #9 raises a problem that seems to exist. Even though it doesn't work with Firefox, for instance, when Plotinus is enabled the shortcut in Firefox that is tied to that Ctrl+Shift+P doesn't work.

p-e-w commented 7 years ago

I am happy to announce that not only is the shortcut now configurable, it is configurable per application!

See the README for details. Don't forget that building Plotinus now requires sudo make install.