]> git.pld-linux.org Git - packages/qt4.git/blame - qt4-git.patch
- rel 7; upstream fix for bugs visible in kate and okteta
[packages/qt4.git] / qt4-git.patch
CommitLineData
192f85ce
AM
1commit ca89c49fa2c5cbb3945897046f33eed9f7da846c
2Author: Jiang Jiang <jiang.jiang@nokia.com>
3Date: Tue Jul 3 10:17:49 2012 +0200
c37e4a41 4
192f85ce 5 Fix cursor truncate to include line position
c37e4a41 6
192f85ce
AM
7 Since we could have moved the line position (QTextLine::setPosition),
8 the truncating position should be adjusted with that.
c37e4a41 9
192f85ce
AM
10 Change-Id: Ie1acd4a1b6a4adfbeeb9ce8ee2dfa19d992470e8
11 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
c37e4a41 12
192f85ce
AM
13diff --git a/src/gui/text/qtextlayout.cpp b/src/gui/text/qtextlayout.cpp
14index 16f7150..52f2793 100644
15--- a/src/gui/text/qtextlayout.cpp
16+++ b/src/gui/text/qtextlayout.cpp
17@@ -2616,8 +2616,8 @@ qreal QTextLine::cursorToX(int *cursorPos, Edge edge) const
18 x += eng->offsetInLigature(si, pos, end, glyph_pos);
19 }
c37e4a41 20
192f85ce
AM
21- if (eng->option.wrapMode() != QTextOption::NoWrap && x > line.width)
22- x = line.width;
23+ if (eng->option.wrapMode() != QTextOption::NoWrap && x > line.x + line.width)
24+ x = line.x + line.width;
c37e4a41 25
192f85ce
AM
26 *cursorPos = pos + si->position;
27 return x.toReal();
This page took 0.048278 seconds and 4 git commands to generate.