At the end of march I spent a few days with the Inkscape team, who were so nice to come to the Red Hat Boston office for their hackfest. We discussed many things, from the GTK3 port of Inkscape, to SVG and CSS, but we also spent some time on one of my favorite topics: fonts.
Font Chooser
One thing Tav showed me which I was immediately envious of is the preview of OpenType features that Inkscape has in its font selector.
Clearly, we want something like that in the GTK+ font chooser as well. So, after coming back from the hackfest, I set out to see if I can get this implemented. This is how far I got so far, it is available in GTK+ master.
This really helps understanding which glyphs are affected by a font feature. I would like to add a preview for ligatures as well, but harfbuzz currently does not offer any API to get at the necessary information (understandably — its main focus is applying font features for shaping) and I’m not prepared to parse those font tables myself in GTK+. So, ligatures will have to wait a bit.
Another thing I would like to explore at some point is possible approaches for letting users apply font features to smaller fragments of text, like a headline or a single word. This could be a ‘font tweak’ dialog or panel. If you have suggestions or ideas for this, I’d love to hear them.
At the request of the Inkscape folks, I’ve also explored a backport of the new font chooser capabilities to the 3.22 branch, but since this involves new API, we’re not sure yet which way to go with this.
Font Browser
While doing font work it is always good to have a supply of featureful fonts, so I end up browing the Google web fonts quite a bit.
Recently, I stumbled over a nice-looking desktop app for doing so, but alas, it wasn’t available as a package, and it is written in rust, which I know very little about (I’m hoping to change that soon, but that’s a topic for another post).
But I’ve mentioned this app on #flatpak, and just a few days later, it appeared on flathub, and thus also in GNOME software on my system, just a click away. So nice of the flathub team!
The new flathub website is awesome, btw. Go check it out.
The best part is that this nice little app is now available not just on my bleeding-edge Fedora Atomic Workstation, but also on Ubuntu, Gentoo and even RHEL, thanks to flatpak. Something we could only dream of a few years ago.
I do need to make some improvements to Font Finder’s code, the UI, and add a Makefike. It was about a three day sprint to make a Rusty replacement for Type Catcher, as the GTK WebKit Rust bindings had just recently been made at the time, and TypeCatcher wasn’t easy to get installed and running.
RFE: handling fonts catalogs (or “subsets” — a concept simillary to playlist).