Mercurial > emacs
comparison src/dispextern.h @ 88901:bcf253c370e8
(struct face): Member `charset' deleted.
(FACE_SUITABLE_FOR_CHAR_P): Use ASCII_CHAR_P, not
SINGLE_BYTE_CHAR_P.
(FACE_FOR_CHAR): Likewise.
(choose_face_font, lookup_non_ascii_face, font_name_registry): Add
prototypes
(lookup_face, lookup_named_face, lookup_derived_face): Prototype
fixed.
(generate_ascii_font_name): Renamed from generate_ascii_font.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Fri, 26 Jul 2002 04:05:48 +0000 |
parents | 721d24ebba91 |
children | 87c6cb535c03 |
comparison
equal
deleted
inserted
replaced
88900:d6c50ac00394 | 88901:bcf253c370e8 |
---|---|
1263 pointers to font_info structures may change. The reason is that | 1263 pointers to font_info structures may change. The reason is that |
1264 they are pointers into a font table vector that is itself | 1264 they are pointers into a font table vector that is itself |
1265 reallocated. */ | 1265 reallocated. */ |
1266 int font_info_id; | 1266 int font_info_id; |
1267 | 1267 |
1268 /* Fontset ID if this face uses a fontset, or -1. This is only >= 0 | 1268 /* Fontset ID if for this face's fontset. Non-ASCII faces derived |
1269 if the face was realized for a composition sequence. | 1269 from the same ASCII face have the same fontset. */ |
1270 Otherwise, a specific font is loaded from the set of fonts | |
1271 specified by the fontset given by the family attribute of the face. */ | |
1272 int fontset; | 1270 int fontset; |
1273 | 1271 |
1274 /* Pixmap width and height. */ | 1272 /* Pixmap width and height. */ |
1275 unsigned int pixmap_w, pixmap_h; | 1273 unsigned int pixmap_w, pixmap_h; |
1276 | 1274 |
1298 Lisp_Object lface[LFACE_VECTOR_SIZE]; | 1296 Lisp_Object lface[LFACE_VECTOR_SIZE]; |
1299 | 1297 |
1300 /* The hash value of this face. */ | 1298 /* The hash value of this face. */ |
1301 unsigned hash; | 1299 unsigned hash; |
1302 | 1300 |
1303 /* The charset for which this face was realized if it was realized | |
1304 for use in multibyte text. If fontset >= 0, this is the charset | |
1305 of the first character of the composition sequence. A value of | |
1306 charset < 0 means the face was realized for use in unibyte text | |
1307 where the idea of Emacs charsets isn't applicable. */ | |
1308 int charset; | |
1309 | |
1310 /* Non-zero if text in this face should be underlined, overlined, | 1301 /* Non-zero if text in this face should be underlined, overlined, |
1311 strike-through or have a box drawn around it. */ | 1302 strike-through or have a box drawn around it. */ |
1312 unsigned underline_p : 1; | 1303 unsigned underline_p : 1; |
1313 unsigned overline_p : 1; | 1304 unsigned overline_p : 1; |
1314 unsigned strike_through_p : 1; | 1305 unsigned strike_through_p : 1; |
1347 unsigned colors_copied_bitwise_p : 1; | 1338 unsigned colors_copied_bitwise_p : 1; |
1348 | 1339 |
1349 /* Next and previous face in hash collision list of face cache. */ | 1340 /* Next and previous face in hash collision list of face cache. */ |
1350 struct face *next, *prev; | 1341 struct face *next, *prev; |
1351 | 1342 |
1352 /* If this face is for ASCII characters, this points this face | 1343 /* If this face is an ASCII face, this points to this face itself. |
1353 itself. Otherwise, this points a face for ASCII characters. */ | 1344 Otherwise, this points to an ASCII face that has the same |
1345 attributes except the font. */ | |
1354 struct face *ascii_face; | 1346 struct face *ascii_face; |
1355 }; | 1347 }; |
1356 | 1348 |
1357 | 1349 |
1358 /* Color index indicating that face uses a terminal's default color. */ | 1350 /* Color index indicating that face uses a terminal's default color. */ |
1435 #ifdef HAVE_WINDOW_SYSTEM | 1427 #ifdef HAVE_WINDOW_SYSTEM |
1436 | 1428 |
1437 /* Non-zero if FACE is suitable for displaying character CHAR. */ | 1429 /* Non-zero if FACE is suitable for displaying character CHAR. */ |
1438 | 1430 |
1439 #define FACE_SUITABLE_FOR_CHAR_P(FACE, CHAR) \ | 1431 #define FACE_SUITABLE_FOR_CHAR_P(FACE, CHAR) \ |
1440 (SINGLE_BYTE_CHAR_P (CHAR) \ | 1432 (ASCII_CHAR_P (CHAR) \ |
1441 ? (FACE) == (FACE)->ascii_face \ | 1433 ? (FACE) == (FACE)->ascii_face \ |
1442 : face_suitable_for_char_p ((FACE), (CHAR))) | 1434 : face_suitable_for_char_p ((FACE), (CHAR))) |
1443 | 1435 |
1444 /* Return the id of the realized face on frame F that is like the face | 1436 /* Return the id of the realized face on frame F that is like the face |
1445 with id ID but is suitable for displaying character CHAR. | 1437 with id ID but is suitable for displaying character CHAR. |
1446 This macro is only meaningful for multibyte character CHAR. */ | 1438 This macro is only meaningful for multibyte character CHAR. */ |
1447 | 1439 |
1448 #define FACE_FOR_CHAR(F, FACE, CHAR) \ | 1440 #define FACE_FOR_CHAR(F, FACE, CHAR) \ |
1449 (SINGLE_BYTE_CHAR_P (CHAR) \ | 1441 (ASCII_CHAR_P (CHAR) \ |
1450 ? (FACE)->ascii_face->id \ | 1442 ? (FACE)->ascii_face->id \ |
1451 : face_for_char ((F), (FACE), (CHAR))) | 1443 : face_for_char ((F), (FACE), (CHAR))) |
1452 | 1444 |
1453 #else /* not HAVE_WINDOW_SYSTEM */ | 1445 #else /* not HAVE_WINDOW_SYSTEM */ |
1454 | 1446 |
2274 void clear_face_cache P_ ((int)); | 2266 void clear_face_cache P_ ((int)); |
2275 unsigned long load_color P_ ((struct frame *, struct face *, Lisp_Object, | 2267 unsigned long load_color P_ ((struct frame *, struct face *, Lisp_Object, |
2276 enum lface_attribute_index)); | 2268 enum lface_attribute_index)); |
2277 void unload_color P_ ((struct frame *, unsigned long)); | 2269 void unload_color P_ ((struct frame *, unsigned long)); |
2278 int frame_update_line_height P_ ((struct frame *)); | 2270 int frame_update_line_height P_ ((struct frame *)); |
2271 char *choose_face_font P_ ((struct frame *, Lisp_Object *, Lisp_Object)); | |
2279 int ascii_face_of_lisp_face P_ ((struct frame *, int)); | 2272 int ascii_face_of_lisp_face P_ ((struct frame *, int)); |
2280 void prepare_face_for_display P_ ((struct frame *, struct face *)); | 2273 void prepare_face_for_display P_ ((struct frame *, struct face *)); |
2281 int xstricmp P_ ((unsigned char *, unsigned char *)); | 2274 int xstricmp P_ ((unsigned char *, unsigned char *)); |
2282 int lookup_face P_ ((struct frame *, Lisp_Object *, int, struct face *)); | 2275 int lookup_face P_ ((struct frame *, Lisp_Object *)); |
2283 int lookup_named_face P_ ((struct frame *, Lisp_Object, int)); | 2276 int lookup_non_ascii_face P_ ((struct frame *, int, struct face *)); |
2277 int lookup_named_face P_ ((struct frame *, Lisp_Object)); | |
2284 int smaller_face P_ ((struct frame *, int, int)); | 2278 int smaller_face P_ ((struct frame *, int, int)); |
2285 int face_with_height P_ ((struct frame *, int, int)); | 2279 int face_with_height P_ ((struct frame *, int, int)); |
2286 int lookup_derived_face P_ ((struct frame *, Lisp_Object, int, int)); | 2280 int lookup_derived_face P_ ((struct frame *, Lisp_Object, int)); |
2287 void init_frame_faces P_ ((struct frame *)); | 2281 void init_frame_faces P_ ((struct frame *)); |
2288 void free_frame_faces P_ ((struct frame *)); | 2282 void free_frame_faces P_ ((struct frame *)); |
2289 void recompute_basic_faces P_ ((struct frame *)); | 2283 void recompute_basic_faces P_ ((struct frame *)); |
2290 int face_at_buffer_position P_ ((struct window *, int, int, int, int *, | 2284 int face_at_buffer_position P_ ((struct window *, int, int, int, int *, |
2291 int, int)); | 2285 int, int)); |
2296 void free_realized_face P_ ((struct frame *, struct face *)); | 2290 void free_realized_face P_ ((struct frame *, struct face *)); |
2297 | 2291 |
2298 extern Lisp_Object Qforeground_color, Qbackground_color; | 2292 extern Lisp_Object Qforeground_color, Qbackground_color; |
2299 extern char unspecified_fg[], unspecified_bg[]; | 2293 extern char unspecified_fg[], unspecified_bg[]; |
2300 extern void check_face_attributes P_ ((Lisp_Object, Lisp_Object, Lisp_Object)); | 2294 extern void check_face_attributes P_ ((Lisp_Object, Lisp_Object, Lisp_Object)); |
2301 extern Lisp_Object generate_ascii_font P_ ((Lisp_Object, Lisp_Object)); | 2295 extern Lisp_Object generate_ascii_font_name P_ ((Lisp_Object, Lisp_Object)); |
2296 extern Lisp_Object font_name_registry P_ ((Lisp_Object)); | |
2302 | 2297 |
2303 /* Defined in xfns.c */ | 2298 /* Defined in xfns.c */ |
2304 | 2299 |
2305 #ifdef HAVE_X_WINDOWS | 2300 #ifdef HAVE_X_WINDOWS |
2306 void gamma_correct P_ ((struct frame *, XColor *)); | 2301 void gamma_correct P_ ((struct frame *, XColor *)); |