Репозитории ALT
S: | 4.8.7-alt25 |
5.1: | 4.6.3-alt1.M51.1 |
4.1: | 4.4.3-alt1.M41.1 |
4.0: | 4.3.4-alt5.M40.1 |
3.0: | 4.0.1-alt1 |
+updates: | 4.0.1-alt2 |
+backports: | 4.2.3-alt7.1.M30 |
Группа :: Система/Библиотеки
Пакет: qt4
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
Патч: 0104-qpainter_vertical_center.diff
Скачать
Скачать
qt-bugs@ issue: none
applied: no
author: raabe
This patch fixes the qt_format_text helper used by QPainter so that it
computes the height of the overall text correctly. This means that
text drawn with the Qt::AlignVCenter flag will not appear correctly, a
little bit higher than it used to be.
Index: src/gui/painting/qpainter.cpp
===================================================================
--- src/gui/painting/qpainter.cpp (revision 450894)
+++ src/gui/painting/qpainter.cpp (working copy)
@@ -4676,7 +4676,7 @@
l.setLineWidth(lineWidth);
height += leading;
l.setPosition(QPointF(0., height));
- height += l.ascent() + l.descent();
+ height += l.height();
width = qMax(width, l.naturalTextWidth());
}
textLayout.endLayout();