#include <wchar.h>
#include "nonspacing.h"
#include "wide.h"
Go to the source code of this file.
|
static const unsigned char | table [] |
|
static const unsigned char | wtable [] |
|
◆ wcwidth()
int wcwidth |
( |
wchar_t |
wc | ) |
|
Definition at line 11 of file wcwidth.c.
13 if(wc < (
wchar_t)0xffU)
15 return (wc + 1 & 0x7f) >= 0x21 ? 1 : wc ? -1 : 0;
18 if((wc & (
wchar_t)0xfffeffffU) < 0xfffe)
20 if((
table[
table[wc >> 8] * 32 + ((wc & 255) >> 3)] >> (wc & 7)) & 1)
25 if((
wtable[
wtable[wc >> 8] * 32 + ((wc & 255) >> 3)] >> (wc & 7)) & 1)
33 if((wc & 0xfffe) == 0xfffe)
38 if(wc - (
wchar_t)0x20000U < 0x20000)
43 if(wc == 0xe0001 || wc - (
wchar_t)0xe0020U < 0x5f || wc - 0xe0100 < 0xef)
static const unsigned char wtable[]
static const unsigned char table[]
References table, and wtable.
Referenced by wcswidth().
◆ table
const unsigned char table[] |
|
static |
◆ wtable
const unsigned char wtable[] |
|
static |