[Commit] fontconfig/src fcfreetype.c,1.28,1.29

Keith Packard commit@keithp.com
Thu, 01 May 2003 07:31:07 -0700


Committed by: keithp

Update of /local/src/CVS/fontconfig/src
In directory home.keithp.com:/tmp/cvs-serv19695

Modified Files:
	fcfreetype.c 
Log Message:
Add demi and book postscript weight names.  Allow spaces in postscript and X matching


Index: fcfreetype.c
===================================================================
RCS file: /local/src/CVS/fontconfig/src/fcfreetype.c,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- fcfreetype.c	30 Apr 2003 15:17:42 -0000	1.28
+++ fcfreetype.c	1 May 2003 14:31:04 -0000	1.29
@@ -747,10 +747,12 @@
 		{ "extralight",		FC_WEIGHT_EXTRALIGHT },
 		{ "ultralight",		FC_WEIGHT_ULTRALIGHT },
 		{ "light",		FC_WEIGHT_LIGHT },
+		{ "book",		FC_WEIGHT_BOOK },
 		{ "regular",		FC_WEIGHT_REGULAR },
 		{ "normal",		FC_WEIGHT_NORMAL },
 		{ "medium",		FC_WEIGHT_MEDIUM },
 		{ "demibold",		FC_WEIGHT_DEMIBOLD },
+		{ "demi",		FC_WEIGHT_DEMIBOLD },
 		{ "semibold",		FC_WEIGHT_SEMIBOLD },
 		{ "bold",		FC_WEIGHT_BOLD },
 		{ "extrabold",		FC_WEIGHT_EXTRABOLD },
@@ -761,7 +763,7 @@
 #define NUM_PS_WEIGHTS	(sizeof (ps_weights) / sizeof (ps_weights[0]))
 	    int	w;
 	    for (w = 0; w < NUM_PS_WEIGHTS; w++)
-		if (!FcStrCmpIgnoreCase ((FcChar8 *) ps_weights[w].name,
+		if (!FcStrCmpIgnoreBlanksAndCase ((FcChar8 *) ps_weights[w].name,
 					 (FcChar8 *) psfontinfo.weight))
 		{
 		    weight = ps_weights[w].value;
@@ -845,7 +847,7 @@
 	    if (FcDebug () & FC_DBG_SCANV)
 		printf ("\nsetwidth: %s\n", prop.u.atom);
 	    for (i = 0; i < sizeof (FcSetWidths) / sizeof (FcSetWidths[0]); i++)
-		if (!FcStrCmpIgnoreCase ((FcChar8 *) prop.u.atom,
+		if (!FcStrCmpIgnoreBlanksAndCase ((FcChar8 *) prop.u.atom,
 					 FcSetWidths[i].width_name))
 		{
 		    width = FcSetWidths[i].width;