mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-02 01:23:37 +00:00
wineps: Store font related strings in unicode.
This commit is contained in:
parent
8cfa8c15ee
commit
11ab927ae2
|
@ -99,7 +99,7 @@ BOOL PSDRV_AddAFMtoList(FONTFAMILY **head, const AFM *afm, BOOL *p_added)
|
|||
newafmle->afm = afm;
|
||||
|
||||
while(family) {
|
||||
if(!strcmp(family->FamilyName, afm->FamilyName))
|
||||
if(!wcscmp(family->FamilyName, afm->FamilyName))
|
||||
break;
|
||||
insert = &(family->next);
|
||||
family = family->next;
|
||||
|
@ -113,12 +113,12 @@ BOOL PSDRV_AddAFMtoList(FONTFAMILY **head, const AFM *afm, BOOL *p_added)
|
|||
return FALSE;
|
||||
}
|
||||
*insert = family;
|
||||
if (!(family->FamilyName = HeapAlloc(PSDRV_Heap, 0, strlen(afm->FamilyName)+1 ))) {
|
||||
if (!(family->FamilyName = HeapAlloc(PSDRV_Heap, 0, (wcslen(afm->FamilyName)+1)*sizeof(WCHAR) ))) {
|
||||
HeapFree(PSDRV_Heap, 0, family);
|
||||
HeapFree(PSDRV_Heap, 0, newafmle);
|
||||
return FALSE;
|
||||
}
|
||||
strcpy( family->FamilyName, afm->FamilyName );
|
||||
wcscpy( family->FamilyName, afm->FamilyName );
|
||||
family->afmlist = newafmle;
|
||||
*p_added = TRUE;
|
||||
return TRUE;
|
||||
|
@ -158,16 +158,16 @@ static void PSDRV_DumpFontList(void)
|
|||
AFMLISTENTRY *afmle;
|
||||
|
||||
for(family = PSDRV_AFMFontList; family; family = family->next) {
|
||||
TRACE("Family '%s'\n", family->FamilyName);
|
||||
TRACE("Family %s\n", debugstr_w(family->FamilyName));
|
||||
for(afmle = family->afmlist; afmle; afmle = afmle->next)
|
||||
{
|
||||
#if 0
|
||||
INT i;
|
||||
#endif
|
||||
|
||||
TRACE("\tFontName '%s' (%i glyphs) - '%s' encoding:\n",
|
||||
afmle->afm->FontName, afmle->afm->NumofMetrics,
|
||||
afmle->afm->EncodingScheme);
|
||||
TRACE("\tFontName '%s' (%i glyphs) - %s encoding:\n",
|
||||
afmle->afm->FontName, afmle->afm->NumofMetrics,
|
||||
debugstr_w(afmle->afm->EncodingScheme));
|
||||
|
||||
/* Uncomment to regenerate font data; see afm2c.c */
|
||||
|
||||
|
|
|
@ -81,7 +81,7 @@ static void writeHeader(FILE *of, const AFM *afm, const char *buffer)
|
|||
fputc('*', of);
|
||||
fprintf(of, "\n"
|
||||
" *\n"
|
||||
" *\tFont metric data for %s\n"
|
||||
" *\tFont metric data for %S\n"
|
||||
" *\n"
|
||||
" *\tCopyright 2001 Ian Pilcher\n"
|
||||
" *\n"
|
||||
|
@ -121,11 +121,11 @@ static void writeAFM(FILE *of, const AFM *afm, const char *buffer)
|
|||
fprintf(of, "const AFM PSDRV_%s =\n{\n", buffer);
|
||||
cursorto(of, 44, fprintf(of, " \"%s\",", afm->FontName));
|
||||
fputs("/* FontName */\n", of);
|
||||
cursorto(of, 44, fprintf(of, " \"%s\",", afm->FullName));
|
||||
cursorto(of, 44, fprintf(of, " L\"%S\",", afm->FullName));
|
||||
fputs("/* FullName */\n", of);
|
||||
cursorto(of, 44, fprintf(of, " \"%s\",", afm->FamilyName));
|
||||
cursorto(of, 44, fprintf(of, " L\"%S\",", afm->FamilyName));
|
||||
fputs("/* FamilyName */\n", of);
|
||||
cursorto(of, 44, fprintf(of, " \"%s\",", afm->EncodingScheme));
|
||||
cursorto(of, 44, fprintf(of, " L\"%S\",", afm->EncodingScheme));
|
||||
fputs("/* EncodingScheme */\n", of);
|
||||
cursorto(of, 44, fprintf(of, " %s,",
|
||||
(afm->Weight > 550) ? "FW_BOLD" : "FW_NORMAL"));
|
||||
|
|
|
@ -157,7 +157,7 @@ static VOID ScaleFont(const AFM *afm, LONG lfHeight, PSFONT *font,
|
|||
*
|
||||
*/
|
||||
BOOL PSDRV_SelectBuiltinFont(PHYSDEV dev, HFONT hfont,
|
||||
LOGFONTW *plf, LPSTR FaceName)
|
||||
LOGFONTW *plf, WCHAR *face_name)
|
||||
{
|
||||
PSDRV_PDEVICE *physDev = get_psdrv_dev( dev );
|
||||
AFMLISTENTRY *afmle;
|
||||
|
@ -165,27 +165,27 @@ BOOL PSDRV_SelectBuiltinFont(PHYSDEV dev, HFONT hfont,
|
|||
BOOL bd = FALSE, it = FALSE;
|
||||
LONG height;
|
||||
|
||||
TRACE("Trying to find facename '%s'\n", FaceName);
|
||||
TRACE("Trying to find facename %s\n", debugstr_w(face_name));
|
||||
|
||||
/* Look for a matching font family */
|
||||
for(family = physDev->pi->Fonts; family; family = family->next) {
|
||||
if(!stricmp(FaceName, family->FamilyName))
|
||||
if(!wcsicmp(face_name, family->FamilyName))
|
||||
break;
|
||||
}
|
||||
|
||||
if(!family) {
|
||||
/* Fallback for Window's font families to common PostScript families */
|
||||
if(!strcmp(FaceName, "Arial"))
|
||||
strcpy(FaceName, "Helvetica");
|
||||
else if(!strcmp(FaceName, "System"))
|
||||
strcpy(FaceName, "Helvetica");
|
||||
else if(!strcmp(FaceName, "Times New Roman"))
|
||||
strcpy(FaceName, "Times");
|
||||
else if(!strcmp(FaceName, "Courier New"))
|
||||
strcpy(FaceName, "Courier");
|
||||
if(!wcscmp(face_name, L"Arial"))
|
||||
wcscpy(face_name, L"Helvetica");
|
||||
else if(!wcscmp(face_name, L"System"))
|
||||
wcscpy(face_name, L"Helvetica");
|
||||
else if(!wcscmp(face_name, L"Times New Roman"))
|
||||
wcscpy(face_name, L"Times");
|
||||
else if(!wcscmp(face_name, L"Courier New"))
|
||||
wcscpy(face_name, L"Courier");
|
||||
|
||||
for(family = physDev->pi->Fonts; family; family = family->next) {
|
||||
if(!strcmp(FaceName, family->FamilyName))
|
||||
if(!wcscmp(face_name, family->FamilyName))
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -193,7 +193,7 @@ BOOL PSDRV_SelectBuiltinFont(PHYSDEV dev, HFONT hfont,
|
|||
if(!family)
|
||||
family = physDev->pi->Fonts;
|
||||
|
||||
TRACE("Got family '%s'\n", family->FamilyName);
|
||||
TRACE("Got family %s\n", debugstr_w(family->FamilyName));
|
||||
|
||||
if(plf->lfItalic)
|
||||
it = TRUE;
|
||||
|
@ -401,8 +401,7 @@ static UINT PSDRV_GetFontMetric(HDC hdc, const AFM *afm,
|
|||
|
||||
lf->lfPitchAndFamily = (afm->IsFixedPitch) ? FIXED_PITCH : VARIABLE_PITCH;
|
||||
|
||||
MultiByteToWideChar(CP_ACP, 0, afm->FamilyName, -1, lf->lfFaceName,
|
||||
LF_FACESIZE);
|
||||
lstrcpynW(lf->lfFaceName, afm->FamilyName, LF_FACESIZE);
|
||||
|
||||
return DEVICE_FONTTYPE;
|
||||
}
|
||||
|
@ -419,18 +418,15 @@ BOOL CDECL PSDRV_EnumFonts( PHYSDEV dev, LPLOGFONTW plf, FONTENUMPROCW proc, LPA
|
|||
BOOL ret;
|
||||
AFMLISTENTRY *afmle;
|
||||
FONTFAMILY *family;
|
||||
char FaceName[LF_FACESIZE];
|
||||
|
||||
ret = next->funcs->pEnumFonts( next, plf, proc, lp );
|
||||
if (!ret) return FALSE;
|
||||
|
||||
if( plf && plf->lfFaceName[0] ) {
|
||||
WideCharToMultiByte(CP_ACP, 0, plf->lfFaceName, -1,
|
||||
FaceName, sizeof(FaceName), NULL, NULL);
|
||||
TRACE("lfFaceName = '%s'\n", FaceName);
|
||||
TRACE("lfFaceName = %s\n", debugstr_w(plf->lfFaceName));
|
||||
for(family = physDev->pi->Fonts; family; family = family->next) {
|
||||
if(!strncmp(FaceName, family->FamilyName,
|
||||
strlen(family->FamilyName)))
|
||||
if(!wcsncmp(plf->lfFaceName, family->FamilyName,
|
||||
wcslen(family->FamilyName)))
|
||||
break;
|
||||
}
|
||||
if(family) {
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_AvantGarde_Book =
|
||||
{
|
||||
"AvantGarde-Book", /* FontName */
|
||||
"ITC Avant Garde Gothic Book", /* FullName */
|
||||
"ITC Avant Garde Gothic", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Avant Garde Gothic Book", /* FullName */
|
||||
L"ITC Avant Garde Gothic", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_AvantGarde_BookOblique =
|
||||
{
|
||||
"AvantGarde-BookOblique", /* FontName */
|
||||
"ITC Avant Garde Gothic Book Oblique", /* FullName */
|
||||
"ITC Avant Garde Gothic", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Avant Garde Gothic Book Oblique", /* FullName */
|
||||
L"ITC Avant Garde Gothic", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-10.5, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_AvantGarde_Demi =
|
||||
{
|
||||
"AvantGarde-Demi", /* FontName */
|
||||
"ITC Avant Garde Gothic Demi", /* FullName */
|
||||
"ITC Avant Garde Gothic", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Avant Garde Gothic Demi", /* FullName */
|
||||
L"ITC Avant Garde Gothic", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_AvantGarde_DemiOblique =
|
||||
{
|
||||
"AvantGarde-DemiOblique", /* FontName */
|
||||
"ITC Avant Garde Gothic Demi Oblique", /* FullName */
|
||||
"ITC Avant Garde Gothic", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Avant Garde Gothic Demi Oblique", /* FullName */
|
||||
L"ITC Avant Garde Gothic", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-10.5, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Bookman_Demi =
|
||||
{
|
||||
"Bookman-Demi", /* FontName */
|
||||
"ITC Bookman Demi", /* FullName */
|
||||
"ITC Bookman", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Bookman Demi", /* FullName */
|
||||
L"ITC Bookman", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Bookman_DemiItalic =
|
||||
{
|
||||
"Bookman-DemiItalic", /* FontName */
|
||||
"ITC Bookman Demi Italic", /* FullName */
|
||||
"ITC Bookman", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Bookman Demi Italic", /* FullName */
|
||||
L"ITC Bookman", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-10, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Bookman_Light =
|
||||
{
|
||||
"Bookman-Light", /* FontName */
|
||||
"ITC Bookman Light", /* FullName */
|
||||
"ITC Bookman", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Bookman Light", /* FullName */
|
||||
L"ITC Bookman", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Bookman_LightItalic =
|
||||
{
|
||||
"Bookman-LightItalic", /* FontName */
|
||||
"ITC Bookman Light Italic", /* FullName */
|
||||
"ITC Bookman", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Bookman Light Italic", /* FullName */
|
||||
L"ITC Bookman", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-10, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -272,9 +272,9 @@ static const AFMMETRICS metrics[243] =
|
|||
const AFM PSDRV_Courier =
|
||||
{
|
||||
"Courier", /* FontName */
|
||||
"Courier", /* FullName */
|
||||
"Courier", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Courier", /* FullName */
|
||||
L"Courier", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
TRUE, /* IsFixedPitch */
|
||||
|
|
|
@ -272,9 +272,9 @@ static const AFMMETRICS metrics[243] =
|
|||
const AFM PSDRV_Courier_Bold =
|
||||
{
|
||||
"Courier-Bold", /* FontName */
|
||||
"Courier Bold", /* FullName */
|
||||
"Courier", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Courier Bold", /* FullName */
|
||||
L"Courier", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
TRUE, /* IsFixedPitch */
|
||||
|
|
|
@ -272,9 +272,9 @@ static const AFMMETRICS metrics[243] =
|
|||
const AFM PSDRV_Courier_BoldOblique =
|
||||
{
|
||||
"Courier-BoldOblique", /* FontName */
|
||||
"Courier Bold Oblique", /* FullName */
|
||||
"Courier", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Courier Bold Oblique", /* FullName */
|
||||
L"Courier", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
TRUE, /* IsFixedPitch */
|
||||
|
|
|
@ -272,9 +272,9 @@ static const AFMMETRICS metrics[243] =
|
|||
const AFM PSDRV_Courier_Oblique =
|
||||
{
|
||||
"Courier-Oblique", /* FontName */
|
||||
"Courier Oblique", /* FullName */
|
||||
"Courier", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Courier Oblique", /* FullName */
|
||||
L"Courier", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
TRUE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica =
|
||||
{
|
||||
"Helvetica", /* FontName */
|
||||
"Helvetica", /* FullName */
|
||||
"Helvetica", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica", /* FullName */
|
||||
L"Helvetica", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Bold =
|
||||
{
|
||||
"Helvetica-Bold", /* FontName */
|
||||
"Helvetica Bold", /* FullName */
|
||||
"Helvetica", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Bold", /* FullName */
|
||||
L"Helvetica", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_BoldOblique =
|
||||
{
|
||||
"Helvetica-BoldOblique", /* FontName */
|
||||
"Helvetica Bold Oblique", /* FullName */
|
||||
"Helvetica", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Bold Oblique", /* FullName */
|
||||
L"Helvetica", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Narrow =
|
||||
{
|
||||
"Helvetica-Narrow", /* FontName */
|
||||
"Helvetica Narrow", /* FullName */
|
||||
"Helvetica Narrow", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Narrow", /* FullName */
|
||||
L"Helvetica Narrow", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Narrow_Bold =
|
||||
{
|
||||
"Helvetica-Narrow-Bold", /* FontName */
|
||||
"Helvetica Narrow Bold", /* FullName */
|
||||
"Helvetica Narrow", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Narrow Bold", /* FullName */
|
||||
L"Helvetica Narrow", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Narrow_BoldOblique =
|
||||
{
|
||||
"Helvetica-Narrow-BoldOblique", /* FontName */
|
||||
"Helvetica Narrow Bold Oblique", /* FullName */
|
||||
"Helvetica Narrow", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Narrow Bold Oblique", /* FullName */
|
||||
L"Helvetica Narrow", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Narrow_Oblique =
|
||||
{
|
||||
"Helvetica-Narrow-Oblique", /* FontName */
|
||||
"Helvetica Narrow Oblique", /* FullName */
|
||||
"Helvetica Narrow", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Narrow Oblique", /* FullName */
|
||||
L"Helvetica Narrow", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Helvetica_Oblique =
|
||||
{
|
||||
"Helvetica-Oblique", /* FontName */
|
||||
"Helvetica Oblique", /* FullName */
|
||||
"Helvetica", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Helvetica Oblique", /* FullName */
|
||||
L"Helvetica", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-12, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_NewCenturySchlbk_Bold =
|
||||
{
|
||||
"NewCenturySchlbk-Bold", /* FontName */
|
||||
"New Century Schoolbook Bold", /* FullName */
|
||||
"New Century Schoolbook", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"New Century Schoolbook Bold", /* FullName */
|
||||
L"New Century Schoolbook", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_NewCenturySchlbk_BoldItalic =
|
||||
{
|
||||
"NewCenturySchlbk-BoldItalic", /* FontName */
|
||||
"New Century Schoolbook Bold Italic", /* FullName */
|
||||
"New Century Schoolbook", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"New Century Schoolbook Bold Italic", /* FullName */
|
||||
L"New Century Schoolbook", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-16, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_NewCenturySchlbk_Italic =
|
||||
{
|
||||
"NewCenturySchlbk-Italic", /* FontName */
|
||||
"New Century Schoolbook Italic", /* FullName */
|
||||
"New Century Schoolbook", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"New Century Schoolbook Italic", /* FullName */
|
||||
L"New Century Schoolbook", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-16, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_NewCenturySchlbk_Roman =
|
||||
{
|
||||
"NewCenturySchlbk-Roman", /* FontName */
|
||||
"New Century Schoolbook Roman", /* FullName */
|
||||
"New Century Schoolbook", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"New Century Schoolbook Roman", /* FullName */
|
||||
L"New Century Schoolbook", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Palatino_Bold =
|
||||
{
|
||||
"Palatino-Bold", /* FontName */
|
||||
"Palatino Bold", /* FullName */
|
||||
"Palatino", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Palatino Bold", /* FullName */
|
||||
L"Palatino", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Palatino_BoldItalic =
|
||||
{
|
||||
"Palatino-BoldItalic", /* FontName */
|
||||
"Palatino Bold Italic", /* FullName */
|
||||
"Palatino", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Palatino Bold Italic", /* FullName */
|
||||
L"Palatino", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-10, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Palatino_Italic =
|
||||
{
|
||||
"Palatino-Italic", /* FontName */
|
||||
"Palatino Italic", /* FullName */
|
||||
"Palatino", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Palatino Italic", /* FullName */
|
||||
L"Palatino", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-10, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Palatino_Roman =
|
||||
{
|
||||
"Palatino-Roman", /* FontName */
|
||||
"Palatino Roman", /* FullName */
|
||||
"Palatino", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Palatino Roman", /* FullName */
|
||||
L"Palatino", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -217,9 +217,9 @@ static const AFMMETRICS metrics[188] =
|
|||
const AFM PSDRV_Symbol =
|
||||
{
|
||||
"Symbol", /* FontName */
|
||||
"Symbol", /* FullName */
|
||||
"Symbol", /* FamilyName */
|
||||
"FontSpecific", /* EncodingScheme */
|
||||
L"Symbol", /* FullName */
|
||||
L"Symbol", /* FamilyName */
|
||||
L"FontSpecific", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Times_Bold =
|
||||
{
|
||||
"Times-Bold", /* FontName */
|
||||
"Times Bold", /* FullName */
|
||||
"Times", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Times Bold", /* FullName */
|
||||
L"Times", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Times_BoldItalic =
|
||||
{
|
||||
"Times-BoldItalic", /* FontName */
|
||||
"Times Bold Italic", /* FullName */
|
||||
"Times", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Times Bold Italic", /* FullName */
|
||||
L"Times", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_BOLD, /* Weight */
|
||||
-15, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Times_Italic =
|
||||
{
|
||||
"Times-Italic", /* FontName */
|
||||
"Times Italic", /* FullName */
|
||||
"Times", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Times Italic", /* FullName */
|
||||
L"Times", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-15.5, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_Times_Roman =
|
||||
{
|
||||
"Times-Roman", /* FontName */
|
||||
"Times Roman", /* FullName */
|
||||
"Times", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"Times Roman", /* FullName */
|
||||
L"Times", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -257,9 +257,9 @@ static const AFMMETRICS metrics[228] =
|
|||
const AFM PSDRV_ZapfChancery_MediumItalic =
|
||||
{
|
||||
"ZapfChancery-MediumItalic", /* FontName */
|
||||
"ITC Zapf Chancery Medium Italic", /* FullName */
|
||||
"ITC Zapf Chancery", /* FamilyName */
|
||||
"AdobeStandardEncoding", /* EncodingScheme */
|
||||
L"ITC Zapf Chancery Medium Italic", /* FullName */
|
||||
L"ITC Zapf Chancery", /* FamilyName */
|
||||
L"AdobeStandardEncoding", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
-14, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -217,9 +217,9 @@ static const AFMMETRICS metrics[188] =
|
|||
const AFM PSDRV_ZapfDingbats =
|
||||
{
|
||||
"ZapfDingbats", /* FontName */
|
||||
"ITC Zapf Dingbats", /* FullName */
|
||||
"ITC Zapf Dingbats", /* FamilyName */
|
||||
"FontSpecific", /* EncodingScheme */
|
||||
L"ITC Zapf Dingbats", /* FullName */
|
||||
L"ITC Zapf Dingbats", /* FamilyName */
|
||||
L"FontSpecific", /* EncodingScheme */
|
||||
FW_NORMAL, /* Weight */
|
||||
0, /* ItalicAngle */
|
||||
FALSE, /* IsFixedPitch */
|
||||
|
|
|
@ -44,7 +44,6 @@ HFONT CDECL PSDRV_SelectFont( PHYSDEV dev, HFONT hfont, UINT *aa_flags )
|
|||
HFONT ret;
|
||||
LOGFONTW lf;
|
||||
BOOL subst = FALSE;
|
||||
char FaceName[LF_FACESIZE];
|
||||
|
||||
if (!GetObjectW( hfont, sizeof(lf), &lf )) return 0;
|
||||
|
||||
|
@ -54,36 +53,33 @@ HFONT CDECL PSDRV_SelectFont( PHYSDEV dev, HFONT hfont, UINT *aa_flags )
|
|||
debugstr_w(lf.lfFaceName), lf.lfHeight, lf.lfItalic,
|
||||
lf.lfWeight);
|
||||
|
||||
WideCharToMultiByte(CP_ACP, 0, lf.lfFaceName, -1,
|
||||
FaceName, sizeof(FaceName), NULL, NULL);
|
||||
|
||||
if(FaceName[0] == '\0') {
|
||||
if(lf.lfFaceName[0] == '\0') {
|
||||
switch(lf.lfPitchAndFamily & 0xf0) {
|
||||
case FF_DONTCARE:
|
||||
break;
|
||||
case FF_ROMAN:
|
||||
case FF_SCRIPT:
|
||||
strcpy(FaceName, "Times");
|
||||
wcscpy(lf.lfFaceName, L"Times");
|
||||
break;
|
||||
case FF_SWISS:
|
||||
strcpy(FaceName, "Helvetica");
|
||||
wcscpy(lf.lfFaceName, L"Helvetica");
|
||||
break;
|
||||
case FF_MODERN:
|
||||
strcpy(FaceName, "Courier");
|
||||
wcscpy(lf.lfFaceName, L"Courier");
|
||||
break;
|
||||
case FF_DECORATIVE:
|
||||
strcpy(FaceName, "Symbol");
|
||||
wcscpy(lf.lfFaceName, L"Symbol");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
if(FaceName[0] == '\0') {
|
||||
if(lf.lfFaceName[0] == '\0') {
|
||||
switch(lf.lfPitchAndFamily & 0x0f) {
|
||||
case VARIABLE_PITCH:
|
||||
strcpy(FaceName, "Times");
|
||||
wcscpy(lf.lfFaceName, L"Times");
|
||||
break;
|
||||
default:
|
||||
strcpy(FaceName, "Courier");
|
||||
wcscpy(lf.lfFaceName, L"Courier");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -94,21 +90,19 @@ HFONT CDECL PSDRV_SelectFont( PHYSDEV dev, HFONT hfont, UINT *aa_flags )
|
|||
|
||||
for (i = 0; i < physDev->pi->FontSubTableSize; ++i)
|
||||
{
|
||||
if (!stricmp (FaceName,
|
||||
if (!wcsicmp (lf.lfFaceName,
|
||||
physDev->pi->FontSubTable[i].pValueName))
|
||||
{
|
||||
TRACE ("substituting facename '%s' for '%s'\n",
|
||||
(LPSTR) physDev->pi->FontSubTable[i].pData, FaceName);
|
||||
if (strlen ((LPSTR) physDev->pi->FontSubTable[i].pData) <
|
||||
LF_FACESIZE)
|
||||
TRACE("substituting facename %s for %s\n",
|
||||
debugstr_w((WCHAR *)physDev->pi->FontSubTable[i].pData), debugstr_w(lf.lfFaceName));
|
||||
if (wcslen((WCHAR *)physDev->pi->FontSubTable[i].pData) < LF_FACESIZE)
|
||||
{
|
||||
strcpy (FaceName,
|
||||
(LPSTR) physDev->pi->FontSubTable[i].pData);
|
||||
wcscpy(lf.lfFaceName, (WCHAR *)physDev->pi->FontSubTable[i].pData);
|
||||
subst = TRUE;
|
||||
}
|
||||
else
|
||||
WARN ("Facename '%s' is too long; ignoring substitution\n",
|
||||
(LPSTR) physDev->pi->FontSubTable[i].pData);
|
||||
WARN("Facename %s is too long; ignoring substitution\n",
|
||||
debugstr_w((WCHAR *)physDev->pi->FontSubTable[i].pData));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -123,7 +117,7 @@ HFONT CDECL PSDRV_SelectFont( PHYSDEV dev, HFONT hfont, UINT *aa_flags )
|
|||
return ret;
|
||||
}
|
||||
|
||||
PSDRV_SelectBuiltinFont(dev, hfont, &lf, FaceName);
|
||||
PSDRV_SelectBuiltinFont(dev, hfont, &lf, lf.lfFaceName);
|
||||
next->funcs->pSelectFont( next, 0, aa_flags ); /* tell next driver that we selected a device font */
|
||||
return hfont;
|
||||
}
|
||||
|
|
|
@ -459,21 +459,21 @@ BOOL CDECL PSDRV_ResetDC( PHYSDEV dev, const DEVMODEW *lpInitData )
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static PRINTER_ENUM_VALUESA *load_font_sub_table( HANDLE printer, DWORD *num_entries )
|
||||
static PRINTER_ENUM_VALUESW *load_font_sub_table( HANDLE printer, DWORD *num_entries )
|
||||
{
|
||||
DWORD res, needed, num;
|
||||
PRINTER_ENUM_VALUESA *table = NULL;
|
||||
static const char fontsubkey[] = "PrinterDriverData\\FontSubTable";
|
||||
PRINTER_ENUM_VALUESW *table = NULL;
|
||||
static const WCHAR fontsubkey[] = L"PrinterDriverData\\FontSubTable";
|
||||
|
||||
*num_entries = 0;
|
||||
|
||||
res = EnumPrinterDataExA( printer, fontsubkey, NULL, 0, &needed, &num );
|
||||
res = EnumPrinterDataExW( printer, fontsubkey, NULL, 0, &needed, &num );
|
||||
if (res != ERROR_MORE_DATA) return NULL;
|
||||
|
||||
table = HeapAlloc( PSDRV_Heap, 0, needed );
|
||||
if (!table) return NULL;
|
||||
|
||||
res = EnumPrinterDataExA( printer, fontsubkey, (LPBYTE)table, needed, &needed, &num );
|
||||
res = EnumPrinterDataExW( printer, fontsubkey, (LPBYTE)table, needed, &needed, &num );
|
||||
if (res != ERROR_SUCCESS)
|
||||
{
|
||||
HeapFree( PSDRV_Heap, 0, table );
|
||||
|
@ -579,7 +579,7 @@ PRINTERINFO *PSDRV_FindPrinterInfo(LPCWSTR name)
|
|||
BOOL using_default_devmode = FALSE;
|
||||
int len;
|
||||
|
||||
TRACE("'%s'\n", debugstr_w(name));
|
||||
TRACE("%s\n", debugstr_w(name));
|
||||
|
||||
LIST_FOR_EACH_ENTRY( pi, &printer_list, PRINTERINFO, entry )
|
||||
{
|
||||
|
@ -659,7 +659,7 @@ PRINTERINFO *PSDRV_FindPrinterInfo(LPCWSTR name)
|
|||
afm = PSDRV_FindAFMinList(PSDRV_AFMFontList, font->Name);
|
||||
if(!afm) {
|
||||
TRACE( "Couldn't find AFM file for installed printer font '%s' - "
|
||||
"ignoring\n", font->Name);
|
||||
"ignoring\n", font->Name);
|
||||
}
|
||||
else {
|
||||
BOOL added;
|
||||
|
|
|
@ -1091,7 +1091,7 @@ PPD *PSDRV_ParsePPD( const WCHAR *fname, HANDLE printer )
|
|||
TRACE("'%s'\n", fn->Name);
|
||||
|
||||
LIST_FOR_EACH_ENTRY(page, &ppd->PageSizes, PAGESIZE, entry) {
|
||||
TRACE("'%s' aka '%s' (%d) invoked by '%s'\n", page->Name,
|
||||
TRACE("'%s' aka %s (%d) invoked by '%s'\n", page->Name,
|
||||
debugstr_w(page->FullName), page->WinPage, page->InvocationString);
|
||||
if(page->ImageableArea)
|
||||
TRACE("Area = %.2f,%.2f - %.2f, %.2f\n",
|
||||
|
|
|
@ -81,10 +81,10 @@ typedef struct {
|
|||
} WINMETRICS;
|
||||
|
||||
typedef struct _tagAFM {
|
||||
LPCSTR FontName;
|
||||
LPCSTR FullName;
|
||||
LPCSTR FamilyName;
|
||||
LPCSTR EncodingScheme;
|
||||
const char *FontName;
|
||||
const WCHAR *FullName;
|
||||
const WCHAR *FamilyName;
|
||||
const WCHAR *EncodingScheme;
|
||||
LONG Weight; /* FW_NORMAL etc. */
|
||||
float ItalicAngle;
|
||||
BOOL IsFixedPitch;
|
||||
|
@ -109,7 +109,7 @@ typedef struct _tagAFMLISTENTRY {
|
|||
} AFMLISTENTRY;
|
||||
|
||||
typedef struct _tagFONTFAMILY {
|
||||
char *FamilyName; /* family name */
|
||||
WCHAR *FamilyName; /* family name */
|
||||
AFMLISTENTRY *afmlist; /* list of afms for this family */
|
||||
struct _tagFONTFAMILY *next; /* next family */
|
||||
} FONTFAMILY;
|
||||
|
@ -243,7 +243,7 @@ typedef struct
|
|||
PPD *ppd;
|
||||
PSDRV_DEVMODE *Devmode;
|
||||
FONTFAMILY *Fonts;
|
||||
PPRINTER_ENUM_VALUESA FontSubTable;
|
||||
PPRINTER_ENUM_VALUESW FontSubTable;
|
||||
DWORD FontSubTableSize;
|
||||
} PRINTERINFO;
|
||||
|
||||
|
@ -545,7 +545,7 @@ const AFMMETRICS *PSDRV_UVMetrics(LONG UV, const AFM *afm) DECLSPEC_HIDDEN;
|
|||
SHORT PSDRV_CalcAvgCharWidth(const AFM *afm) DECLSPEC_HIDDEN;
|
||||
|
||||
extern BOOL PSDRV_SelectBuiltinFont(PHYSDEV dev, HFONT hfont,
|
||||
LOGFONTW *plf, LPSTR FaceName) DECLSPEC_HIDDEN;
|
||||
LOGFONTW *plf, WCHAR *face_name) DECLSPEC_HIDDEN;
|
||||
extern BOOL PSDRV_WriteSetBuiltinFont(PHYSDEV dev) DECLSPEC_HIDDEN;
|
||||
extern BOOL PSDRV_WriteBuiltinGlyphShow(PHYSDEV dev, LPCWSTR str, INT count) DECLSPEC_HIDDEN;
|
||||
|
||||
|
|
|
@ -319,6 +319,32 @@ static BOOL ReadString(FILE *file, CHAR buffer[], INT bufsize, LPCSTR key,
|
|||
return TRUE;
|
||||
}
|
||||
|
||||
static BOOL ReadStringW(FILE *file, CHAR *buffer, int size, const char *key, WCHAR **out)
|
||||
{
|
||||
char *outA;
|
||||
int len;
|
||||
|
||||
if (!ReadString(file, buffer, size, key, &outA))
|
||||
return FALSE;
|
||||
if (!outA)
|
||||
{
|
||||
*out = NULL;
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
len = MultiByteToWideChar(CP_ACP, 0, outA, -1, NULL, 0);
|
||||
if (len)
|
||||
*out = HeapAlloc(PSDRV_Heap, 0, len * sizeof(WCHAR));
|
||||
if (!len || !*out)
|
||||
{
|
||||
HeapFree(PSDRV_Heap, 0, outA);
|
||||
return FALSE;
|
||||
}
|
||||
MultiByteToWideChar(CP_ACP, 0, outA, -1, *out, len);
|
||||
HeapFree(PSDRV_Heap, 0, outA);
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
/*******************************************************************************
|
||||
* ReadBBox
|
||||
*
|
||||
|
@ -851,7 +877,7 @@ static VOID Unicodify(AFM *afm, OLD_AFMMETRICS *metrics)
|
|||
{
|
||||
INT i;
|
||||
|
||||
if (strcmp(afm->EncodingScheme, "FontSpecific") == 0)
|
||||
if (wcscmp(afm->EncodingScheme, L"FontSpecific") == 0)
|
||||
{
|
||||
for (i = 0; i < afm->NumofMetrics; ++i)
|
||||
{
|
||||
|
@ -1028,8 +1054,9 @@ static BOOL BuildAFM(FILE *file)
|
|||
CHAR buffer[258]; /* allow for <cr>, <lf>, and <nul> */
|
||||
AFM *afm;
|
||||
AFMMETRICS *metrics;
|
||||
LPSTR font_name, full_name, family_name, encoding_scheme;
|
||||
BOOL retval, added;
|
||||
WCHAR *full_name, *family_name, *encoding_scheme;
|
||||
char *font_name;
|
||||
BOOL retval, added;
|
||||
|
||||
retval = ReadFontMetrics(file, buffer, sizeof(buffer), &afm);
|
||||
if (retval == FALSE || afm == NULL)
|
||||
|
@ -1039,16 +1066,16 @@ static BOOL BuildAFM(FILE *file)
|
|||
if (retval == FALSE || font_name == NULL)
|
||||
goto cleanup_afm;
|
||||
|
||||
retval = ReadString(file, buffer, sizeof(buffer), "FullName", &full_name);
|
||||
retval = ReadStringW(file, buffer, sizeof(buffer), "FullName", &full_name);
|
||||
if (retval == FALSE || full_name == NULL)
|
||||
goto cleanup_font_name;
|
||||
|
||||
retval = ReadString(file, buffer, sizeof(buffer), "FamilyName",
|
||||
retval = ReadStringW(file, buffer, sizeof(buffer), "FamilyName",
|
||||
&family_name);
|
||||
if (retval == FALSE || family_name == NULL)
|
||||
goto cleanup_full_name;
|
||||
|
||||
retval = ReadString(file, buffer, sizeof(buffer), "EncodingScheme",
|
||||
retval = ReadStringW(file, buffer, sizeof(buffer), "EncodingScheme",
|
||||
&encoding_scheme);
|
||||
if (retval == FALSE || encoding_scheme == NULL)
|
||||
goto cleanup_family_name;
|
||||
|
|
Loading…
Reference in a new issue