Mercurial > emacs
comparison src/xterm.c @ 17877:7841036d55f4
(x_load_font): Set 4 instead of -1 in fontp->encoding[1]
for the meaning of `can't decided'.
author | Kenichi Handa <handa@m17n.org> |
---|---|
date | Mon, 19 May 1997 03:33:50 +0000 |
parents | 281d99590839 |
children | 96a51be54a7e |
comparison
equal
deleted
inserted
replaced
17876:6e27f660a0be | 17877:7841036d55f4 |
---|---|
6489 fontp->size = font->max_bounds.width; | 6489 fontp->size = font->max_bounds.width; |
6490 fontp->height = font->ascent + font->descent; | 6490 fontp->height = font->ascent + font->descent; |
6491 | 6491 |
6492 /* The slot `encoding' specifies how to map a character | 6492 /* The slot `encoding' specifies how to map a character |
6493 code-points (0x20..0x7F or 0x2020..0x7F7F) of each charset to | 6493 code-points (0x20..0x7F or 0x2020..0x7F7F) of each charset to |
6494 the font code-points (0x20..0x7F, 0xA0..0xFF, 0x2020..0x7F7F, | 6494 the font code-points (0:0x20..0x7F, 1:0xA0..0xFF, 0:0x2020..0x7F7F, |
6495 0xA0A0..0xFFFF, 0x20A0..0x7FFF, or 0xA020..0xFF7F). For the | 6495 1:0xA0A0..0xFFFF, 3:0x20A0..0x7FFF, or 2:0xA020..0xFF7F). For the |
6496 moment, we don't know which charset uses this font. So, we set | 6496 moment, we don't know which charset uses this font. So, we set |
6497 informatoin in fontp->encoding[1] which is never used by any | 6497 informatoin in fontp->encoding[1] which is never used by any |
6498 charset. If mapping can't be decided, set -1. */ | 6498 charset. If mapping can't be decided, set 4. */ |
6499 fontp->encoding[1] | 6499 fontp->encoding[1] |
6500 = (font->max_byte1 == 0 | 6500 = (font->max_byte1 == 0 |
6501 /* 1-byte font */ | 6501 /* 1-byte font */ |
6502 ? (font->min_char_or_byte2 < 0x80 | 6502 ? (font->min_char_or_byte2 < 0x80 |
6503 ? (font->max_char_or_byte2 < 0x80 | 6503 ? (font->max_char_or_byte2 < 0x80 |
6504 ? 0 /* 0x20..0x7F */ | 6504 ? 0 /* 0x20..0x7F */ |
6505 : -1) /* 0x20..0xFF (can't decide) */ | 6505 : 4) /* 0x20..0xFF (can't decide) */ |
6506 : 1) /* 0xA0..0xFF */ | 6506 : 1) /* 0xA0..0xFF */ |
6507 /* 2-byte font */ | 6507 /* 2-byte font */ |
6508 : (font->min_byte1 < 0x80 | 6508 : (font->min_byte1 < 0x80 |
6509 ? (font->max_byte1 < 0x80 | 6509 ? (font->max_byte1 < 0x80 |
6510 ? (font->min_char_or_byte2 < 0x80 | 6510 ? (font->min_char_or_byte2 < 0x80 |
6511 ? (font->max_char_or_byte2 < 0x80 | 6511 ? (font->max_char_or_byte2 < 0x80 |
6512 ? 0 /* 0x2020..0x7F7F */ | 6512 ? 0 /* 0x2020..0x7F7F */ |
6513 : -1) /* 0x2020..0x7FFF (can't decide) */ | 6513 : 4) /* 0x2020..0x7FFF (can't decide) */ |
6514 : 3) /* 0x20A0..0x7FFF */ | 6514 : 3) /* 0x20A0..0x7FFF */ |
6515 : -1) /* 0x20??..0xA0?? (can't decide) */ | 6515 : 4) /* 0x20??..0xA0?? (can't decide) */ |
6516 : (font->min_char_or_byte2 < 0x80 | 6516 : (font->min_char_or_byte2 < 0x80 |
6517 ? (font->max_char_or_byte2 < 0x80 | 6517 ? (font->max_char_or_byte2 < 0x80 |
6518 ? 2 /* 0xA020..0xFF7F */ | 6518 ? 2 /* 0xA020..0xFF7F */ |
6519 : -1) /* 0xA020..0xFFFF (can't decide) */ | 6519 : 4) /* 0xA020..0xFFFF (can't decide) */ |
6520 : 1))); /* 0xA0A0..0xFFFF */ | 6520 : 1))); /* 0xA0A0..0xFFFF */ |
6521 | 6521 |
6522 fontp->baseline_offset | 6522 fontp->baseline_offset |
6523 = (XGetFontProperty (font, dpyinfo->Xatom_MULE_BASELINE_OFFSET, &value) | 6523 = (XGetFontProperty (font, dpyinfo->Xatom_MULE_BASELINE_OFFSET, &value) |
6524 ? (long) value : 0); | 6524 ? (long) value : 0); |