diff options
author | Eli Zaretskii <eliz@gnu.org> | 2016-07-02 16:56:36 +0300 |
---|---|---|
committer | Eli Zaretskii <eliz@gnu.org> | 2016-07-02 16:56:36 +0300 |
commit | da2512f24c5772476671202bf6106f63983e22e4 (patch) | |
tree | 21fd6c389a5ce38f521642afee117f263cd1272d | |
parent | 3a1e3b41a545ffc438b2e5c69982ff82e64b747c (diff) |
Fix cursor positioning on TTY frames after stretch glyph
* src/term.c (append_glyph, append_composite_glyph)
(append_glyphless_glyph): Set the avoid_cursor_p and multibyte_p
members of the produced 'struct glyph'. Fixes cursor positioning
on the first character after a stretch glyph produced from
line-prefix, wrap-prefix, etc. on TTY frames.
-rw-r--r-- | src/term.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/term.c b/src/term.c index 7e63a0cf63..81908b370a 100644 --- a/src/term.c +++ b/src/term.c @@ -1496,6 +1496,8 @@ append_glyph (struct it *it) glyph->pixel_width = 1; glyph->u.ch = it->char_to_display; glyph->face_id = it->face_id; + glyph->avoid_cursor_p = it->avoid_cursor_p; + glyph->multibyte_p = it->multibyte_p; glyph->padding_p = i > 0; glyph->charpos = CHARPOS (it->position); glyph->object = it->object; @@ -1692,8 +1694,10 @@ append_composite_glyph (struct it *it) glyph->slice.cmp.to = it->cmp_it.to - 1; } + glyph->avoid_cursor_p = it->avoid_cursor_p; + glyph->multibyte_p = it->multibyte_p; glyph->face_id = it->face_id; - glyph->padding_p = 0; + glyph->padding_p = false; glyph->charpos = CHARPOS (it->position); glyph->object = it->object; if (it->bidi_p) @@ -1776,8 +1780,10 @@ append_glyphless_glyph (struct it *it, int face_id, const char *str) return; glyph->type = CHAR_GLYPH; glyph->pixel_width = 1; + glyph->avoid_cursor_p = it->avoid_cursor_p; + glyph->multibyte_p = it->multibyte_p; glyph->face_id = face_id; - glyph->padding_p = 0; + glyph->padding_p = false; glyph->charpos = CHARPOS (it->position); glyph->object = it->object; if (it->bidi_p) |