mirror of
https://github.com/irssi/irssi.git
synced 2026-08-17 07:32:04 +02:00
BIG5 fixes by vanilla@FreeBSD.org(?)
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3134 dbcabf3a-b0e7-0310-adc4-f8d773084564
This commit is contained in:
parent
6122035f2f
commit
7eb2fc70e3
6 changed files with 94 additions and 11 deletions
|
|
@ -18,6 +18,13 @@ int utf16_char_to_utf8(unichar c, char *outbuf);
|
|||
Make sure out is at least 6 x length of str. */
|
||||
void utf16_to_utf8(const unichar *str, char *out);
|
||||
|
||||
/* XXX I didn't check the encoding range of big5+. This is standard big5. */
|
||||
#define is_big5_los(lo) (0x40 <= (lo) && (lo) <= 0x7E) /* standard */
|
||||
#define is_big5_lox(lo) (0x80 <= (lo) && (lo) <= 0xFE) /* extended */
|
||||
#define is_big5_lo(lo) ((is_big5_los(lo) || is_big5_lox(lo)))
|
||||
#define is_big5_hi(hi) (0x81 <= (hi) && (hi) <= 0xFE)
|
||||
#define is_big5(hi,lo) (is_big5_hi(hi) && is_big5_lo(lo))
|
||||
|
||||
/* Returns width for character (0-2). */
|
||||
int utf8_width(unichar c);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue