]> code.delx.au - gnu-emacs/blobdiff - src/term.c
Merge from trunk.
[gnu-emacs] / src / term.c
index 10416090b80c974f78f27248d64dd264cd65d2e6..fb3166a6e50dda11d59cf0e2594d5964c0c7ffbf 100644 (file)
@@ -574,6 +574,8 @@ encode_terminal_code (struct glyph *src, int src_len, struct coding_system *codi
              {
                int c = COMPOSITION_GLYPH (cmp, i);
 
+               /* TAB in a composition means display glyphs with
+                  padding space on the left or right.  */
                if (c == '\t')
                  continue;
                if (char_charset (c, charset_list, NULL))
@@ -1913,8 +1915,7 @@ produce_special_glyphs (struct it *it, enum display_element_type what)
       else
        SET_GLYPH_FROM_CHAR (glyph, '\\');
       if (it->dp
-         && (gc = DISP_CONTINUE_GLYPH (it->dp), GLYPH_CODE_P (gc))
-         && GLYPH_CODE_CHAR_VALID_P (gc))
+         && (gc = DISP_CONTINUE_GLYPH (it->dp), GLYPH_CODE_P (gc)))
        {
          /* FIXME: Should we mirror GC for R2L lines?  */
          SET_GLYPH_FROM_GLYPH_CODE (glyph, gc);
@@ -1926,8 +1927,7 @@ produce_special_glyphs (struct it *it, enum display_element_type what)
       /* Truncation glyph.  */
       SET_GLYPH_FROM_CHAR (glyph, '$');
       if (it->dp
-         && (gc = DISP_TRUNC_GLYPH (it->dp), GLYPH_CODE_P (gc))
-         && GLYPH_CODE_CHAR_VALID_P (gc))
+         && (gc = DISP_TRUNC_GLYPH (it->dp), GLYPH_CODE_P (gc)))
        {
          /* FIXME: Should we mirror GC for R2L lines?  */
          SET_GLYPH_FROM_GLYPH_CODE (glyph, gc);
@@ -2277,7 +2277,7 @@ set_tty_color_mode (struct tty_display_info *tty, struct frame *f)
   else
     color_mode = Qnil;
 
-  mode = INTEGERP (color_mode) ? XINT (color_mode) : 0;
+  mode = TYPE_RANGED_INTEGERP (int, color_mode) ? XINT (color_mode) : 0;
 
   if (mode != tty->previous_color_mode)
     {