Bug 444517 - Font preview kerning is broken
Summary: Font preview kerning is broken
Status: REPORTED
Alias: None
Product: systemsettings
Classification: Applications
Component: kcm_fontinst (other bugs)
Version First Reported In: 5.23.2
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2021-10-28 02:21 UTC by Nagy Tibor
Modified: 2023-07-21 22:01 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments
Screenshot (176.67 KB, image/png)
2021-10-28 02:21 UTC, Nagy Tibor
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Nagy Tibor 2021-10-28 02:21:05 UTC
Created attachment 142957 [details]
Screenshot

SUMMARY
The preview panel at the Font Management KCM doesn't properly kern its preview text. This makes the preview text look slightly crooked.

I attached a screenshot that compares this preview with an another KDE app (Krita) that does proper kerning just for reference.

STEPS TO REPRODUCE
1. Get Liberation Sans from your package manager. Also reproducible with other well-kerned fonts like Bitstream Vera Sans, DejaVu Sans, Noto Sans, Ubuntu font, etc.
2. Open Font Management and select Liberation Sans.
3. Right click the preview -> Change Preview Text...
4. Enter "VAVA" as the preview text -> OK.
5. Notice how the negative kerning offsets are not applied between the "V" and "A" characters. Liberation Sans defines a -152 unit offset at 2048 units/em resolution between these character pairs.

SOFTWARE/OS VERSIONS
Operating System: KDE neon 5.23
KDE Plasma Version: 5.23.2
KDE Frameworks Version: 5.87.0
Qt Version: 5.15.3
Graphics Platform: X11
Comment 1 Colin Griffith 2023-07-21 22:01:09 UTC
This bugged me too, so I started using KCharSelect to preview kerning, shaping, and so on. It seems to use Harfbuzz, which supports OpenType-styled kerning (which uses character classes in a table instead of kerning pairs), custom ligatures, and other advanced font features, and also supports traditional character pair kerning, so seems to support all fonts I've thrown at it.

It'd be nice to have that in Font Management, or at least in `kfontview`, but maybe that messes up when showing the 'All Characters' preview type? Then again, 'All Characters' *already* has characters falling off the edge of the window on the sides, so it's kinda already messed up.