From 7363a90346221183e6dec1837f9aac5e6448ef6b Mon Sep 17 00:00:00 2001 From: Gerd Moellmann Date: Tue, 25 Jul 2000 12:06:09 +0000 Subject: [PATCH] (GLYPH_MASK_CHAR, GLYPH_MASK_FACE): Use 19 bits for the character code, and the rest for the face id. (FAST_GLYPH_FACE, FAST_MAKE_GLYPH): Changed accordingly. --- src/lisp.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/lisp.h b/src/lisp.h index 14b65e30571..f43e5de8685 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -1182,20 +1182,20 @@ typedef unsigned char UCHAR; #define GLYPH int /* Mask bits for face. */ -#define GLYPH_MASK_FACE 0x7FFFFF00 +#define GLYPH_MASK_FACE 0x7FF80000 /* Mask bits for character code. */ -#define GLYPH_MASK_CHAR 0x000000FF /* The lowest 8 bits */ +#define GLYPH_MASK_CHAR 0x0007FFFF /* The lowest 19 bits */ /* The FAST macros assume that we already know we're in an X window. */ /* Set a character code and a face ID in a glyph G. */ -#define FAST_MAKE_GLYPH(char, face) ((char) | ((face) << 8)) +#define FAST_MAKE_GLYPH(char, face) ((char) | ((face) << CHARACTERBITS)) /* Return a glyph's character code. */ #define FAST_GLYPH_CHAR(glyph) ((glyph) & GLYPH_MASK_CHAR) /* Return a glyph's face ID. */ -#define FAST_GLYPH_FACE(glyph) (((glyph) & GLYPH_MASK_FACE) >> 8) +#define FAST_GLYPH_FACE(glyph) (((glyph) & GLYPH_MASK_FACE) >> CHARACTERBITS) /* Slower versions that test the frame type first. */ #define MAKE_GLYPH(f, char, face) (FAST_MAKE_GLYPH (char, face)) -- 2.39.2