comparison src/xterm.c @ 35315:1f5511b1d5ea

(x_set_mouse_face_gc): If the last use mouse face has gone in the meantime, use face MOUSE_FACE_ID.
author Gerd Moellmann <gerd@gnu.org>
date Mon, 15 Jan 2001 20:14:16 +0000
parents cb7e1d7b6b67
children 68000d773920
comparison
equal deleted inserted replaced
35314:9199190adb77 35315:1f5511b1d5ea
2659 struct glyph_string *s; 2659 struct glyph_string *s;
2660 { 2660 {
2661 int face_id; 2661 int face_id;
2662 struct face *face; 2662 struct face *face;
2663 2663
2664 /* What face has to be used for the mouse face? */ 2664 /* What face has to be used last for the mouse face? */
2665 face_id = FRAME_X_DISPLAY_INFO (s->f)->mouse_face_face_id; 2665 face_id = FRAME_X_DISPLAY_INFO (s->f)->mouse_face_face_id;
2666 face = FACE_FROM_ID (s->f, face_id); 2666 face = FACE_FROM_ID (s->f, face_id);
2667 if (face == NULL)
2668 face = FACE_FROM_ID (s->f, MOUSE_FACE_ID);
2669
2667 if (s->first_glyph->type == CHAR_GLYPH) 2670 if (s->first_glyph->type == CHAR_GLYPH)
2668 face_id = FACE_FOR_CHAR (s->f, face, s->first_glyph->u.ch); 2671 face_id = FACE_FOR_CHAR (s->f, face, s->first_glyph->u.ch);
2669 else 2672 else
2670 face_id = FACE_FOR_CHAR (s->f, face, 0); 2673 face_id = FACE_FOR_CHAR (s->f, face, 0);
2671 s->face = FACE_FROM_ID (s->f, face_id); 2674 s->face = FACE_FROM_ID (s->f, face_id);