LMMS / LMMS/lmms

Make sticky note resizing more consistent (i.e., shift+resize)

Open
#8,442 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
C++
Stars
10.4k
Forks
1.3k
Avg merge
2d 13h
Merged PRs (30d)
7

Description

Enhancement Summary

To preface, "sticky resizing" refers to resizing a note and having all notes past it shift relative by the amount resized. (I am using the same verbiage as in the code.)

Currently, there are two main ways to initiate sticky resizing:

  1. With one note selected, drag right side and hold shift
  2. With multiple notes selected, drag right side and hold shift and then ctrl (this order is important!)

This behavior is inconsistent, most forms of resizing break when ctrl gets held before shift, and it doesn't account for the alternate way of resizing notes by holding the note then pressing shift and dragging.

Instead, I propose that shift acts as an internal sticky resize and ctrl acts as an external sticky resize. (Currently, holding ctrl while in the process of resizing usually just breaks the resizing entirely with the cursor showing the select mode icon but doing nothing.) In other words, we can have this (where [NEW] represents features which weren't previously supported):

  1. With any amount of notes selected, drag right side and
    1. hold nothing to resize like normal
    2. hold shift to sticky resize internally
    3. hold ctrl to resize externally [NEW]
    4. hold shift and ctrl (in any order! [NEW]) to sticky resize both internally and externally (similar to current behavior except order of shift and ctrl isn't important)
  2. With any amount of notes selected, hold left click on one and
    1. hold right click (or something else like space?) to resize like normal
    2. hold shift to sticky resize internally [NEW]
    3. hold ctrl to sticky resize externally [NEW]
    4. hold shift and ctrl (in any order!) to sticky resize both internally and externally [NEW]

In effect, this would make the behavior more consistent and would add support for sticky resizing in more scenarios than before.

Implementation Details / Mockup

To implement this enhancement, figuring out what is causing ctrl to break things when pressed first/on its own would need to be investigated and resolved. Presumably, the rest can be handled by making some modifications to this code branch.

Please search the issue tracker for existing feature requests before submitting your own.
  • I have searched all existing issues and confirmed that this is not a duplicate.

Please note that I made a few edits shortly after posting this due to some flaws I noticed in my original proposal.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in src/gui/editors/PianoRoll.cpp around the sticky-resizing branch near line 3171, and reproduce the modifier-order behavior described in the issue. Use the listed drag and click combinations as acceptance criteria, including independent shift and ctrl behavior and either modifier order when both are held.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
desktop
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.