Lock element feature

• Apr 4, 2015 - 13:16

On various occasions I have been burned when I accidentally selected and moved a note or group of notes or some other type of element without realizing it.

In a previous stage of my life I was proficient at using a CAD program called Microstation. It had a feature that allowed you to lock graphical elements, or a selection set of elements . Once locked, an element could not be modified. The element could be selected and unlocked, however.

I wonder if this could be a valuable feature for a future version of Musescore?

The upside was that you were protected from accidentally / unwittingly changing something that took perhaps months or years to create.

The only gotcha in locking an element that I ran into was forgetting elements were locked and the resulting frustration. There was no visible cue that elements were locked.


There was work on a feature to lock the entire score, but it wasn't quite ready to go for 2.0. That to me seems simpler and more generally useful, although no doubt, there might be times when locking just particular elements could be useful as well.

In reply to by [DELETED] 1831606

Unfortunately concert pitch isn't just a "view"; it necessarily changes your score in significant ways, recalculating all the notes, perhaps also making some measures wider or narrower and thus changing the page layout etc. So it has to have undo implications or very very bad things happen - making a change in mode and undoing in another often won't make sense because the change has no counterpart in the other view.

I'd settle for being able to limit mouse action. Too often I click on a score (maybe after zooming in on a PDF file) and place a note by accident or I drag an element when I meant to just move the score. I would propose that the user can select whether the mouse behaves as at present or whether another key [e.g. Shift or Ctrl] has to be pressed in order for the mouse to place a note or drag or change an element. I would still allow double-clicks to behave as at present as it is much more difficult to accidentally double-click than it is to single-click.

In reply to by underquark

Re: too often I click...
Me too. And that is what prompted this request. Locking the whole score as Marc suggests could help. But I am thinking it would help more to lock parts that are complete while I am working on parts that are not. That could be sections of music that are locked, or lines of music, or both. I don't think Marc describes what I am asking for

The CAD software I described essentially prevented locked elements from bring selected. That was generally but not always done via the user interface.

Note that I don't actually expect to get what I am asking for. But one can hope.

+1 on this request, but I think our developers might want some clarity on what the users need...

If we lock an element, we should be to select it, but not make any mouse or keyboards edits, I'm sure. If we want to edit, we should press the assigned hotkey or select "Unlock" from a menu.

Does lock mean it locks to the page? To the staff? To the text box? To the assigned note? Is it possible to make it a "smart lock?" So for example an embedded graphic might lock to the page, but a staff mark locks to the measure, no?

Would locking an element still be affected by MuseScore's layout recalc algorithms?

In reply to by harbinger

I think there is only one natural / implementation interpretation of "locked" for an element - it means it cannot be manually dragged / moved with arrow keys. It would still be attached to whatever it is currently attached to, be that a note, measure, or frame. It would still move automatically when the layout changes. You would simply be prevented from dragging it or moving it with the arrow keys.

This much would be pretty simple. Not sure anything else would be anything but a giant can of worms for little additional benefit.

In reply to by Marc Sabatella

I don't think arrow keys are really the problem here. My guess is that most of the problems about undesired changes in element positions are caused by mouse drag. And probably the majority of the cases while dragging the score view to move in the score. Using scroll wheel and shift scroll wheel is already a valid workaround and I think we should advertise it at the first way to move the score view.

We could implement a complex lock feature for each element, but I think it would be underused and it will generate frustration when someone receive a "locked" score.

We could protect drag to move the score view with a modifier key. But doing it by default would be a pain for people who are cautious on where they click before dragging. So eventually, we could have preference option to protect drag move with a modifier key.

In reply to by [DELETED] 5

FWIW, I accidentally move notes and text with the cursor keys more often than I'd like - unlike other elements, these don't require a double click first to enable the cursor keys. I accept this as my fault, but still, I can see the value of a lock feature that prevents this as well.

Anyhow, the lock feature as originally proposed was something a bit different - the ability to lock a portion of the score while still allowing work elsewhere. As I said originally, this seems to be of limited value compared to something that solves the more common problem of simply not wanting to accidentally alter *anything*, but I was responding to the musings about how it might work if implemented.

I agree that this is not much of an issue in practice if you are in the habit of using the scroll wheel (or touchpad equivalent). But it seems to me that even if we had a preference to make it harder to drag the score, that doesn't solve the problem that you might accidentally drag a note or symbol anyhow. It maybe makes it less likely, once you realize the "lock" is in place, that you will try dragging without the modifier key, but I think it would still be easy to forget.

All my problems in this regard result from trackpad scrolling/moving when in "note entry mode", and I accidentally "touch" and an unfortunate note is dropped somewhere. I'm not sure what the best solution is.

In reply to by Marc Sabatella

My own sense is that it is impossible to solve ALL situations happening through user accident, whether caused by haste or poor devices.

I am happy this issue was raised, and apparently there may come a new "feature" based on it, but it seems to me that there are some things, such as care, that people just have to control.

In a way this reminds me of the difficulty selecting notes when zoomed out too far. There is a solution without increasing the size of the selectable area.

I have a slightly different take on this. I create scores which I want to share with a group of people that I sing with-- but I want to prevent anyone from "accidentally" changing the (finalized) score, such that they no longer are all looking at the same music! Is there a way to "completely lock" (as in "make no note changes to") a score? I wouldn't mind saving a "distributed score" under a separate version number, but right now, I can't figure out how to "lock a score" at ALL.

I'm still somewhat of a "newbie" to MuseScore, so maybe there is a simple way to do this, but when I search under "lock", "block", "prevent edits", etc, nothing pops up.


In reply to by Marc Sabatella

Hi, Mark-- That doesn't solve my issue. I want the singers to be able to "listen to" the scores in addition to just reading them. A PDF file can't do that (can it?) MuseScore is a GREAT tool for helping "slower learners" learn their parts (especially since they can increase the volume for their part using the mixer). Listening to the score also helps the memorization process.

Do you still have an unanswered question? Please log in first to post your question.