Charles Philip Chan <cpchan@sympatico.ca> さんは書きました:
Actually I am quite happy with the script as it stands. I don't mind touching up the fontmap file until the problem is fixed within QT itself. Although a script that can generate a perfect fontmap file will be a big win for SuSE, especially with newbies, since SuSE uses KDE as the default environment.
By the way, did you already try the fontembedding feature in Qt? You can do that with qtconfig. Just call qtconfig switch to the rightmost tab labelled "Printer" and make sure that fontembedding is enabled. Actually this is the better solution than using the aliases for Ghostscript. If you use fontembedding, the TrueType and PostScript fonts used for display will be embedded into the PostScript output. This has the small disadvantage that the PostScript file gets a bit bigger, but the huge advantage that you can take such a PostScript file with you and print anywhere on any PostScript printer or on any other system which has Ghostscript, no matter which fonts are installed on that other system or available in the PostScript printer, because the file itself already has the fonts. The aliases are only needed when the fontembedding is off. In that case Qt/KDE applications don't include the fonts into the PostScript file, they only write the name of the font into the file. Then, Ghostscript has to find that font again and needs such a Fontmap file to find the proper fonts to render that document. Such a document will then only print on a system which has Ghostscript *and* a Fontmap which has all necessary entries. The only advantage is that the PostScript files a bit smaller. I recommend to use fontembedding as the more practical solution and thus avoid the problems with the aliases completely. Nevertheless I want to make it work with the aliases as well, because some people may want to switch fontembedding of for whatever reasons, and I want to make it work by default in that case as well. To check whether you KDE programs really embed the fonts, direct the printing output to a file: Click on the print menu, there you can select somewhere that you want PostScript output into a file. Then try to view that file with gs: gs print.ps If you file does not embed all fonts, you will see some messages Loading .... font from ... like this: mfabian@magellan:~$ gs print.ps ESP Ghostscript 7.05 (2002-06-28) Copyright (C) 2002 artofcode LLC, Benicia, CA. All rights reserved. This software comes with NO WARRANTY: see the file COPYING for details. Loading BitstreamVeraSans-Roman font from /usr/X11R6/lib/X11/fonts/Vera/tt2001gn.ttf...2775920 1316395 2905116 1506272 0 done. >>showpage, press <return> to continue<< quit GS>mfabian@magellan:~$ This is using the Fontmap. If all fonts are already embedded into the PostScript file, you will see no "Loading .... font from ..." messages at all, everything is already in print.ps, Ghostscript doesn't need to load anything else in that case. -- Mike Fabian <mfabian@suse.de> http://www.suse.de/~mfabian 睡眠不足はいい仕事の敵だ。