From: Gerd Moellmann Date: Thu, 25 Apr 2002 17:28:08 +0000 (+0000) Subject: (x_draw_phys_cursor_glyph): Take into account that a box X-Git-Url: https://git.hcoop.net/bpt/emacs.git/commitdiff_plain/ef58a7ec876cd60b2ab9c7223013fc3079e67c72 (x_draw_phys_cursor_glyph): Take into account that a box cursor on a stretch glyph has a width that depends on x_stretch_cursor_p. --- diff --git a/src/ChangeLog b/src/ChangeLog index 5a7dc54a66..686c19c77b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2002-04-25 Gerd Moellmann + + * xterm.c (x_draw_phys_cursor_glyph): Take into account that a box + cursor on a stretch glyph has a width that depends on + x_stretch_cursor_p. + 2002-04-25 Pavel Jan,Bm(Bk * indent.c (Fvertical_motion): Fix last change. diff --git a/src/xterm.c b/src/xterm.c index 0009161af7..1f9e863d42 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -11478,7 +11478,13 @@ x_draw_phys_cursor_glyph (w, row, hl) { struct glyph *cursor_glyph = get_phys_cursor_glyph (w); if (cursor_glyph) - w->phys_cursor_width = cursor_glyph->pixel_width; + { + if (x_stretch_cursor_p) + w->phys_cursor_width = cursor_glyph->pixel_width; + else + w->phys_cursor_width = min (CANON_X_UNIT (XFRAME (w->frame)), + cursor_glyph->pixel_width); + } } /* When we erase the cursor, and ROW is overlapped by other