diff src/objects-x.c @ 14:9ee227acff29 r19-15b90

Import from CVS: tag r19-15b90
author cvs
date Mon, 13 Aug 2007 08:48:42 +0200
parents ac2d302a0011
children 131b0175ea99
line wrap: on
line diff
--- a/src/objects-x.c	Mon Aug 13 08:48:18 2007 +0200
+++ b/src/objects-x.c	Mon Aug 13 08:48:42 2007 +0200
@@ -154,8 +154,8 @@
   int result;
 
   result = x_parse_nearest_color (XDEVICE (device), &color,
-				  string_data (XSTRING (name)),
-				  string_length (XSTRING (name)),
+				  XSTRING_DATA   (name),
+				  XSTRING_LENGTH (name),
 				  errb);
 
   if (!result)
@@ -287,7 +287,8 @@
   f->descent = xf->descent;
   f->height = xf->ascent + xf->descent;
   {
-    unsigned int def_char = xf->default_char;
+    /* following change suggested by Ted Phelps <phelps@dstc.edu.au> */
+    unsigned int def_char = 'n'; /*xf->default_char;*/
     int byte1, byte2;
 
   once_more:
@@ -315,11 +316,11 @@
        0 width too (unlikely) then just use the max width. */
     if (f->width == 0)
       {
-	if (def_char == 'n')
+	if (def_char == xf->default_char)
 	  f->width = xf->max_bounds.width;
 	else
 	  {
-	    def_char = 'n';
+	    def_char = xf->default_char;
 	    goto once_more;
 	  }
       }
@@ -667,8 +668,7 @@
   if (NILP (FONT_INSTANCE_X_TRUENAME (f)))
     {
       Display *dpy = DEVICE_X_DISPLAY (d);
-      char *name =
-	(char *) string_data (XSTRING (f->name));
+      char *name = (char *) XSTRING_DATA (f->name);
       {
 	FONT_INSTANCE_X_TRUENAME (f) =
 	  x_font_truename (dpy, name, FONT_INSTANCE_X_FONT (f));