r15457 by jghali - #9333: Cursor doesn't jump to next line upon "soft-return"
scribus-commit
scribus-commit at lists.scribus.net
Mon Aug 30 01:42:50 CEST 2010
Author: jghali
Date: Sun Aug 29 23:42:50 2010
New Revision: 15457
URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=15457
Log:
#9333: Cursor doesn't jump to next line upon "soft-return"
Modified:
trunk/Scribus/scribus/canvasmode_edit.cpp
Modified: trunk/Scribus/scribus/canvasmode_edit.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=15457&path=/trunk/Scribus/scribus/canvasmode_edit.cpp
==============================================================================
--- trunk/Scribus/scribus/canvasmode_edit.cpp (original)
+++ trunk/Scribus/scribus/canvasmode_edit.cpp Sun Aug 29 23:42:50 2010
@@ -180,7 +180,8 @@
// Happens often when typing directly into frame.
// And the cursor curses nothing, vertigo.
textCursorPos = textframe->lastInFrame();
- if(textframe->itemText.text(textCursorPos) == SpecialChars::PARSEP)
+ QChar textCursorChar = textframe->itemText.text(textCursorPos);
+ if (textCursorChar == SpecialChars::PARSEP || textCursorChar == SpecialChars::LINEBREAK)
{
// The cursor must be moved to the beginning of the next line
FRect bbox = textframe->itemText.boundingBox ( textCursorPos );
@@ -211,7 +212,7 @@
dy += lineSpacing;
dy1 += lineSpacing;
}
- else if((textframe->itemText.text(textCursorPos) == SpecialChars::COLBREAK))
+ else if (textCursorChar == SpecialChars::COLBREAK)
{
// A bit tricky :)
// We want to position the cursor at the beginning of the next column, if any.
More information about the scribus-commit
mailing list