diff options
| author | Eli Zaretskii | 2022-01-27 20:35:22 +0200 |
|---|---|---|
| committer | Eli Zaretskii | 2022-01-27 20:35:22 +0200 |
| commit | 10c680551e899805a6de7360e9b65986fd87df72 (patch) | |
| tree | 6f7f55c5584f4e84517194fdc8aacd94d1b9a764 /src | |
| parent | 61f5ca3b27a52a9ed86f71502d794554aa56195a (diff) | |
| download | emacs-10c680551e899805a6de7360e9b65986fd87df72.tar.gz emacs-10c680551e899805a6de7360e9b65986fd87df72.zip | |
Improve detection of glyphless characters on TTY frames
* src/term.c (produce_glyphs): If the terminal can report for
which characters it has glyphs, use that to determine whether
a given character should be displayed as glyphless.
Diffstat (limited to 'src')
| -rw-r--r-- | src/term.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/term.c b/src/term.c index 4c7a90a5773..ddf0e8e2f28 100644 --- a/src/term.c +++ b/src/term.c | |||
| @@ -1632,9 +1632,13 @@ produce_glyphs (struct it *it) | |||
| 1632 | } | 1632 | } |
| 1633 | else | 1633 | else |
| 1634 | { | 1634 | { |
| 1635 | Lisp_Object charset_list = FRAME_TERMINAL (it->f)->charset_list; | 1635 | struct terminal *t = FRAME_TERMINAL (it->f); |
| 1636 | Lisp_Object charset_list = t->charset_list, char_glyph; | ||
| 1636 | 1637 | ||
| 1637 | if (char_charset (it->char_to_display, charset_list, NULL)) | 1638 | if (char_charset (it->char_to_display, charset_list, NULL) |
| 1639 | && (char_glyph = terminal_glyph_code (t, it->char_to_display), | ||
| 1640 | NILP (char_glyph) | ||
| 1641 | || (FIXNUMP (char_glyph) && XFIXNUM (char_glyph) >= 0))) | ||
| 1638 | { | 1642 | { |
| 1639 | it->pixel_width = CHARACTER_WIDTH (it->char_to_display); | 1643 | it->pixel_width = CHARACTER_WIDTH (it->char_to_display); |
| 1640 | it->nglyphs = it->pixel_width; | 1644 | it->nglyphs = it->pixel_width; |