# HG changeset patch # User Andrew Innes # Date 997789480 0 # Node ID a59ac9807c9d5c721fe41ec7984fb39d97c70bcc # Parent 45b12f1bd5fed1c28358ac955252f64e76b10064 Draw relief (if any) before drawing glyph string. diff -r 45b12f1bd5fe -r a59ac9807c9d src/w32term.c --- a/src/w32term.c Tue Aug 14 11:44:38 2001 +0000 +++ b/src/w32term.c Tue Aug 14 11:44:40 2001 +0000 @@ -4300,6 +4300,8 @@ x_draw_glyph_string (s) struct glyph_string *s; { + int relief_drawn_p = 0; + /* If S draws into the background of its successor, draw the background of the successor first so that S can draw into it. This makes S->next use XDrawString instead of XDrawImageString. */ @@ -4315,6 +4317,19 @@ x_set_glyph_string_gc (s); x_set_glyph_string_clipping (s); + /* Draw relief (if any) in advance for char/composition so that the + glyph string can be drawn over it. */ + if (!s->for_overlaps_p + && s->face->box != FACE_NO_BOX + && (s->first_glyph->type == CHAR_GLYPH + || s->first_glyph->type == COMPOSITE_GLYPH)) + + { + x_draw_glyph_string_background (s, 1); + x_draw_glyph_string_box (s); + relief_drawn_p = 1; + } + switch (s->first_glyph->type) { case IMAGE_GLYPH: @@ -4403,7 +4418,7 @@ } /* Draw relief. */ - if (s->face->box != FACE_NO_BOX) + if (!relief_drawn_p && s->face->box != FACE_NO_BOX) x_draw_glyph_string_box (s); }