qt5base-lts/tests/auto/gui/text/qfontmetrics
Bernd Weimer d641792ff2 Fix QFontMetrics width
Commit f4dd534 introduced a regression, so that QFontMetrics reported
a wrong size (to be more specific width) for FreeType fonts.
The calculation of glyph advances has to to reflect (rounded)
integral number of pixels. This was only done when the glyph was cached.
So in some cases the first call to QFontMetrics::size gave a different
result than the second.
This patch reverts f4dd5344fb.

The tst_QFontMetrics::same auto test only happened to work on some
platforms, on BlackBerry for instance it did not. Extended the test
case to make sure it works for different font sizes.

Change-Id: Ia5bb9abd3ff98193c9bba048b85207672ed8d9c3
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2014-02-20 20:13:27 +01:00
..
.gitignore Moved gui autotests into new directory structure 2011-09-01 10:59:49 +02:00
qfontmetrics.pro QtGui tests: Remove DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0 2013-03-27 03:54:42 +01:00
testfont.qrc Moved gui autotests into new directory structure 2011-09-01 10:59:49 +02:00
tst_qfontmetrics.cpp Fix QFontMetrics width 2014-02-20 20:13:27 +01:00
ucs4font.ttf Moved gui autotests into new directory structure 2011-09-01 10:59:49 +02:00