qt6-bb10/tests/auto/gui/text
Eskil Abrahamsen Blomfeldt 93f32fd47a test: Fix test for oblique/italic equivalence
The tst_QFont::italicOblique() test is testing whether
a request for an "Oblique" font in the presence of an italic
one (or vice versa) may return the other as a second-best match.

However, it did not consider the fact that some fonts may not
be marked as italic even if the style name contains the word
"italic". One instance of this are variable fonts with oblique
instances. In this case we currently do not correctly recognize
the fonts as oblique.

But there is nothing preventing someone from creating a normal
font that has "italic" in the style name and not setting it as
italic in the OS/2 table (maybe the style name is "non-italic"),
so we can't really depend on this.

This makes the test a bit more robust by checking if the actual
font stored in the database is italic and verifying a match with
the requested oblique font. There are still cases that might
fail here, but we don't need to address those unless they
actually appear.

Pick-to: 6.5
Fixes: QTBUG-131108
Task-number: QTBUG-131262
Change-Id: I9ae0d37d378e8fec2be524db203dcea9a881f15a
Reviewed-by: Rami Potinkara <rami.potinkara@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
(cherry picked from commit 957e2be00a5c45223a5ef842a5f9f2f7b7be882b)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
2024-11-19 13:06:56 +00:00
..
qabstracttextdocumentlayout Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
qcssparser QTextHtmlParser: Handle fractional font-size pixel values 2024-08-13 12:08:27 +00:00
qfont test: Fix test for oblique/italic equivalence 2024-11-19 13:06:56 +00:00
qfontcache
qfontdatabase Support application fallbacks for common script 2024-05-21 07:24:03 +02:00
qfontmetrics Introduce flag to use typographical line metrics for fonts 2024-05-31 19:30:53 +02:00
qglyphrun
qinputcontrol
qrawfont Tests: check the output of QFile::open 2024-03-27 04:24:11 +01:00
qstatictext
qsyntaxhighlighter
qtextblock
qtextcursor Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
qtextdocument Support SVG specific stroke styling properties 2024-05-14 21:48:12 +03:00
qtextdocumentfragment
qtextdocumentlayout Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
qtextformat Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
qtextimagehandler QTextDocument: Add support for responsive images 2024-05-07 12:28:59 -07:00
qtextlayout Don't count overflowing inline image height to previous line 2024-11-19 07:02:49 +00:00
qtextlist Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
qtextmarkdownimporter
qtextmarkdownwriter Replace 'Qt Designer' and 'Qt Widgets Designer' in code 2024-05-16 13:04:41 +01:00
qtextobject
qtextodfwriter Respect QTextDocument::defaultFont() in ODF writer 2024-08-19 19:42:55 +00:00
qtextpiecetable
qtextscriptengine
qtexttable Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00
CMakeLists.txt Fix test compilation issues with QtLite configuration 2024-05-06 14:29:02 +00:00