The logic was wrong and could cause crashes
Fixes bug #11777.
return;
// If cursor position is after the deletion place update it
+ // but if we are not at start of line keep it after the space that was kept.
if (cur.pos() > from)
- cur.pos() = max(from + 1, cur.pos() - num_chars);
+ cur.pos() = max(from + (from > 0), cur.pos() - num_chars);
// Check also if we don't want to set the cursor on a spot behind the
// pagragraph because we erased the last character.
- Avoid crash in some cases where a dialog is shown during operation
(bug 11763).
+- Fix crash with nested insets when spaces are removed automatically (bug 11777).
+
* INTERNALS