Bug 1158673

Summary: libpango no longer supports rendering of bitmap fonts
Product: [openSUSE] openSUSE Tumbleweed Reporter: Aleksa Sarai <asarai>
Component: GNOMEAssignee: E-mail List <gnome-bugs>
Status: RESOLVED WONTFIX QA Contact: E-mail List <qa-bugs>
Severity: Normal    
Priority: P5 - None CC: dimstar, f4tmike, fcrozat, jacob
Version: Current   
Target Milestone: ---   
Hardware: Other   
OS: Other   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: screenshot of broken text rendering

Description Aleksa Sarai 2019-12-06 13:53:45 UTC
Created attachment 825704 [details]
screenshot of broken text rendering

My normal font is Dina (dina-bitmap-fonts) and after the most recent update, both Termite and i3 (namely i3status and i3 itself) display all characters as though they are unknown unicode glyphs (see attached screenshot). Strangely, dmenu and i3-nagbar (which use the same font) display properly.

Changing to a non-bitmap font like DejaVu Sans Mono fixed the issue, but I would like to be able to use a font that worked in the past.
Comment 1 Jacob W 2019-12-08 23:31:23 UTC
I have the same issue, but with gvim using the Misc Fixed font, which I have been using for ~15 years now without issue until my latest update in TW. Fonts like DejaVu work ok. Also worth noting is that Misc Fixed shows up properly in KDE's font viewer (System Settings -> Fonts -> Font Management) and works as expected in the terminal urxvt.
Comment 2 Jacob W 2019-12-09 00:52:22 UTC
I forgot to mention that xorg-x11-server was upgraded to 1.20.6+0-1.1 and gvim to 8.1.0401-1.1

gvim's gui font picker (set guifont=*) does not see Misc Fixed.
Comment 3 Jacob W 2019-12-09 01:05:28 UTC
Just read that libpango (which was just upgraded to 1.44.7+11-1.1) dropped support for bitmap fonts in 1.44 [1]. Therefore, anything using libpango, which AFAIK is anything using gtk (which includes gvim) no longer has support for bitmap fonts.

[1] https://gitlab.gnome.org/GNOME/pango/issues/386
Comment 4 Jacob W 2019-12-11 03:58:48 UTC
Found a workaround: fonttosfnt

Use fonttosfnt to wrap a bitmap font in a sfnt wrapper, which is a font file that is acceptable by libpango.

Steps:
1) fonttosfnt -r -o "output.otb" "input.pcf"
2) install the output.otb font into your system (I used KDE's font manager)

Done.
Comment 5 Stefan Dirsch 2020-01-05 19:52:52 UTC
Reassigning to pango maintainers.
Comment 6 Frederic Crozat 2020-01-16 13:38:00 UTC
Nothing will change on the pango side (see upstream discussion). The proper way to move this would be to fix the offending fonts package to provide the font into OTB format.

One way to do it is explained at https://gitlab.gnome.org/GNOME/pango/issues/386#note_613754
Comment 7 Dominique Leuenberger 2020-07-01 11:57:42 UTC
*** Bug 1173553 has been marked as a duplicate of this bug. ***
Comment 8 Dominique Leuenberger 2020-12-29 16:15:57 UTC
(In reply to Frederic Crozat from comment #6)
> Nothing will change on the pango side (see upstream discussion). The proper
> way to move this would be to fix the offending fonts package to provide the
> font into OTB format.
> 
> One way to do it is explained at
> https://gitlab.gnome.org/GNOME/pango/issues/386#note_613754

IE, not a bug, but a feature.