David C. Rankin composed on 2015-09-24 16:54 (UTC-0500):
David C. Rankin wrote:
You will be unhappy to note that this effects both FF and TB. So if you are wonder why file listings like download.opensuse.org/repositories/... are harder to read because they are displayed in some weird windows mono font -- this is the answer.
Wolfgang (oh, mozilla wizard),
How in the heck do we tell both FF and TB to display messages and plain-text pages in the font chosen in:
Options-> Display-> Formatting-> Advanced-> (our font choice)?
It seems no matter what they are set to, if the page, or message, has the *charset=utf-8* included somewhere, then you get the ms default font instead of your chosen font?
cc: Mozilla Wizard
After chasing down a solution to this gift in TB38, the solution isn't that difficult at all.
With mozilla no longer honoring the default font faces of 'sans', 'sans-serif' and 'monospace', even though you tell FF or TB to use a specific font (e.g DejaVu Sans Mono), when receiving a page or message with *charset=utf-8*, both FF and TB continue to rely on the system-wide default font. (which makes absolutely no sense whatsoever)
Regardless, they can be trained to use the proper font by you setting the system-wide font for 'monospace', etc.. to a specific font.
First, check what your system thinks the system-wide font is for that typeface:
$ fc-match monospace consola.ttf: "Consolas" "Regular"
Yuk!
In 13.1, that results from line 129 in /usr/share/fontconfig/conf.avail/58-suse-post-user.conf, which places Consolas at the head of the monospace heirarchy.
If it is not what you want, then you must set the system-wide default for that typeface in /etc/fonts/local.conf (which is just an empty xml shell for fontconfig by default)
"Must" isn't accurate. Fontconfig has multiple routes to the same ends.
Edit the file with your favorite editor and add the following between the <fontconfig> tags. (substitute your chosen font where I have 'DejaVu Sans Mono')
<match target="pattern"> <test name="family" qual="any"> <string>monospace</string> </test> <edit binding="strong" mode="prepend" name="family"> <string>DejaVu Sans Mono</string> </edit> </match>
Save -- that's it. Not both FF and TB 38 will display the plain-text pages/messages in DejaVu Sans Mono regardless of whether charset=utf-8 or charset=us-ascii
Alternatively, make a copy of /usr/share/fontconfig/conf.avail/58-suse-post-user.conf, and sort the heirarchies in the order you'd prefer. http://fm.no-ip.com/Share/57-post-user.conf has the order I prefer, where you can see I knocked Consolas down to #8. That file I put in /etc/fonts/conf.d/. On this particular 13.1 installation, I've symlink'd /etc/fonts/conf.d/57-post-user.conf to both 55-post-user.conf and 58-post-user.conf rather than spending the time to figure out which number its filename ought to start with to achieve the desired system-wide results, which here, is thus: # fc-match monospace DroidSansMono.ttf: "Droid Sans Mono" "Regular" If you have Consolas on your system and load http://fm.no-ip.com/Auth/Font/fonts-face-samplesM.html in a browser you might be able to tell why I don't like it - it's smaller at most nominal sizes than most other monospace fonts. Whether any smaller at a given size, and how much, depends on pt-to-px ratio, which depends on browser engine and DE DPI. -- "The wise are known for their understanding, and pleasant words are persuasive." Proverbs 16:21 (New Living Translation) Team OS/2 ** Reg. Linux User #211409 ** a11y rocks! Felix Miata *** http://fm.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org