qt6-bb10/tests/manual
Eskil Abrahamsen Blomfeldt 4a935a192e Improve hinted rendering quality on Windows
When rendering hinted text on Windows with DirectWrite, the goal was
to keep the rendering and metrics as close to GDI as possible,
minimizing the impact of changing the default font backend.

Therefore, the DWRITE_RENDERING_MODE_GDI_CLASSIC was always preferred
when hinting was on.

However, DWRITE_RENDERING_MODE_GDI_CLASSIC only applies antialiasing
in the horizontal direction, but GDI applies vertical antialiasing
as well. The result is that text will look more aliased with
DirectWrite than it did with GDI, which arguably looks ugly
especially at large sizes and can be perceived as a regression.

Microsoft documentation recommends using symmetric antialiasing
when the pixel size exceeds 16, so this patch enables
DWRITE_RENDERING_MODE_NATURAL_SYMMETRIC for fonts larger than
16px regardless of whether hinting is on.

It's worth noting that for fonts with heavy hinting, such as
Times New Roman, the rendering using
DWRITE_RENDERING_MODE_NATURAL_SYMMETRIC is different from
GDI, although more similar to Freetype. However, the impact
of not having vertical antialiasing is worse and as native apps
are moving towards using DirectWrite, the GDI rendering is not
going to be the definition of a "native" look anymore.

A second thing to note in this patch is that we always pass in false
for the useGdiNatural argument in GetGdiCompatibleGlyphMetrics().
According to the documentation, we should be passing in true for text
rendered with CLEARTYPE_NATURAL_QUALITY. However, doing this causes
wider kerning in certain cases. Since the tighter kerning matches
the layouts we get in native apps, as well as when using Freetype,
I've chosen to pass false for now, to be consistent.

This change also adds a manual test which can be used to switch
between DirectWrite, GDI and Freetype rendering on Windows, so
that it's easy to compare.

[ChangeLog][Windows] Improved hinted text rendering at font sizes
larger than 16px.

Fixes: QTBUG-131946
Change-Id: Iebbe5c7affe7df6266ade6b161c31bde3d2caa84
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
(cherry picked from commit 407a98d94fb05780f30e77463fb2bd535041a044)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
(cherry picked from commit e59362678880cf89a2e7870365a030f0b9c254a7)
2025-02-08 13:53:37 +00:00
..
android_content_uri Add copyright and licensing to build system files missing it 2024-05-21 17:23:21 +02:00
assets Correct tests license 2024-08-13 12:56:14 +00:00
cmake/test_copy_file_if_different_command Change license for tests files 2024-02-04 09:56:42 +01:00
cocoa Change license for tests files 2024-02-04 09:56:42 +01:00
corelib Fix QDataStream::operator<<(const char *) to handle 64-bit length 2024-02-07 15:02:19 +01:00
diaglib Change license for tests files 2024-02-04 09:56:42 +01:00
dialogs Replace 'Qt Designer' and 'Qt Widgets Designer' in code 2024-05-16 13:04:41 +01:00
embeddedintoforeignwindow Change license for tests files 2024-02-04 09:56:42 +01:00
embeddedwindows Add WS_CLIPCHILDREN style to native window in embeddedwindows test 2024-10-07 12:30:27 +00:00
examples Android: cleanup AndroidManifest.xml files in examples 2024-05-23 17:52:21 +03:00
filetest Change license for tests files 2024-02-04 09:56:42 +01:00
findfiles Doc: Further replace 'Qt Designer' with 'Qt Widgets Designer' 2024-02-29 15:35:58 +01:00
fontfeatures Change license for tests files 2024-02-04 09:56:42 +01:00
foreignwindows Change license for tests files 2024-02-04 09:56:42 +01:00
gestures Change license for tests files 2024-02-04 09:56:42 +01:00
graphicsframecapture Add configure feature for Metal 2024-03-19 14:52:48 +01:00
highdpi Add copyright and licensing to build system files missing it 2024-05-21 17:23:21 +02:00
iconbrowser Make iconbrowser manual test directly openable in Creator 2025-01-22 23:04:14 +00:00
inputdevices Add copyright and licensing to build system files missing it 2024-05-21 17:23:21 +02:00
inputmethodhints Change license for tests files 2024-02-04 09:56:42 +01:00
ios_assets Change license for tests files 2024-02-04 09:56:42 +01:00
keyevents Change license for tests files 2024-02-04 09:56:42 +01:00
keypadnavigation Change license for tests files 2024-02-04 09:56:42 +01:00
lance Fix lance readme: tests/auto/other/lancelot is gone now 2024-04-18 13:15:52 -07:00
markdown Change license for tests files 2024-02-04 09:56:42 +01:00
mkspecs Correct license for tools files 2024-03-05 12:59:21 +01:00
network/ssl/client-auth Correct license for tools files 2024-03-05 12:59:21 +01:00
network_remote_stresstest Change license for tests files 2024-02-04 09:56:42 +01:00
network_stresstest Add REUSE.toml files 2024-11-07 08:38:49 +01:00
permissions CMake: make tst_manual_permissions standalone project 2024-08-10 10:07:44 +00:00
qcursor Change license for tests files 2024-02-04 09:56:42 +01:00
qdesktopservices Change license for tests files 2024-02-04 09:56:42 +01:00
qdnslookup QDnsLookup: add support for TLSA records 2024-05-08 21:13:47 -07:00
qglyphruns Change license for tests files 2024-02-04 09:56:42 +01:00
qgraphicsitem Change license for tests files 2024-02-04 09:56:42 +01:00
qgraphicsitemgroup Change license for tests files 2024-02-04 09:56:42 +01:00
qgraphicslayout Change license for tests files 2024-02-04 09:56:42 +01:00
qhttpnetworkconnection Change license for tests files 2024-02-04 09:56:42 +01:00
qimagereader Change license for tests files 2024-02-04 09:56:42 +01:00
qlayout Change license for tests files 2024-02-04 09:56:42 +01:00
qlocale Change license for tests files 2024-02-04 09:56:42 +01:00
qmetatype Change license for tests files 2024-02-04 09:56:42 +01:00
qmimedatabase Change license for tests files 2024-02-04 09:56:42 +01:00
qnetconmonitor Change license for tests files 2024-02-04 09:56:42 +01:00
qnetworkaccessmanager/qget Fix the crash of test case authentication required 2024-08-19 04:04:18 +00:00
qnetworkinformation Change license for tests files 2024-02-04 09:56:42 +01:00
qnetworkreply Change license for tests files 2024-02-04 09:56:42 +01:00
qopenglcontext Change license for tests files 2024-02-04 09:56:42 +01:00
qopengltextureblitter Change license for tests files 2024-02-04 09:56:42 +01:00
qopenglwidget Add copyright and licensing to .glsl missing them 2024-05-03 14:04:52 +02:00
qopenglwindow/multiwindow Change license for tests files 2024-02-04 09:56:42 +01:00
qprintdevice_dump Change license for tests files 2024-02-04 09:56:42 +01:00
qscreen Change license for tests files 2024-02-04 09:56:42 +01:00
qscreen_xrandr Change license for tests files 2024-02-04 09:56:42 +01:00
qssloptions Change license for tests files 2024-02-04 09:56:42 +01:00
qsslsocket Change license for tests files 2024-02-04 09:56:42 +01:00
qstorageinfo Change license for tests files 2024-02-04 09:56:42 +01:00
qsysinfo Change license for tests files 2024-02-04 09:56:42 +01:00
qt_poll Change license for tests files 2024-02-04 09:56:42 +01:00
qtabbar Add copyright and licensing to .cpp and .h files missing them 2024-05-28 09:47:01 +02:00
qtabletevent tests: update info for mouse move events in device_information 2024-04-10 21:01:07 +02:00
qtbug-8933 Change license for tests files 2024-02-04 09:56:42 +01:00
qtbug-52641 Change license for tests files 2024-02-04 09:56:42 +01:00
qtextcursorinsert Change license for tests files 2024-02-04 09:56:42 +01:00
qtexteditlist Change license for tests files 2024-02-04 09:56:42 +01:00
qtexttableborders Change license for tests files 2024-02-04 09:56:42 +01:00
qtouchevent Change license for tests files 2024-02-04 09:56:42 +01:00
qvulkaninstance Change license for tests files 2024-02-04 09:56:42 +01:00
qwidget_zorder Change license for tests files 2024-02-04 09:56:42 +01:00
repaint Remove extra semi-colons 2024-02-06 20:17:18 +09:00
rhi Add REUSE.toml files 2024-11-07 08:38:49 +01:00
shortcuts Windows: Add Key_Backtab as possible key combination for Shift+Tab 2025-01-15 00:09:59 +00:00
socketengine Change license for tests files 2024-02-04 09:56:42 +01:00
startsystemmove Change license for tests files 2024-02-04 09:56:42 +01:00
stereographicsview Change license for tests files 2024-02-04 09:56:42 +01:00
textrendering Improve hinted rendering quality on Windows 2025-02-08 13:53:37 +00:00
touch Change license for tests files 2024-02-04 09:56:42 +01:00
touchGraphicsItem tests: port touchGraphicsItem to Qt 6 2024-09-20 15:23:58 +00:00
transientwindow Change license for tests files 2024-02-04 09:56:42 +01:00
triangulator Change license for tests files 2024-02-04 09:56:42 +01:00
unc Change license for tests files 2024-02-04 09:56:42 +01:00
wasm wasm: fix uri-list handling urls 2024-05-29 08:18:06 +10:00
widgetgrab Change license for tests files 2024-02-04 09:56:42 +01:00
widgets Change license for tests files 2024-02-04 09:56:42 +01:00
windowactivation Change license for tests files 2024-02-04 09:56:42 +01:00
windowchildgeometry Change license for tests files 2024-02-04 09:56:42 +01:00
windowflags Change license for tests files 2024-02-04 09:56:42 +01:00
windowgeometry Change license for tests files 2024-02-04 09:56:42 +01:00
windowmask Change license for tests files 2024-02-04 09:56:42 +01:00
windowmodality Change license for tests files 2024-02-04 09:56:42 +01:00
windowtransparency Change license for tests files 2024-02-04 09:56:42 +01:00
xcb_gl_integration Change license for tests files 2024-02-04 09:56:42 +01:00
xembed Add copyright and licensing to build system files missing it 2024-05-21 17:23:21 +02:00
xmlstreamlint Change license for tests files 2024-02-04 09:56:42 +01:00
CMakeLists.txt AssetDownloader: Add manual test 2024-06-14 13:44:17 +00:00
manual.pro AssetDownloader: Add manual test 2024-06-14 13:44:17 +00:00