Unicode surrogate-pair text cutting and pasting and undoing produces corruption
Text edit code is not correctly aware or doesn't properly handle surrogate pairs always.
Edit: the description that follows I've split off as a separate issue #280522: TextEdit edit mode lost after undo...shouldn't be deselected as I've determined that issue isn't even related to surrogate pairs. So disregard the rest of this description:
Was making a christmas tree out of different ways to say happy new year, but discovered that a cut and undo for some unicode would produce corrupted text.
1. Open unicode test.mscz
2. Select this line:
- Cut via ctrl->x.
- Paste it in the space above.
- Undo with ctrl->z twice.
- Reselect that line
- Cut again via ctrl->x.
Result: That cut line is replaced with an up arrow:
That character shouldn't be there. Also doing some other operations with undo will produce similar unusual characters.
I think this might be a residual part of one of these high & low surrogate pair characters being detached from it's partner and unintentionally left behind or produced.
On 3.0 release candidate OS: Windows 10 (10.0), Arch.: x86_64, MuseScore version (64-bit): 220.127.116.1147, revision: 96c1f7b