Skip to content

Conversation

@regulus79
Copy link
Member

@regulus79 regulus79 commented May 16, 2025

This PR adds the ability for users to shift the contents of clips without changing the clip bounds. This is useful when working with vocal samples, and you want to chop them up and arrange them without having to manually resize and move the clip each time.

To use, hold Shift while dragging on a clip. For quantized movement, hold Alt or Ctrl at the same time.

2025-05-15.23-03-51.mp4

Note! Previously, Shift allowed users to drag clips while snapping their position to the global grid, while normal dragging would move them a quantized offset with respect to their current positions. This PR integrates that functionality into normal dragging, much like how #7477 integrated the Shift key for quantized knife position from to normal knife functionality.

Previously

  • Shift-dragging snaps the position of a clip to the global grid, so that either the start or the end of the clip is on the grid, whichever is closer
  • Normal dragging snaps the position of a clip to the closest quantized offset from its previous position.

Now

  • Shift-dragging moves the contents of a clip unquantized. Alt or Ctrl + Shift moves quantized.
  • Normal dragging mvoes and snaps the position of a clip so that either: the start of the clip is on a gridline, the end of a clip is on a gridline, or the clip is moved a quantized amount from its previous position, whichever is closer.

Additionally, I similarly combined Shift resizing into normal resizing, since it makes things much easier for beginners, and to make things more consistent.

@firiox
Copy link

firiox commented May 17, 2025

Sorry by the way.
I test It like the knife cuts in the closer grid then I had to test It and It cutted off the grid .

cutting.of.the.grid.mov

I just cutted It by default with the mouse and then used ctrl to cutt off grid and then I tested draggin with the pencil with alt then as I was writting this review I had to deliberate test It and It cutted off the grid. Anyway I tested the draggin the contents of the clip with My gosh.
It was with shift and then for draggin cuantized with alt and It do the trick. feel free to ask if you don't understand anything.
So I guess the issue isn't with this PR right? this is just for dragging the content right?

@firiox
Copy link

firiox commented May 17, 2025

I need help with the shift resizing bc I reziced the clip with shift and withou It and I don't see the trick

@regulus79
Copy link
Member Author

I test It like the knife cuts in the closer grid then I had to test It and It cutted off the grid .

Actually, I think it did, just relative to the end of the clip.

image

You can hold down the knife and drag it around to see where the cuts lines snap to. It will either snap to the global grid, relative to the start, or relative to the end.

I need help with the shift resizing bc I reziced the clip with shift and withou It and I don't see the trick

I might have worded the description badly. Basically in normal lmms, shift resizing snaps to the grid, and normal resizing quantizes the resize amount. But this PR combines shift resizing with normal resizing, so there shouldn't be a difference.

@allejok96
Copy link
Contributor

(First of all thank you @regulus79 for your work on the splitting midi clips, especially the non-destructable part. I didn't know how much I needed that until I tried it, thank you)

Now, I like the content shifting idea, but I see two problems:

Combined snapping for moving clips is terrible idea. Imagine I carefully placed a sample close to a grid line. Then I zoom out, do some work and then want to move it 4 bars ahead. It will be really hard to see what it snaps to. This should at least be configurable, like in piano roll where you have an nudge/snap option. Nudge should always be the default. As firiox demonstrated it's really hard to wrap your head around the logic when the options are combined.

Second issue is that nobody would ever know about this cool feature. Pressing a modifier is such an obscure thing. I see the source code is cluttered with modifier actions, that nobody except the people who designed them would know about. We need to stop adding these. Modifiers should be intuitive and consistent, like snap on/off, select or zoom.

To make this feature more discoverable it could be something like a handle that appeared on top of the waveform when the track height is big enough (you'll probably not use it unless you are zoomed in a little). And with that you wouldn't need to mess with combined snapping either.

bild

@regulus79 regulus79 added the gui label Jun 29, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants