Tweaking the curve#2217
Conversation
Added the following new tools to the piano roll toolbar: - Vertical Stretch Tool - Horizontal Stretch Tool - Vertical Shift Tool - Horizontal Shift Tool Added tooltips and icons corresponding to these tools, and updated the settings in PianoRoll.axaml, Strings.axaml, and PianoRollStyles.axaml. Implemented the behavior of the new tools in PianoRoll.axaml.cs and extended the ExpCanvasPointerPressed and ExpCanvasPointerMoved methods. Added logic to CurveViewModel.cs to support the new tools. Implemented the TryGetSelection method to retrieve the selection range. Added new state classes to NoteEditStates.cs and implemented editing logic (move, scale) for each tool.
|
Would it be possible to add a setting to ignore any values that are 0/default when using the shift tools? |
|
@nagotown If you don't want to move the default values, I think it's best to simply not select them. As for the behavior of the selection, I haven't made any specific changes to it, so it remains exactly as it was when the curve selection feature was first added. |
|
The reason why I wouldn't just select very specific parts is related to the last part of my reply. It's a bit of a hassle with the grid snapping. By the way, could you check my PR on this branch? |
fixes icon display
|
@nagotown |
Introduced the DefaultSnapCurve property to allow the Snap Curve to be enabled by default. This setting has been implemented in Preferences.cs, PreferencesViewModel.cs, and NoteEditStates.cs, with a new localization key added to Strings.axaml for the UI.
New curve editing tools have been added to the piano roll.
The following tools have been newly added to the piano roll toolbar:
Icons and tooltips for these tools have been added, and the settings in PianoRoll.axaml, Strings.axaml, and PianoRollStyles.axaml have been updated accordingly.
Additionally, the behavior of the new tools has been implemented in PianoRoll.axaml.cs, with extensions to the ExpCanvasPointerPressed and ExpCanvasPointerMoved methods.
In CurveViewModel.cs, logic to support the new tools has been added.
The TryGetSelection method has been implemented to retrieve the selection range.
In NoteEditStates.cs, new state classes have been added, and the editing logic (movement and scaling) for each tool has been implemented.
An option to turn off the default snap function for curve selection has been added to Preferences.cs.
Previously, this could be disabled by turning off the Note snap function. However, since some users may not require snapping during selection, a separate setting has been added to allow it to be turned off individually.

The snap function was originally introduced because the selection feature was designed to snap to the grid, matching the specification where curve pasting operations are performed along the grid.