changeset 25016:15a2436cb80f

(CHAR_LEN): Moved here from dispextern.h.
author Gerd Moellmann <gerd@gnu.org>
date Wed, 21 Jul 1999 21:43:52 +0000
parents 7730c6f39ef5
children 4a142fb92f94
files src/charset.h
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/charset.h	Wed Jul 21 21:43:52 1999 +0000
+++ b/src/charset.h	Wed Jul 21 21:43:52 1999 +0000
@@ -839,4 +839,12 @@
     while (i--) *from_p++ = *to_p++;		\
   } while (0)
 
+/* Length of C in bytes.  */
+
+#define CHAR_LEN(C)					\
+     (CHAR_CHARSET ((C)) == CHARSET_COMPOSITION		\
+      ? cmpchar_table[COMPOSITE_CHAR_ID ((C))]->len	\
+      : CHARSET_BYTES (CHAR_CHARSET ((C))))
+
+
 #endif /* _CHARSET_H */