Chapter 13. Examples of I18N
98
XFontStruct **xfonts;
char **font_names;
register int i;
int ascent;
int descent;
int fnum;
char *basename2;
if (use_fontset) {
if (font >fontset != NULL){
XFreeFontSet(dpy, font >fontset);
}
basename2 = (char *)malloc(strlen(font >name) + 3);
if (basename2) sprintf(basename2, "%s,*", font >name);
else basename2 = font >name;
if( (font >fontset = XCreateFontSet(dpy, basename2,
&missing_charset_list_return,
&missing_charset_count_return,
&def_string_return)) == NULL) {
fprintf (stderr, "%s:
unable to open fontset \"%s\"\n",
ProgramName, font >name);
exit(1);
}
if (basename2 != font >name) free(basename2);
for(i=0; i
printf("%s: warning: font for charset %s is lacking.\n",
ProgramName, missing_charset_list_return[i]);
}
font_extents = XExtentsOfFontSet(font >fontset);
fnum = XFontsOfFontSet(font >fontset, &xfonts, &font_names);
for( i = 0, ascent = 0, descent = 0; i
if (ascent < (*xfonts) >ascent) ascent = (*xfonts) >ascent;
if (descent < (*xfonts) >descent) descent = (*xfonts) >descent;
xfonts++;
}
font >height = font_extents >max_logical_extent.height;
font >y = ascent;
font >ascent = ascent;
font >descent = descent;
return;






footer




 

 

 

 

 Home | About Us | Network | Services | Support | FAQ | Control Panel | Order Online | Sitemap | Contact

indiana web hosting

 

Our partners: PHP: Hypertext Preprocessor Best Web Hosting Java Web Hosting Inexpensive Web Hosting  Jsp Web Hosting

Cheapest Web Hosting Jsp Hosting Cheap Hosting

Visionwebhosting.net Business web hosting division of Web Design Plus. All rights reserved