mirror of
https://github.com/blender/blender
synced 2026-11-22 03:45:13 +03:00
This PR refactors the blade tool from the ground up to improve its capabilities and make it more useful. New features: - Split visualizers: line for blade, region for box blade - Custom tooltips with frame values - Split all channels with Shift, ignore connected with Alt - Quick `C` keybind to switch (see: !164536) - Pressing activates, releasing it returns to the previous active tool - `C` for circle select is still present in the preview. This select type only really makes sense there anyways, as the original rationale given in !141422 concerned preview image origins. - When hovering, show split frame in preview - This can be toggled with `View > Preview Edit Point`, which was renamed from the old `Show Transform Preview`, since it affects more than just handle transform now - Properly expose all properties in tool settings rather than confusingly combining split and box blade properties. Python Changes: - The `ignore_selected` property has been deprecated and replaced by `only_selected` (its inverse) to improve clarity. The old property will not be removed from the API until 6.0. - The `only_selected` is forced off by default for both box blade and split. - As a result, calling `split` in a Python script without any arguments now defaults to splitting everything at that frame; pass either `ignore_selected=false` or `only_selected=true` to override this. Shortcuts are not affected. On code architecture: - Implementation uses a gizmo group that registers a paint cursor, and sets a free callback for it. - This also adds a new function for creating custom tooltips, `tooltip_create_from_func`. - I have rearranged some code in `wm_draw.cc` to make popups (tooltips) draw above gestures, so that the box gesture does not draw over our tooltip; I checked that this did not regress any draw cases. This also addresses and fixes all concerns in #110835. Pull Request: https://projects.blender.org/blender/blender/pulls/161031 |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| io.py | ||
| keymap_from_toolbar.py | ||
| keymap_hierarchy.py | ||
| platform_helpers.py | ||
| versioning.py | ||