Results 1 to 1 of 1
Problem #1: Here's some locations my system stores fonts: /usr/X11R6/lib/X11/fonts /usr/share/fonts /usr/local/share/fonts /usr/share/ghostscript/7.01/Resource/Font /usr/local/share/ghostscript/8.01/Resource/Font To a large degree they all repeat themselves. X11 has all the unique ones that I've ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 09-26-2013 #1
- Join Date
- Dec 2011
- Turtle Island West
Barnum & Bailey's 3 ring Font Circus.
Here's some locations my system stores fonts:
To a large degree they all repeat themselves. X11 has all the unique ones that I've installed.
I changed my mind about a few of the fonts I installed, so I un-installed them, and then my x font server started dying silently anytime it had to do it's job. I read that it does this when it doesn't like permissions on it's files. Well, after much lack of success trying to fix it, I actually re-installed the rpm and it still didn't work.
In fact, my XServer wouldn't even start if the font server wasn't running.
After a little research, I discovered I don't even need xfs if I put a few lines in /etc/X11/XF86Config-4:
Section "Files" # Multiple FontPath entries are allowed (they are concatenated together) # By default, Mandrake 6.0 and later now use a font server independent of # the X server to render fonts. FontPath "unix/:-1" # the font server if it's available # otherwise look in these locations FontPath "/usr/X11R6/lib/X11/fonts/misc:unscaled" FontPath "/usr/X11R6/lib/X11/fonts/drakfont/Type1" FontPath "/usr/X11R6/lib/X11/fonts/drakfont/ttf" FontPath "/usr/X11R6/lib/X11/fonts/100dpi:unscaled" FontPath "/usr/X11R6/lib/X11/fonts/75dpi:unscaled" FontPath "/usr/X11R6/lib/X11/fonts/Type1" FontPath "/usr/X11R6/lib/X11/fonts/TTF" FontPath "/usr/X11R6/lib/X11/fonts/mdk:unscaled" FontPath "/usr/X11R6/lib/X11/fonts/100dpi" FontPath "/usr/X11R6/lib/X11/fonts/75dpi" FontPath "/usr/X11R6/lib/X11/fonts/cyrillic" FontPath "/usr/X11R6/lib/X11/fonts/gs" FontPath "/usr/X11R6/lib/X11/fonts/misc" FontPath "/usr/X11R6/lib/X11/fonts/new" FontPath "/usr/X11R6/lib/X11/fonts/new2" FontPath "/usr/X11R6/lib/X11/fonts/script" FontPath "/usr/X11R6/lib/X11/fonts/win" FontPath "/usr/share/fonts/default/Type1" FontPath "/usr/share/fonts/ttf/vera" FontPath "/usr/share/fonts/ttf/decoratives" FontPath "/usr/share/fonts/ttf/western" EndSection
I make PDFs with OpenOffice. For the most part it does a great job. I cannot *edit* PDFs, but I can create them and view them. That is perfectly adequate. Mostly.
I need to create a great deal of very similar PDFs on occasion, and doing it manually is an error-prone pain in the neck.
I discovered I can create postscript files with a shell script, that I can then turn into PDFs. Wow. That works great.
Except for a small issue: fonts. Ghostscript is very finicky about fonts. Mostly about where you put them and how you tell it where they are.
For example, I have a directory: /usr/local/share/ghostscript/8.01/Resource/Font that has a bunch of Type1 fonts in it. They are the standard ones that come with ghostscript.
I like Arial, gs likes Helvetica, and I got sick of arguing with it about the issue. I convert arial.ttf to Type1 with ttf2pt1 -b, put the resulting files in that dir, update the Fontmap file that is sitting in that dir, and... no luck.
Can't find (or can't open) font file /Resource/Font/Arial. Can't find (or can't open) font file Arial. Substituting font Helvetica for Arial.
Why is it looking for fonts in lib? lib is already packed with stuff. I tried setting GS_FONTPATH but it made no difference. So I made a subdirectory in lib, lib/fonts, made a file Fontmap.new, included it in Fontmap, and put my new fonts in the new subdirectory to keep things clean. So far it works.
But still, I want to know why gs is looking for fonts in its lib dir, and refuses to look in Resource/Font. After some perusal, I discover a tidbit in PREFIX/lib/gs_font.ps. This is one of it's main config files:
% Scan directories looking for plausible fonts. "Plausible" means that % the file begins with %!PS-AdobeFont or %!FontType1, or with \200\001 % followed by four arbitrary bytes and then either of these strings. % To speed up the search, we skip any file whose name appears in % the Fontmap (with any extension and upper/lower case variation) already, % and any file whose extension definitely indicates it is not a font.
% To speed up the search, we skip any file whose name appears in % the Fontmap (with any extension and upper/lower case variation) already,
I'm no postscript guru. I can make basic ps files that print nicely, but I cannot make heads or tails of the code that follows that bit, so I just left it alone and suffer with my work-around.
BTW, scriptina seems like a nice font. You can get it here.
Peace and Cheer.