Re: Fonts Again
Chris Siebenmann <[email protected]> Sun, 02 Jun 2019 13:50:30 -0400
| Newsgroups | gmane.mail.exmh.user |
|---|---|
| Message-ID | <[email protected]> |
> I've recently upgraded my system from Ubuntu 14.04 to 18.04 and I'm using > the exmh package included in this release (2.8.0-7). > > Since the upgrade, exmh uses a quite large font which might be a hint at > my age but I digress. > app-defaults select "fixed" as font and I have no font selected in my > exmh-defaults. > > This seems to result in the TrueType font DejaVuSansMono being used. Now > exmh doesn't seem to have provisions for selecting TrueType fonts at all, > so there's some fontconfig magic going on here. > I'm quite happy with this font, just the size could be a bit smaller but I > have no clue how to achieve this result. With the disclaimer that my knowledge here is somewhat rusty, I believe that the magic is actually in TK. If it is compiled to use XFT fonts (and fontconfig and so on), it magically maps certain old style X font names to XFT fonts internally. I think that 'fixed' is one of them, but it may actually be handled in your standard fontconfig. In any case, TK in general does allow you to select and control XFT fonts, and exmh inherits this. You can read about some of the details in the 'font(n)' TK manpage, and I wrote some more about this back in 2012 when Ubuntu 12.04 switched to a TK version compiled with XFT: https://utcc.utoronto.ca/~cks/space/blog/programming/TK85XFTFontNotes I believe that using basic exmh-defaults settings to set XFT font names and sizes works fine without any changes to exmh. These are things like: *font: monospace 11 *fl_font: monospace 11 However, you may well run into a problem with fonts in some MIME messages, because exmh very much believes that it can create and use old school XLFD font names (the -misc-fixed-medium-r-... names) in order to control font size and other things, and this does not work in the XFT world. Back in 2012 I posted some proposed patches to exmh-workers to deal with this. The patches work for me and have been ever since, but I don't think any version of them ever made it into the code. If you're interested I can dig up my message and send you a copy. (It appears that the Ubuntu exmh package has a patch to make HTML fonts work better, perhaps especially in an XFT world, which was an issue not addressed by my changes at the time.) - cks