+2010-12-02 Jan Djärv <jan.h.d@swipnet.se>
+
+ * nsterm.m (ns_draw_glyph_string): Switch fore- and background if
+ drawing text under filled box cursor (Bug#7479).
+
2010-11-27 Kenichi Handa <handa@m17n.org>
* charset.c (emacs_mule_charset): Make it an array of charset ID;
if (ns_tmp_font == NULL)
ns_tmp_font = (struct nsfont_info *)FRAME_FONT (s->f);
+ if (s->hl == DRAW_CURSOR && s->w->phys_cursor_type == FILLED_BOX_CURSOR)
+ {
+ unsigned long tmp = NS_FACE_BACKGROUND (s->face);
+ NS_FACE_BACKGROUND (s->face) = NS_FACE_FOREGROUND (s->face);
+ NS_FACE_FOREGROUND (s->face) = tmp;
+ }
+
ns_tmp_font->font.driver->draw
(s, 0, s->nchars, s->x, s->y,
(ns_tmp_flags == NS_DUMPGLYPH_NORMAL && !s->background_filled_p)
|| ns_tmp_flags == NS_DUMPGLYPH_MOUSEFACE);
+ if (s->hl == DRAW_CURSOR && s->w->phys_cursor_type == FILLED_BOX_CURSOR)
+ {
+ unsigned long tmp = NS_FACE_BACKGROUND (s->face);
+ NS_FACE_BACKGROUND (s->face) = NS_FACE_FOREGROUND (s->face);
+ NS_FACE_FOREGROUND (s->face) = tmp;
+ }
+
ns_unfocus (s->f);
break;