diff options
| author | Kenichi Handa | 1998-03-03 01:29:16 +0000 |
|---|---|---|
| committer | Kenichi Handa | 1998-03-03 01:29:16 +0000 |
| commit | 54e15bb98c80eb9cb09f32f708277ff67d4358c3 (patch) | |
| tree | 9a226e8dbd5f05d223bc98ef43bc19cc2c092fff | |
| parent | b98590074d53c9b510e344bc81d5ae47ceb8abfa (diff) | |
| download | emacs-54e15bb98c80eb9cb09f32f708277ff67d4358c3.tar.gz emacs-54e15bb98c80eb9cb09f32f708277ff67d4358c3.zip | |
(NONASCII_INSERT_OFFSET): New macro.
(VALID_MULTIBYTE_CHAR_P): New macro.
| -rw-r--r-- | src/charset.h | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/charset.h b/src/charset.h index 12bc02e48aa..86f81fc89e8 100644 --- a/src/charset.h +++ b/src/charset.h | |||
| @@ -475,6 +475,29 @@ extern int width_by_char_head[256]; | |||
| 475 | ((c) >= 0 \ | 475 | ((c) >= 0 \ |
| 476 | && (SINGLE_BYTE_CHAR_P (c) || char_valid_p (c, genericp))) | 476 | && (SINGLE_BYTE_CHAR_P (c) || char_valid_p (c, genericp))) |
| 477 | 477 | ||
| 478 | /* This default value is used when nonascii-translate-table or | ||
| 479 | nonascii-insert-offset fail to convert unibyte character to a valid | ||
| 480 | multibyte character. This makes a Latin-1 character. */ | ||
| 481 | |||
| 482 | #define DEFAULT_NONASCII_INSERT_OFFSET 0x800 | ||
| 483 | |||
| 484 | /* Check if the character C is valid as a multibyte character. */ | ||
| 485 | |||
| 486 | #define VALID_MULTIBYTE_CHAR_P(c) \ | ||
| 487 | ((c) < MIN_CHAR_OFFICIAL_DIMENSION2 \ | ||
| 488 | ? (!NILP (XCHAR_TABLE (Vcharset_table)->contents[CHAR_FIELD2 (c) \ | ||
| 489 | + 0xF0]) \ | ||
| 490 | && CHAR_FIELD3 (c) >= 32) \ | ||
| 491 | : ((c) < MIN_CHAR_PRIVATE_DIMENSION2 \ | ||
| 492 | ? (!NILP (XCHAR_TABLE (Vcharset_table)->contents[CHAR_FIELD1 (c) \ | ||
| 493 | + 0x10F]) \ | ||
| 494 | && CHAR_FIELD2 (c) >= 32 && CHAR_FIELD3 (c) >= 32) \ | ||
| 495 | : ((c) < MIN_CHAR_COMPOSITION \ | ||
| 496 | ? (!NILP (XCHAR_TABLE (Vcharset_table)->contents[CHAR_FIELD1 (c) \ | ||
| 497 | + 0x160]) \ | ||
| 498 | && CHAR_FIELD2 (c) >= 32 && CHAR_FIELD3 (c) >= 32) \ | ||
| 499 | : (c) < MIN_CHAR_COMPOSITION + n_cmpchars))) | ||
| 500 | |||
| 478 | /* The charset of non-ASCII character C is stored in CHARSET, and the | 501 | /* The charset of non-ASCII character C is stored in CHARSET, and the |
| 479 | position-codes of C are stored in C1 and C2. | 502 | position-codes of C are stored in C1 and C2. |
| 480 | We store -1 in C2 if the character is just 2 bytes. | 503 | We store -1 in C2 if the character is just 2 bytes. |