eclipse.platform.ui
eclipse.platform.ui copied to clipboard
Ctrl+3 (quick search): allow toggling options directly in the search dialog
IntelliJ has a really cool feature where you can toogle boolean options directly in the quick-search dialog: Low-priority, but I think this would really help with usability. The preferences dialog is harder to "mentally parse" than just clicking in the search-dialog
That's a very good idea. Adding a toggle widget in the table should be feasible relatively easily, the tricky part are to design some API to annotate that an entry is "toggable" and feed it with existing value; and the other part is for the provider to determine whether an entry is a boolean or not. Unfortunately, the preferences model in Eclipse is currently very weak: most preferences are not defined declaratively, we can't list them, get the type, the name, the description... Everything is coded in the UI.
The topic of declarative preferences has been a long desired improvement as it can improve usability trememdously (setting default values, having a preference search engine, generated widgets...). I don't think we need to break things, but probably just want to have a preferenceDescription in the org.eclipse.core.preferences extension point that would allow for a given preferenceId to set a name/type/description... that could be used in many places such as the one you're mentioning here.
I just wanted to note that OSGi has Metatype Service Specification for this purpose ... it is made for configurations but can be used for preferences as well as it is just a metadescription, e.g. if you use PID = preference node path. Beside that, the backing preference can be quiried already, basically there is a "settings node" and a "default" node, so one trivially could guess if the default note contains a key that is either true or false that this is a boolean preference (most likely).