Bold, italic, underlined etc. applied to wrong selection; may lead to crash

• Mar 18, 2014 - 16:27
Type
Functional
Severity
S2 - Critical
Status
closed
Project

Steps:
1- Open attached file;
2- Double-click on the text;
3- Select the word "Long";
4- Press "bold" button, or Ctrl+B;
5- Repeat step 4 -> the word "Long" is still bold;
6- Repeat step 4.

Result:
result.png
Expected:
expected.png
It can lead to crash:
1- Open attached file;
2- Double-click on the text;
3- Select the word "Long";
4- Press "bold" button, or Ctrl+B;
5- Press "italic" button, or Ctrl+I -> other letters, not the selected ones, become bold;
6- Press Esc or click outside the text -> crash.

Windows 8.1, Nightly build e6a2034

Attachment Size
text_double_font_change.mscz 1.34 KB
expected.png 10.87 KB
result.png 11.2 KB

Comments

A typo in the previous steps:
5- Press "italic" button, or Ctrl+I -> other letters, not the selected ones, become bold italic;

It does not crash on my version which is around a week old. Also, I am using Ubuntu.
However, the text is not changed to italic/ bold either. No effect is seen whatsoever.

Status (old) fixed active

Unfortunately, the crash part is still active, because it is probably a different bug with respect to the "applied to wrong selection" part.
Steps:
1- Open previous file;
2- Double-click on the text;
3- Select the word "Long";
4- Press "bold" button, or Ctrl+B;
5- Without exiting text edit mode, press "italic" button, or Ctrl+I;
6- Press Esc or click outside the text -> crash.

Attached the log from gdb (from a personal build under Linux Mint).

Windows 8.1, Nightly Build 9cde62c.

Attachment Size
double_change_crash_log.txt 5.16 KB

Pressing Superscript on selected text (title, system text) always crashes for me. I can make it crash after some combinations including subscript.

No, I was able to make it fail on other random combinations, usually including subscript. The three normal ones (bold, italic, underline) do work better than yesterday.

I can still see the crash in a357ccb self-build under Windows 8.1 and Linux Mint 13.
It always crashes when using superscript.
It crashes when using bold, italic or underline + subscript (subscript alone works fine).
Attached the gdb logs for the superscript and bold+subscript cases.

In the superscript case at #6 of the log it says:
Ms::XmlNesting::popToken (this=0x7fffffffca90, t=0x1cfdde0 "sub")
shouldn't it be "sup" instead of "sub"?

Attachment Size
superscript.txt 3.82 KB
bold_and_subscript.txt 5.13 KB