David Rosenstrauch wrote:
David C. Rankin wrote:
David C. Rankin wrote:
Listmates,
I have several additional fonts in /usr/local/share/fonts that I want configured for the system. I found /etc/fonts/fonts.conf and /etc/fonts/conf.d/51-local.conf, but I'm unsure about the placement of my <dir></dir> location in the local.conf file. Currently I have chosen:
<?xml version="1.0"?> <!DOCTYPE fontconfig SYSTEM "fonts.dtd"> <fontconfig> <!-- Load local system customization file --> <include ignore_missing="yes">local.conf</include> <dir>/usr/local/share/fonts</dir> </fontconfig>
My question is "does it matter whether the <dir> statement comes before or after the <include> and what do I need to do after I add the <dir> statement in 51-local.conf to make the system create a new font config?
I found additional information and things seem to be working great. Following http://wiki.archlinux.org/index.php/Xorg_Font_Configuration after adding my <dir> statement as shown above, I ran:
# fc-cache -fv <snip> /usr/local/share/fonts: caching, new cache contents: 46 fonts, 0 dirs
So it looks like its pickup up my fonts. I ran through the rest of the wiki and all is good!
Just a heads up - it's probably a bad idea to edit the /etc/fonts/fonts.conf file directly, as per both the wiki page ("fonts.conf should never be changed, and all changes should be done in local.conf (for system wide changes) or ~/.fonts.conf (for user based changes)") and the fonts.conf file itself ("DO NOT EDIT THIS FILE. IT WILL BE REPLACED WHEN FONTCONFIG IS UPDATED.")
DR
Thanks DR, I actually saw that warning and put the additional <dir> statement in /etc/fonts/conf.d/51-local.conf. I pretty sure that is the right place. The "Notes" in both /etc/fonts/fonts.conf and /etc/fonts/conf.d/51-local.conf are not as clear as they should be for new folks because /etc/fonts/fonts.conf direct the user to put the additional fonts in "local.conf" presuming the new user can decipher the XML <include> tag that specifies the contents of 51-local.conf as "local.conf". I scratched my head a bit and worked my way through it, but many users, even those very good with Linux, often are left scratching their heads when forced to decipher an XML schema, especially one that is spread over multiple files due to the use of a sourcing or <include> layout. I think the warning contained in /etc/fonts/fonts.conf should be changed to be literal with respect to the filenames. Something like: DO NOT EDIT THIS FILE. IT WILL BE REPLACED WHEN FONTCONFIG IS UPDATED. LOCAL CHANGES BELONG IN '/etc/fonts/conf.d/51-local.conf' ALL FILES IN '/etc/fonts/conf.d/' NAMED 'XX-filename.conf', WHERE 'XX' ARE DIGITS, ARE SOURCED BY THIS FILE. That would have eliminated all questions in my mind. -- David C. Rankin, J.D.,P.E. Rankin Law Firm, PLLC 510 Ochiltree Street Nacogdoches, Texas 75961 Telephone: (936) 715-9333 Facsimile: (936) 715-9339 www.rankinlawfirm.com