[Bug 1314] Wine always downloads truetype fonts into its ps files when printing
Wine Bugs
wine-bugs at winehq.com
Sun Jun 22 10:10:54 CDT 2003
http://bugs.winehq.com/show_bug.cgi?id=1314
------- Additional Comments From fsteinel at flonet.net 2003-22-06 10:10 -------
Bug comments restored from Gmane.org:
In wine-20030302 shipped by SuSE, if you have a truetype font directory defined
such
as the following:
[FontDirs]
"dir1" = "/home/aknaff/winefonts/core/ttf"
then all fonts defined there in will be downloaded into the generated postscript
file,
even if the printer natively understands them (as defined in the ppd file).
I.e. if I have an arial truetype font, this font is downloaded to the printer,
even though I
have the following in my .ppd file:
*Font ArialMT:
*Font Arial-BoldMT:
*Font Arial-BoldItalicMT:
*Font Arial-ItalicMT:
and even though I have the relevant .afm files in my [afmdirs].
The only way how I could force wine to use the printer's builtin Arial font was
to define
a substitution table where I substituted it with itself:
[System\\CurrentControlSet\\Control\\Print\\Printers\\file\\PrinterDriverData\\FontSubTable]
1047119381
"Courier New"="Courier New"
"Arial"="Arial"
"Times New Roman"="Times New Roman"
"Webdings"="Webdings"
"Tahoma"="Tahoma"
...
[Btw, the above FontSubTable worked for Courier New, Arial, Times New Roman, and
Tahoma, but still not for Webdings. But that's probably a different problem].
After perusing the source code, I found the following in
wine-20030219/dlls/wineps/font.c near the end of function PSDRV_SelectFont :
if(physDev->dc->gdiFont && !subst) {
if(PSDRV_SelectDownloadFont(physDev))
return 0; /* use gdi font */
}
PSDRV_SelectBuiltinFont(physDev, hfont, &lf, FaceName);
return (HFONT)1; /* use device font */
I.e. if there is a gdiFont defined for current font (I assume, this means if a
display font
has been loaded), and if the font is not the result of a substitution, then we
download it
into the printer. Otherwise we try to use a builtin font.
Shouldn't that be the other way round: first try to use a builtin font, and only
if that is not
possible (because no such font defined in generic.ppd or missing .afm file)
download it.
------- Additional Comments From wine <at> alk.org.lu 2003-03-25 14:42 -------
*** This bug has been confirmed by popular vote. ***
--
Configure bugmail: http://bugs.winehq.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
More information about the wine-bugs
mailing list