Text edit mode: newline character can't be removed by Delete

• Jun 27, 2019 - 09:28
Reported version
3.2
Priority
P2 - Medium
Type
Functional
Frequency
Few
Severity
S4 - Minor
Reproducibility
Always
Status
closed
Regression
Yes
Workaround
No
Project
Tags
  1. Enter a text with a newline in it (any type will do, staff/tempo/title/...)
  2. Put the input cursor at the end of the first line
  3. Press Del

Expected result: The newline character is deleted
Actual result: nothing happens

Workaround:
Put input cursor at the start of the second line, press backspace.

Bug present in 3.1 & 3.2, probably all 3.x's are affected.
Regression compared to 2.3.2 where this does work as expected


Comments

Title [regression] Text: newline character can't be deleted by 'delete', only 'backspace' Text edit mode: newline character can't be deleted by Delete or by Backspace
Severity S4 - Minor S3 - Major
Workaround Yes No

OS: Windows 10 (10.0), Arch.: x86_64, MuseScore version (64-bit): 3.3.0.8267, revision: e36df56

In the above example, backspacing only apparently removes the newline character:

  1. Open the attached file.
  2. Create any text object in the frame.
  3. Type some text, then press Return and type a second line.
  4. Backspace through the text to remove the second line. The cursor should now be at the end of line 1.
  5. Press Esc to exit.
  6. Go back into text edit mode and navigate to the end of the line with the cursor keys.
    Expected result: The cursor stops at the end of the text.
    Actual result: The cursor can be moved one extra space onto a new line, albeit with a smaller line height.

This sheds more light on another issue: #292652: Blank lines of text consisting only of a RETURN are too small in height on some scores.

Attachment Size
newline_character.mscz 3.92 KB
Title Text edit mode: newline character can't be deleted by Delete or by Backspace Text edit mode: newline character can't be removed by Delete or Backspace
Title Text edit mode: newline character can't be removed by Delete or Backspace Text edit mode: newline character can't be removed by Delete

It's only at the end of a block that you cannot delete the newline. Newlines within the block can be deleted by backspace normally.

Fixed in branch master, commit e0d7245ab7

_Merge pull request #5875 from SKefalidis/text-delete

fix #291402: added the ability to delete \n using the delete key (duplicate, the old one was automatically closed for some reason)_

Fix version
3.5.0