Lock segment molding to an axis with Shift#4325
Conversation
When molding a path segment with the Path tool, holding Shift now constrains the drag to the dominant screen axis (purely horizontal or vertical), mirroring the direction-lock behavior of other drag operations. A "Lock Direction" hint is shown while molding. Closes GraphiteEditor#3760
There was a problem hiding this comment.
Code Review
This pull request introduces a "Lock Direction" feature when molding segments in the path tool. By holding the modifier key (Shift), the drag is constrained to the dominant screen axis (purely horizontal or vertical). Dynamic hints have also been updated to display this option. There are no review comments, so I have no feedback to provide.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
|
The implementation in #3766 is far more complete. It features overlays so you can see where you are aligning to (in your implementation the user just has to guess). It also does not offset the cursor position in such a strange way. |
Closes #3760
While molding a path segment with the Path tool, holding Shift now constrains the drag to a single axis (horizontal or vertical), matching the direction-locking behavior of other drag operations in the tool.
Behavior
Implementation
mold_handle_positionsgains alock_directionflag; when set, the incoming pointer position is snapped to the grab point's x or y before the drag delta is computed, so the segment moves purely along one axis.snap_angle(Shift) key state into the molding branch, where it was previously unused, and adds the corresponding hint.