The old editor settings API allowed adding Settings.Filter implementations that modules could use for tweaking setting
values supplied by modules through settings initializers. While this is usually not needed there is the jVi plugin that
relies on this functionality for installing special keybindings.
We should find a suitable way for supporting this in Editor Settings and Editor Settings Storage APIs.
Some things to consider
- The set of keys that jVi binds is dynamic. Tools>Options>... is used to specify which keys jVi should catch.
- Only CTRL keys and single modifier keys typically on keypad are available for selecting.
- Keys not caught by jVi "pass through" to the option selected keypad profile.
- There is a jVi checkbox in Tools, so the jVi keybindings are inserted when needed.
- NB's default key typed action has magic and must be used. jVi goes through gyrations to get hold of it, then relay
events to it as needed.
Some design/implementation details are in the email thread
http://www.nabble.com/jVi-as-KeyBindings-instead-of-extending-EditorKits-tf3281472.html#a9127667 . This thread gives
some insight into how things developed the way they are.
Catching the key events elsewhere in the delivery pipeline migh be tricky to avoid interfering with NB.
Other approaches to catching the events and/or to adding jVi's keybindings is certainly possible. It does seem that it
needs to be a "NB" supported API since there are a variety of NB specific requirements. I don't have much GUI, Swing or
NB deep experience, but I will contribute as I can in examining/considering alternatives.
This will undoubtedly be the trickiest part of porting jVi to nb6.5.
Though this issue is mentioned in issue #90403 there doesn't seem to be anything concrete. Any ideas about this? Is
there something I can or should be doing to find a resolution for this (difficult considering my limited available time).
I'll generate and attach here the javadoc of StorageFilter. But basically you can hook into loading settings (eg.
keybindings) and add/remove/modify them as you like. StorageFilter has two methods afterLoad(), beforeSave(), which
allow intercepting both loading and saving. So filters can undo whatever they have done before settings are persisted to
Should be resolved in 7.0.
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.
Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss