Prepare for exposing tool registration to the Python API.
- Generated tools can use their own prefix so naming collisions
won't happen between hard coded & generated tools.
- Add-on authors can use the add-on name as a prefix.
Currently the names match, renaming will happen next.
Tools can define a function that generates the tooltip using a function,
this takes the tools keymap as an argument which can be used
to extract keys to include in the tip.
bpy_extras were meant to be useful high-level helper functions for
script authors to perform common operations,
to avoid writing to verbose API's.
bpy_extras.keymap_utils contains some specialized API calls
mainly intended for Blender's own internal use.
Move keymap import export to internal API.
When the toolbar is accessed with modifiers (eg shift-space):
- Check if we can use the key without any modifiers to set the cursor.
- Pie-menu stile release event no longer checks for modifiers.
Both the active tools and selection are now on LMB, which leads to
various conflicts.
For that reason the LMB keymap now has a couple of differences
compared to before. These changes do not affect the RMB keymap.
* Context Menu: W -> RMB
* Select Tool activate: None -> W
* Set Cursor: RMB -> Shift+RMB
* Loop Select: Alt+LMB -> double click LMB
* Mask Feather Vertex Slide: Shift+RMB -> Ctrl+Shift+RMB
* Node Select: only with LMB now, no RMB
The idea behind the W key Select Tool shortcut is that various
tools can't be combined with selection, unlike the RMB keymap.
So this works as a quick shortcut to drop a tool
and go back to selection.
Tools: set Select Box tool as default, rather than Cursor.
This goes along with coming LMB select keymap changes,
where we want the user to be able to LMB click to select by default,
rather than set the cursor.
The cursor will still be directly setabble with shift+RMB.
For Blender builtin configurations the option to choose the select mouse remains
and is now also in the splash screen. It works by changing the keymap dynamically
in the script, rather than using special events.
The system of automatic switching of events was not flexible enough to deal with
side effects that require further keymap changes, so it is now under more manual
control in the script.
This breaks compatibility for some scripts and exported key configurations.
These can be fixed by replacing SELECTMOUSE, ACTIONMOUSE, EVT_TWEAK_S and
EVT_TWEAK_A with appropriate LEFTMOUSE, RIGHTMOUSE, EVT_TWEAK_L and
EVT_TWEAK_R events.
Other than that, there should be no functional changes.
While there is no support for dropping tools exactly,
the cursor tool supports a keyboard oriented workflow
which is often over-ridden by other tools key-maps
While many tools had shortcuts there was no fast way to get back to
the cursor tool.
Now double-tapping space sets the cursor tool
(as long as this tool doesn't have a key mapped).
- Vertex & weight paint now use the 'blend' setting.
- Weight paint now has it's own tool setting,
since weight paint doesn't deal with color - we'll likely
support different tools eventually.
Currently some modes share tool keymaps, we might want to disable
this since it's confusing editing one thing in multiple places.
However this should be resolved in the tool definitions.
- Add support for key_modifiers, so grease pencil gets "D".
- Assign number keys for unmapped items
This means all tools get keyboard access,
use number/numpad to avoid confusion with other keymap items
which directly activate the tool.