comparison src/objects.c @ 440:8de8e3f6228a r21-2-28

Import from CVS: tag r21-2-28
author cvs
date Mon, 13 Aug 2007 11:33:38 +0200
parents 3ecd8885ac67
children abe6d1db359e
comparison
equal deleted inserted replaced
439:357dd071b03c 440:8de8e3f6228a
57 Lisp_Object Qcolor_instancep; 57 Lisp_Object Qcolor_instancep;
58 58
59 static Lisp_Object 59 static Lisp_Object
60 mark_color_instance (Lisp_Object obj) 60 mark_color_instance (Lisp_Object obj)
61 { 61 {
62 struct Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj); 62 Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj);
63 mark_object (c->name); 63 mark_object (c->name);
64 if (!NILP (c->device)) /* Vthe_null_color_instance */ 64 if (!NILP (c->device)) /* Vthe_null_color_instance */
65 MAYBE_DEVMETH (XDEVICE (c->device), mark_color_instance, (c)); 65 MAYBE_DEVMETH (XDEVICE (c->device), mark_color_instance, (c));
66 66
67 return c->device; 67 return c->device;
70 static void 70 static void
71 print_color_instance (Lisp_Object obj, Lisp_Object printcharfun, 71 print_color_instance (Lisp_Object obj, Lisp_Object printcharfun,
72 int escapeflag) 72 int escapeflag)
73 { 73 {
74 char buf[100]; 74 char buf[100];
75 struct Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj); 75 Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj);
76 if (print_readably) 76 if (print_readably)
77 error ("printing unreadable object #<color-instance 0x%x>", 77 error ("printing unreadable object #<color-instance 0x%x>",
78 c->header.uid); 78 c->header.uid);
79 write_c_string ("#<color-instance ", printcharfun); 79 write_c_string ("#<color-instance ", printcharfun);
80 print_internal (c->name, printcharfun, 0); 80 print_internal (c->name, printcharfun, 0);
88 } 88 }
89 89
90 static void 90 static void
91 finalize_color_instance (void *header, int for_disksave) 91 finalize_color_instance (void *header, int for_disksave)
92 { 92 {
93 struct Lisp_Color_Instance *c = (struct Lisp_Color_Instance *) header; 93 Lisp_Color_Instance *c = (Lisp_Color_Instance *) header;
94 94
95 if (!NILP (c->device)) 95 if (!NILP (c->device))
96 { 96 {
97 if (for_disksave) finalose (c); 97 if (for_disksave) finalose (c);
98 MAYBE_DEVMETH (XDEVICE (c->device), finalize_color_instance, (c)); 98 MAYBE_DEVMETH (XDEVICE (c->device), finalize_color_instance, (c));
100 } 100 }
101 101
102 static int 102 static int
103 color_instance_equal (Lisp_Object obj1, Lisp_Object obj2, int depth) 103 color_instance_equal (Lisp_Object obj1, Lisp_Object obj2, int depth)
104 { 104 {
105 struct Lisp_Color_Instance *c1 = XCOLOR_INSTANCE (obj1); 105 Lisp_Color_Instance *c1 = XCOLOR_INSTANCE (obj1);
106 struct Lisp_Color_Instance *c2 = XCOLOR_INSTANCE (obj2); 106 Lisp_Color_Instance *c2 = XCOLOR_INSTANCE (obj2);
107 107
108 return (c1 == c2) || 108 return (c1 == c2) ||
109 (EQ (c1->device, c2->device) && 109 (EQ (c1->device, c2->device) &&
110 DEVICEP (c1->device) && 110 DEVICEP (c1->device) &&
111 HAS_DEVMETH_P (XDEVICE (c1->device), color_instance_equal) && 111 HAS_DEVMETH_P (XDEVICE (c1->device), color_instance_equal) &&
113 } 113 }
114 114
115 static unsigned long 115 static unsigned long
116 color_instance_hash (Lisp_Object obj, int depth) 116 color_instance_hash (Lisp_Object obj, int depth)
117 { 117 {
118 struct Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj); 118 Lisp_Color_Instance *c = XCOLOR_INSTANCE (obj);
119 struct device *d = DEVICEP (c->device) ? XDEVICE (c->device) : 0; 119 struct device *d = DEVICEP (c->device) ? XDEVICE (c->device) : 0;
120 120
121 return HASH2 ((unsigned long) d, 121 return HASH2 ((unsigned long) d,
122 !d ? LISP_HASH (obj) 122 !d ? LISP_HASH (obj)
123 : DEVMETH_OR_GIVEN (d, color_instance_hash, (c, depth), 123 : DEVMETH_OR_GIVEN (d, color_instance_hash, (c, depth),
126 126
127 DEFINE_LRECORD_IMPLEMENTATION ("color-instance", color_instance, 127 DEFINE_LRECORD_IMPLEMENTATION ("color-instance", color_instance,
128 mark_color_instance, print_color_instance, 128 mark_color_instance, print_color_instance,
129 finalize_color_instance, color_instance_equal, 129 finalize_color_instance, color_instance_equal,
130 color_instance_hash, 0, 130 color_instance_hash, 0,
131 struct Lisp_Color_Instance); 131 Lisp_Color_Instance);
132 132
133 DEFUN ("make-color-instance", Fmake_color_instance, 1, 3, 0, /* 133 DEFUN ("make-color-instance", Fmake_color_instance, 1, 3, 0, /*
134 Return a new `color-instance' object named NAME (a string). 134 Return a new `color-instance' object named NAME (a string).
135 135
136 Optional argument DEVICE specifies the device this object applies to 136 Optional argument DEVICE specifies the device this object applies to
147 these objects are GCed, the underlying window-system data (e.g. X object) 147 these objects are GCed, the underlying window-system data (e.g. X object)
148 is deallocated as well. 148 is deallocated as well.
149 */ 149 */
150 (name, device, no_error)) 150 (name, device, no_error))
151 { 151 {
152 struct Lisp_Color_Instance *c; 152 Lisp_Color_Instance *c;
153 Lisp_Object val; 153 Lisp_Object val;
154 int retval; 154 int retval;
155 155
156 CHECK_STRING (name); 156 CHECK_STRING (name);
157 XSETDEVICE (device, decode_device (device)); 157 XSETDEVICE (device, decode_device (device));
158 158
159 c = alloc_lcrecord_type (struct Lisp_Color_Instance, &lrecord_color_instance); 159 c = alloc_lcrecord_type (Lisp_Color_Instance, &lrecord_color_instance);
160 c->name = name; 160 c->name = name;
161 c->device = device; 161 c->device = device;
162 c->data = 0; 162 c->data = 0;
163 163
164 retval = MAYBE_INT_DEVMETH (XDEVICE (device), initialize_color_instance, 164 retval = MAYBE_INT_DEVMETH (XDEVICE (device), initialize_color_instance,
193 color components of COLOR-INSTANCE, or nil if unknown. 193 color components of COLOR-INSTANCE, or nil if unknown.
194 Component values range from 0 to 65535. 194 Component values range from 0 to 65535.
195 */ 195 */
196 (color_instance)) 196 (color_instance))
197 { 197 {
198 struct Lisp_Color_Instance *c; 198 Lisp_Color_Instance *c;
199 199
200 CHECK_COLOR_INSTANCE (color_instance); 200 CHECK_COLOR_INSTANCE (color_instance);
201 c = XCOLOR_INSTANCE (color_instance); 201 c = XCOLOR_INSTANCE (color_instance);
202 202
203 if (NILP (c->device)) 203 if (NILP (c->device))
237 Error_behavior errb); 237 Error_behavior errb);
238 238
239 static Lisp_Object 239 static Lisp_Object
240 mark_font_instance (Lisp_Object obj) 240 mark_font_instance (Lisp_Object obj)
241 { 241 {
242 struct Lisp_Font_Instance *f = XFONT_INSTANCE (obj); 242 Lisp_Font_Instance *f = XFONT_INSTANCE (obj);
243 243
244 mark_object (f->name); 244 mark_object (f->name);
245 if (!NILP (f->device)) /* Vthe_null_font_instance */ 245 if (!NILP (f->device)) /* Vthe_null_font_instance */
246 MAYBE_DEVMETH (XDEVICE (f->device), mark_font_instance, (f)); 246 MAYBE_DEVMETH (XDEVICE (f->device), mark_font_instance, (f));
247 247
250 250
251 static void 251 static void
252 print_font_instance (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag) 252 print_font_instance (Lisp_Object obj, Lisp_Object printcharfun, int escapeflag)
253 { 253 {
254 char buf[200]; 254 char buf[200];
255 struct Lisp_Font_Instance *f = XFONT_INSTANCE (obj); 255 Lisp_Font_Instance *f = XFONT_INSTANCE (obj);
256 if (print_readably) 256 if (print_readably)
257 error ("printing unreadable object #<font-instance 0x%x>", f->header.uid); 257 error ("printing unreadable object #<font-instance 0x%x>", f->header.uid);
258 write_c_string ("#<font-instance ", printcharfun); 258 write_c_string ("#<font-instance ", printcharfun);
259 print_internal (f->name, printcharfun, 1); 259 print_internal (f->name, printcharfun, 1);
260 write_c_string (" on ", printcharfun); 260 write_c_string (" on ", printcharfun);
267 } 267 }
268 268
269 static void 269 static void
270 finalize_font_instance (void *header, int for_disksave) 270 finalize_font_instance (void *header, int for_disksave)
271 { 271 {
272 struct Lisp_Font_Instance *f = (struct Lisp_Font_Instance *) header; 272 Lisp_Font_Instance *f = (Lisp_Font_Instance *) header;
273 273
274 if (!NILP (f->device)) 274 if (!NILP (f->device))
275 { 275 {
276 if (for_disksave) finalose (f); 276 if (for_disksave) finalose (f);
277 MAYBE_DEVMETH (XDEVICE (f->device), finalize_font_instance, (f)); 277 MAYBE_DEVMETH (XDEVICE (f->device), finalize_font_instance, (f));
299 } 299 }
300 300
301 DEFINE_LRECORD_IMPLEMENTATION ("font-instance", font_instance, 301 DEFINE_LRECORD_IMPLEMENTATION ("font-instance", font_instance,
302 mark_font_instance, print_font_instance, 302 mark_font_instance, print_font_instance,
303 finalize_font_instance, font_instance_equal, 303 finalize_font_instance, font_instance_equal,
304 font_instance_hash, 0, struct Lisp_Font_Instance); 304 font_instance_hash, 0, Lisp_Font_Instance);
305 305
306 DEFUN ("make-font-instance", Fmake_font_instance, 1, 3, 0, /* 306 DEFUN ("make-font-instance", Fmake_font_instance, 1, 3, 0, /*
307 Return a new `font-instance' object named NAME. 307 Return a new `font-instance' object named NAME.
308 DEVICE specifies the device this object applies to and defaults to the 308 DEVICE specifies the device this object applies to and defaults to the
309 selected device. An error is signalled if the font is unknown or cannot 309 selected device. An error is signalled if the font is unknown or cannot
315 you drop all pointers to it and allow it to be garbage collected. When 315 you drop all pointers to it and allow it to be garbage collected. When
316 these objects are GCed, the underlying X data is deallocated as well. 316 these objects are GCed, the underlying X data is deallocated as well.
317 */ 317 */
318 (name, device, no_error)) 318 (name, device, no_error))
319 { 319 {
320 struct Lisp_Font_Instance *f; 320 Lisp_Font_Instance *f;
321 Lisp_Object val; 321 Lisp_Object val;
322 int retval = 0; 322 int retval = 0;
323 Error_behavior errb = decode_error_behavior_flag (no_error); 323 Error_behavior errb = decode_error_behavior_flag (no_error);
324 324
325 if (ERRB_EQ (errb, ERROR_ME)) 325 if (ERRB_EQ (errb, ERROR_ME))
327 else if (!STRINGP (name)) 327 else if (!STRINGP (name))
328 return Qnil; 328 return Qnil;
329 329
330 XSETDEVICE (device, decode_device (device)); 330 XSETDEVICE (device, decode_device (device));
331 331
332 f = alloc_lcrecord_type (struct Lisp_Font_Instance, &lrecord_font_instance); 332 f = alloc_lcrecord_type (Lisp_Font_Instance, &lrecord_font_instance);
333 f->name = name; 333 f->name = name;
334 f->device = device; 334 f->device = device;
335 335
336 f->data = 0; 336 f->data = 0;
337 337
415 415
416 static Lisp_Object 416 static Lisp_Object
417 font_instance_truename_internal (Lisp_Object font_instance, 417 font_instance_truename_internal (Lisp_Object font_instance,
418 Error_behavior errb) 418 Error_behavior errb)
419 { 419 {
420 struct Lisp_Font_Instance *f = XFONT_INSTANCE (font_instance); 420 Lisp_Font_Instance *f = XFONT_INSTANCE (font_instance);
421 421
422 if (NILP (f->device)) 422 if (NILP (f->device))
423 { 423 {
424 maybe_signal_simple_error ("Couldn't determine font truename", 424 maybe_signal_simple_error ("Couldn't determine font truename",
425 font_instance, Qfont, errb); 425 font_instance, Qfont, errb);
426 return Qnil; 426 return Qnil;
427 } 427 }
428 428
429 return DEVMETH_OR_GIVEN (XDEVICE (f->device), 429 return DEVMETH_OR_GIVEN (XDEVICE (f->device),
430 font_instance_truename, (f, errb), f->name); 430 font_instance_truename, (f, errb), f->name);
431 } 431 }
432 432
433 DEFUN ("font-instance-truename", Ffont_instance_truename, 1, 1, 0, /* 433 DEFUN ("font-instance-truename", Ffont_instance_truename, 1, 1, 0, /*
445 DEFUN ("font-instance-properties", Ffont_instance_properties, 1, 1, 0, /* 445 DEFUN ("font-instance-properties", Ffont_instance_properties, 1, 1, 0, /*
446 Return the properties (an alist or nil) of FONT-INSTANCE. 446 Return the properties (an alist or nil) of FONT-INSTANCE.
447 */ 447 */
448 (font_instance)) 448 (font_instance))
449 { 449 {
450 struct Lisp_Font_Instance *f; 450 Lisp_Font_Instance *f;
451 451
452 CHECK_FONT_INSTANCE (font_instance); 452 CHECK_FONT_INSTANCE (font_instance);
453 f = XFONT_INSTANCE (font_instance); 453 f = XFONT_INSTANCE (font_instance);
454 454
455 if (NILP (f->device)) 455 if (NILP (f->device))
480 /* Qcolor defined in general.c */ 480 /* Qcolor defined in general.c */
481 481
482 static void 482 static void
483 color_create (Lisp_Object obj) 483 color_create (Lisp_Object obj)
484 { 484 {
485 struct Lisp_Specifier *color = XCOLOR_SPECIFIER (obj); 485 Lisp_Specifier *color = XCOLOR_SPECIFIER (obj);
486 486
487 COLOR_SPECIFIER_FACE (color) = Qnil; 487 COLOR_SPECIFIER_FACE (color) = Qnil;
488 COLOR_SPECIFIER_FACE_PROPERTY (color) = Qnil; 488 COLOR_SPECIFIER_FACE_PROPERTY (color) = Qnil;
489 } 489 }
490 490
491 static void 491 static void
492 color_mark (Lisp_Object obj) 492 color_mark (Lisp_Object obj)
493 { 493 {
494 struct Lisp_Specifier *color = XCOLOR_SPECIFIER (obj); 494 Lisp_Specifier *color = XCOLOR_SPECIFIER (obj);
495 495
496 mark_object (COLOR_SPECIFIER_FACE (color)); 496 mark_object (COLOR_SPECIFIER_FACE (color));
497 mark_object (COLOR_SPECIFIER_FACE_PROPERTY (color)); 497 mark_object (COLOR_SPECIFIER_FACE_PROPERTY (color));
498 } 498 }
499 499
620 } 620 }
621 621
622 void 622 void
623 set_color_attached_to (Lisp_Object obj, Lisp_Object face, Lisp_Object property) 623 set_color_attached_to (Lisp_Object obj, Lisp_Object face, Lisp_Object property)
624 { 624 {
625 struct Lisp_Specifier *color = XCOLOR_SPECIFIER (obj); 625 Lisp_Specifier *color = XCOLOR_SPECIFIER (obj);
626 626
627 COLOR_SPECIFIER_FACE (color) = face; 627 COLOR_SPECIFIER_FACE (color) = face;
628 COLOR_SPECIFIER_FACE_PROPERTY (color) = property; 628 COLOR_SPECIFIER_FACE_PROPERTY (color) = property;
629 } 629 }
630 630
658 /* Qfont defined in general.c */ 658 /* Qfont defined in general.c */
659 659
660 static void 660 static void
661 font_create (Lisp_Object obj) 661 font_create (Lisp_Object obj)
662 { 662 {
663 struct Lisp_Specifier *font = XFONT_SPECIFIER (obj); 663 Lisp_Specifier *font = XFONT_SPECIFIER (obj);
664 664
665 FONT_SPECIFIER_FACE (font) = Qnil; 665 FONT_SPECIFIER_FACE (font) = Qnil;
666 FONT_SPECIFIER_FACE_PROPERTY (font) = Qnil; 666 FONT_SPECIFIER_FACE_PROPERTY (font) = Qnil;
667 } 667 }
668 668
669 static void 669 static void
670 font_mark (Lisp_Object obj) 670 font_mark (Lisp_Object obj)
671 { 671 {
672 struct Lisp_Specifier *font = XFONT_SPECIFIER (obj); 672 Lisp_Specifier *font = XFONT_SPECIFIER (obj);
673 673
674 mark_object (FONT_SPECIFIER_FACE (font)); 674 mark_object (FONT_SPECIFIER_FACE (font));
675 mark_object (FONT_SPECIFIER_FACE_PROPERTY (font)); 675 mark_object (FONT_SPECIFIER_FACE_PROPERTY (font));
676 } 676 }
677 677
830 } 830 }
831 831
832 void 832 void
833 set_font_attached_to (Lisp_Object obj, Lisp_Object face, Lisp_Object property) 833 set_font_attached_to (Lisp_Object obj, Lisp_Object face, Lisp_Object property)
834 { 834 {
835 struct Lisp_Specifier *font = XFONT_SPECIFIER (obj); 835 Lisp_Specifier *font = XFONT_SPECIFIER (obj);
836 836
837 FONT_SPECIFIER_FACE (font) = face; 837 FONT_SPECIFIER_FACE (font) = face;
838 FONT_SPECIFIER_FACE_PROPERTY (font) = property; 838 FONT_SPECIFIER_FACE_PROPERTY (font) = property;
839 } 839 }
840 840
865 Lisp_Object Qface_boolean; 865 Lisp_Object Qface_boolean;
866 866
867 static void 867 static void
868 face_boolean_create (Lisp_Object obj) 868 face_boolean_create (Lisp_Object obj)
869 { 869 {
870 struct Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj); 870 Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj);
871 871
872 FACE_BOOLEAN_SPECIFIER_FACE (face_boolean) = Qnil; 872 FACE_BOOLEAN_SPECIFIER_FACE (face_boolean) = Qnil;
873 FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean) = Qnil; 873 FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean) = Qnil;
874 } 874 }
875 875
876 static void 876 static void
877 face_boolean_mark (Lisp_Object obj) 877 face_boolean_mark (Lisp_Object obj)
878 { 878 {
879 struct Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj); 879 Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj);
880 880
881 mark_object (FACE_BOOLEAN_SPECIFIER_FACE (face_boolean)); 881 mark_object (FACE_BOOLEAN_SPECIFIER_FACE (face_boolean));
882 mark_object (FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean)); 882 mark_object (FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean));
883 } 883 }
884 884
975 975
976 void 976 void
977 set_face_boolean_attached_to (Lisp_Object obj, Lisp_Object face, 977 set_face_boolean_attached_to (Lisp_Object obj, Lisp_Object face,
978 Lisp_Object property) 978 Lisp_Object property)
979 { 979 {
980 struct Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj); 980 Lisp_Specifier *face_boolean = XFACE_BOOLEAN_SPECIFIER (obj);
981 981
982 FACE_BOOLEAN_SPECIFIER_FACE (face_boolean) = face; 982 FACE_BOOLEAN_SPECIFIER_FACE (face_boolean) = face;
983 FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean) = property; 983 FACE_BOOLEAN_SPECIFIER_FACE_PROPERTY (face_boolean) = property;
984 } 984 }
985 985
1035 /* Qcolor, Qfont defined in general.c */ 1035 /* Qcolor, Qfont defined in general.c */
1036 defsymbol (&Qface_boolean, "face-boolean"); 1036 defsymbol (&Qface_boolean, "face-boolean");
1037 } 1037 }
1038 1038
1039 static const struct lrecord_description color_specifier_description[] = { 1039 static const struct lrecord_description color_specifier_description[] = {
1040 { XD_LISP_OBJECT, specifier_data_offset + offsetof(struct color_specifier, face), 2 }, 1040 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct color_specifier, face) },
1041 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct color_specifier, face_property) },
1041 { XD_END } 1042 { XD_END }
1042 }; 1043 };
1043 1044
1044 static const struct lrecord_description font_specifier_description[] = { 1045 static const struct lrecord_description font_specifier_description[] = {
1045 { XD_LISP_OBJECT, specifier_data_offset + offsetof(struct font_specifier, face), 2 }, 1046 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct font_specifier, face) },
1047 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct font_specifier, face_property) },
1046 { XD_END } 1048 { XD_END }
1047 }; 1049 };
1048 1050
1049 static const struct lrecord_description face_boolean_specifier_description[] = { 1051 static const struct lrecord_description face_boolean_specifier_description[] = {
1050 { XD_LISP_OBJECT, specifier_data_offset + offsetof(struct face_boolean_specifier, face), 2 }, 1052 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct face_boolean_specifier, face) },
1053 { XD_LISP_OBJECT, specifier_data_offset + offsetof (struct face_boolean_specifier, face_property) },
1051 { XD_END } 1054 { XD_END }
1052 }; 1055 };
1053 1056
1054 void 1057 void
1055 specifier_type_create_objects (void) 1058 specifier_type_create_objects (void)
1095 void 1098 void
1096 reinit_vars_of_objects (void) 1099 reinit_vars_of_objects (void)
1097 { 1100 {
1098 staticpro_nodump (&Vthe_null_color_instance); 1101 staticpro_nodump (&Vthe_null_color_instance);
1099 { 1102 {
1100 struct Lisp_Color_Instance *c = 1103 Lisp_Color_Instance *c =
1101 alloc_lcrecord_type (struct Lisp_Color_Instance, &lrecord_color_instance); 1104 alloc_lcrecord_type (Lisp_Color_Instance, &lrecord_color_instance);
1102 c->name = Qnil; 1105 c->name = Qnil;
1103 c->device = Qnil; 1106 c->device = Qnil;
1104 c->data = 0; 1107 c->data = 0;
1105 1108
1106 XSETCOLOR_INSTANCE (Vthe_null_color_instance, c); 1109 XSETCOLOR_INSTANCE (Vthe_null_color_instance, c);
1107 } 1110 }
1108 1111
1109 staticpro_nodump (&Vthe_null_font_instance); 1112 staticpro_nodump (&Vthe_null_font_instance);
1110 { 1113 {
1111 struct Lisp_Font_Instance *f = 1114 Lisp_Font_Instance *f =
1112 alloc_lcrecord_type (struct Lisp_Font_Instance, &lrecord_font_instance); 1115 alloc_lcrecord_type (Lisp_Font_Instance, &lrecord_font_instance);
1113 f->name = Qnil; 1116 f->name = Qnil;
1114 f->device = Qnil; 1117 f->device = Qnil;
1115 f->data = 0; 1118 f->data = 0;
1116 1119
1117 f->ascent = f->height = 0; 1120 f->ascent = f->height = 0;