diff options
Diffstat (limited to 'framework/src')
-rw-r--r-- | framework/src/domain/documenthandler.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/framework/src/domain/documenthandler.cpp b/framework/src/domain/documenthandler.cpp index d9a17e34..b4ddc24c 100644 --- a/framework/src/domain/documenthandler.cpp +++ b/framework/src/domain/documenthandler.cpp | |||
@@ -299,6 +299,8 @@ void DocumentHandler::contentsChange(int position, int charsRemoved, int charsAd | |||
299 | QTextCursor cursor = textCursor(); | 299 | QTextCursor cursor = textCursor(); |
300 | cursor.setPosition(position + charsAdded, QTextCursor::KeepAnchor); | 300 | cursor.setPosition(position + charsAdded, QTextCursor::KeepAnchor); |
301 | cursor.mergeCharFormat(*m_cachedTextFormat); | 301 | cursor.mergeCharFormat(*m_cachedTextFormat); |
302 | //This is somehow necessary, otherwise space can break in the editor. | ||
303 | cursor.setPosition(position + charsAdded, QTextCursor::MoveAnchor); | ||
302 | } | 304 | } |
303 | m_cachedTextFormat = {}; | 305 | m_cachedTextFormat = {}; |
304 | } | 306 | } |