1
0
mirror of https://github.com/gryf/wmaker.git synced 2026-01-07 22:34:18 +01:00

- Changed ConvertFont et al. to WMEmphasizeFont, and added WMNormalizeFont()

This commit is contained in:
nwanua
2000-11-04 03:47:39 +00:00
parent 731656cbed
commit d00e72bc45
2 changed files with 26 additions and 13 deletions

View File

@@ -691,15 +691,15 @@ WMFont *WMBoldSystemFontOfSize(WMScreen *scrPtr, int size);
XFontSet WMGetFontFontSet(WMFont *font);
WMFont * WMConvertFontToPlain(WMScreen *scr, WMFont *font);
WMFont * WMNormalizeFont(WMScreen *scr, WMFont *font);
WMFont * WMConvertFontToBold(WMScreen *scr, WMFont *font);
WMFont * WMStrengthenFont(WMScreen *scr, WMFont *font);
WMFont * WMConvertFontToUnbold(WMScreen *scr, WMFont *font);
WMFont * WMUnstrengthenFont(WMScreen *scr, WMFont *font);
WMFont * WMConvertFontToItalic(WMScreen *scr, WMFont *font);
WMFont * WMEmphasizeFont(WMScreen *scr, WMFont *font);
WMFont * WMConvertFontToUnitalic(WMScreen *scr, WMFont *font);
WMFont * WMUnemphasizeFont(WMScreen *scr, WMFont *font);
WMFont * WMGetFontOfSize(WMScreen *scr, WMFont *font, int size);

View File

@@ -479,16 +479,28 @@ changeFontProp(char *fname, char *newprop, int which)
WMFont *
WMConvertFontToPlain(WMScreen *scr, WMFont *font)
{
WMNormalizeFont(WMScreen *scr, WMFont *font)
{
WMFont *newfont=NULL;
char fname[256];
if(!scr || !font)
return NULL;
return font;
snprintf(fname, 255, font->name);
changeFontProp(fname, "medium", 2);
changeFontProp(fname, "r", 3);
newfont = WMCreateNormalFont(scr, fname);
if(!newfont)
return NULL;
return newfont;
}
WMFont *
WMConvertFontToBold(WMScreen *scr, WMFont *font)
WMStrengthenFont(WMScreen *scr, WMFont *font)
{
WMFont *newfont=NULL;
char fname[256];
@@ -508,7 +520,7 @@ WMConvertFontToBold(WMScreen *scr, WMFont *font)
WMFont *
WMConvertFontToUnbold(WMScreen *scr, WMFont *font)
WMUnstrengthenFont(WMScreen *scr, WMFont *font)
{
WMFont *newfont=NULL;
char fname[256];
@@ -528,7 +540,7 @@ WMConvertFontToUnbold(WMScreen *scr, WMFont *font)
WMFont *
WMConvertFontToItalic(WMScreen *scr, WMFont *font)
WMEmphasizeFont(WMScreen *scr, WMFont *font)
{
WMFont *newfont=NULL;
char fname[256];
@@ -546,8 +558,9 @@ WMConvertFontToItalic(WMScreen *scr, WMFont *font)
return newfont;
}
WMFont *
WMConvertFontToUnitalic(WMScreen *scr, WMFont *font)
WMUnemphasizeFont(WMScreen *scr, WMFont *font)
{
WMFont *newfont=NULL;
char fname[256];