diff options
author | Jiang Jiang <jiang.jiang@nokia.com> | 2011-09-22 14:23:29 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2011-09-23 10:48:37 +0200 |
commit | 8b4e40f5354ef81c40d8da35e0e79b2a87278e31 (patch) | |
tree | 4a6efda2e6a3de84668199752107ae72f795e778 /tests/auto/gui/text/qrawfont/tst_qrawfont.cpp | |
parent | 9ee53afb32cc1bea6f60f4ca7a951330a979c04a (diff) |
Support adding application fonts with QFontconfigDatabase
QFontDatabaseQPA should be able to reinitialize database and
reregister all the fonts when an application font is added, because
it will trigger db->invalidate().
Add cloneWithSize support to QFontEngineBox so that even no usable
font is found in QFontDatabase, QRawFont::setPixelSize can still
work (without making the result rawfont invalid).
Register application fonts with QFontconfigDatabase, the code is
adapted from QFontDatabaseX11.
Reenable QRawFont tests for QPA, these usages are now supported in
QPA.
Fix QStaticText tests, raster in QPA does support transformations.
Translate the text before ZAxix rotation so that it will be visible
in canvas.
Add back fixedPitch support to QPA, and fix QFontDatabase tests.
Fix QGlyphRun tests, ignore non-existence glyphs in alphaMap
locking.
Fix QFontMetrics tests.
Task-number: QTBUG-21415, QTBUG-20754, QTBUG-20977,
QTBUG-20976, QTBUG-20760, QTBUG-20759
Change-Id: I24aea7d6ec6b2ac6342134d1f2591327c23a692b
Reviewed-on: http://codereview.qt-project.org/5384
Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
Diffstat (limited to 'tests/auto/gui/text/qrawfont/tst_qrawfont.cpp')
-rw-r--r-- | tests/auto/gui/text/qrawfont/tst_qrawfont.cpp | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp b/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp index 1c18f2f1e8..5404b0f587 100644 --- a/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp +++ b/tests/auto/gui/text/qrawfont/tst_qrawfont.cpp @@ -111,16 +111,6 @@ Q_DECLARE_METATYPE(QFontDatabase::WritingSystem) void tst_QRawFont::init() { -#ifdef Q_WS_QPA - // Loading fonts from a QByteArray seems unimplemented for all qpa plugins at time of writing; - // almost all testfunctions fail on qpa due to this, except these few: - const QByteArray func = QTest::currentTestFunction(); - if (func != "invalidRawFont" - && func != "explicitRawFontNotAvailableInSystem" - && func != "fromFont" - && func != "textLayout") - QEXPECT_FAIL("", "QTBUG-20976 fails on qpa", Abort); -#endif } void tst_QRawFont::invalidRawFont() @@ -308,9 +298,6 @@ void tst_QRawFont::textLayout() QString familyName = QString::fromLatin1("QtBidiTestFont"); QFont font(familyName); font.setPixelSize(18.0); -#ifdef Q_WS_QPA - QEXPECT_FAIL("", "QTBUG-20976 fails on qpa", Abort); -#endif QCOMPARE(QFontInfo(font).family(), familyName); QTextLayout layout(QLatin1String("Foobar")); @@ -628,10 +615,6 @@ void tst_QRawFont::fromFont() QRawFont rawFont = QRawFont::fromFont(font, writingSystem); QVERIFY(rawFont.isValid()); -#ifdef Q_WS_QPA - QEXPECT_FAIL("", "QTBUG-20976 fails on qpa", Abort); -#endif - QCOMPARE(rawFont.familyName(), familyName); QCOMPARE(rawFont.pixelSize(), 26.0); |