summaryrefslogtreecommitdiffstats
path: root/src/gui
diff options
context:
space:
mode:
authorAndy Shaw <andy.shaw@digia.com>2013-10-14 13:26:03 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-10-16 10:32:47 +0200
commit1f01ac832346fb217e7c07452673cd5f66cf4835 (patch)
tree8df6c4a038f863a897af4503bc694c9f85c7e117 /src/gui
parentd4d96c375df5e697f878b15548c1abff7e35ff08 (diff)
Restore handling of bullets for lists with a font size of > 36 pixels
This patch partially reverts ad443dfb1d8e9096c4913686aa2ed0bc9b3f5de7, the test that was added is still there as it can be used to compare against Chrome and to check that indenting works correctly. The original behavior of clipping the bullets is correct because the specified indent is where the text itself should be positioned, the bullet uses the available space to the side of it. This is how other web browsers handle the same situation. Change-Id: I63440e037d8efec356459c09228ef4817ccb9cb6 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/text/qtextdocumentlayout.cpp13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/gui/text/qtextdocumentlayout.cpp b/src/gui/text/qtextdocumentlayout.cpp
index 6156f56ae1..313700429c 100644
--- a/src/gui/text/qtextdocumentlayout.cpp
+++ b/src/gui/text/qtextdocumentlayout.cpp
@@ -1427,19 +1427,6 @@ void QTextDocumentLayoutPrivate::drawListItem(const QPointF &offset, QPainter *p
xoff = -xoff - size.width();
r.translate( xoff, (fontMetrics.height() / 2) - (size.height() / 2));
- // Prevent clipping the left side of the list decorator (on left to
- // right layouts) and clipping the right side of the list
- // decorator (on right to left layouts).
- if ((r.left() < 0) && (dir == Qt::LeftToRight)) {
- int horizontalOffset = -r.left();
- r.translate(horizontalOffset, 0);
- layout->setPosition(layout->position() + QPointF(horizontalOffset, 0));
- } else if ((r.right() > document->pageSize().width()) && (dir == Qt::RightToLeft)) {
- int horizontalOffset = r.right() - document->pageSize().width();
- r.translate(-horizontalOffset, 0);
- layout->setPosition(layout->position() - QPointF(horizontalOffset, 0));
- }
-
painter->save();
painter->setRenderHint(QPainter::Antialiasing);