Crash after adding text then exiting edit mode with no text
Reported version
3.0
Priority
P1 - High
Type
Functional
Frequency
Once
Severity
S2 - Critical
Reproducibility
Always
Status
closed
Regression
Yes
Workaround
No
Project
- default score
- click first rest
- Ctrl+T
- Esc without entering text
Result: you can see that the empty text element still exists and is selected according to Inspector, even though it has been removed from the score. Probably multiple ways to crash at this point, one is to press Alt+Right.
Comments
OS: Windows 10 (10.0), Arch.: x86_64, MuseScore version (64-bit): 3.0.0.4839, revision: cf1f5ce
I cannot reproduce the crash right now (Alt + Right, or a few others). Only with debug build maybe.
can't reproduce
Interesting, for me it crashes reliably on the actual release as well as my own builds. I take it, though, that after pressing Esc you still see the Inspector showing the text still selected?
Which text? I didn't enter any and your instructions didn't imply that? So no, nothing is seen after Esc.
Oh, yes, Inspector still shows the text part and I can easily imaging this to cause a crash later. Id doesn't for me though (Self built, MinGW)
Right - when you press Ctrl+T, t creates an empty text element, and it is selected, so the status bar and Inspector reflect that fact. When you hit Esc, the text element is removed from the score but remains selected, as shown in both the Inspector and status bar, and for me at least, the crash ln Alt+Right is reproducible in the release. Anyhow, originally this was blocking me from completing something else, but I got past that.
In reply to Right - when you press Ctrl… by Marc Sabatella
I got it too with Alt + right.
But only on my desktop Win7 (not with the laptop Win10, and same nigthly: cf1f5ce, don't know why !)
crashes like this don't surprise me too much if they are only sometimes reproducible.
The easy fix is to make sure we deselect this empty text element. What I don't know is if there are deeper problems too though - like if there are other pointers to it somewhere, if it is truly gone or somehow still represented on the "undo" stack, etc.
I'd like to pick up this issue.
PR #4742 created: https://github.com/musescore/MuseScore/pull/4742
Fixed in branch master, commit 82b16643cb
_fix #280878: adding vector empty check in function Ms::Segment::nextAnnotation(Ms::Element * e).
Fixed issue #280878 by adding vector empty check in function Ms::Segment::nextAnnotation(Ms::Element * e)._
Fixed in branch master, commit ea8da9edab
_Merge pull request #4742 from ylink-lfs/fix-empty-textbox-bug
fix #280878: by adding vector empty check in function Ms::Segment::nextAnnotation(Ms::Element * e)._
Fixed in branch 3.0.5, commit 82a0f717dd
_Merge pull request #4742 from ylink-lfs/fix-empty-textbox-bug
fix #280878: by adding vector empty check in function Ms::Segment::nextAnnotation(Ms::Element * e)._
Automatically closed -- issue fixed for 2 weeks with no activity.