1TICKIT_UTF8_MBSWIDTH(3)    Library Functions Manual    TICKIT_UTF8_MBSWIDTH(3)
2
3
4

NAME

6       tickit_utf8_mbswidth,   tickit_utf8_byte2col,   tickit_utf8_col2byte  -
7       count the column width of a Unicode string
8

SYNOPSIS

10       #include <tickit.h>
11
12       int tickit_utf8_mbswidth(const char *str);
13
14       int tickit_utf8_byte2col(const char *str, size_t byte);
15       size_t tickit_utf8_col2byte(const char *str, int col );
16
17       Link with -ltickit.
18

DESCRIPTION

20       These   functions   are   a   set   of   shortcut    wrappers    around
21       tickit_utf8_count(3)  for performing a single simple counting operation
22       on a given string. When  performing  multiple  operations  on  a  given
23       string, it is more efficient to use tickit_utf8_count() directly.
24
25       tickit_utf8_mbswidth()  returns  the  number  of columns wide the given
26       Unicode string consumes.
27
28       tickit_utf8_byte2col() and tickit_utf8_col2byte() convert between  byte
29       and  column indexes within a given string; returning one when given the
30       other.
31

RETURN VALUE

33       tickit_utf8_mbswidth() and  tickit_utf8_byte2col()  return  an  integer
34       column count. tickit_utf8_col2byte() returns an integer byte count.
35

SEE ALSO

37       tickit_utf8_count(3), tickit(7)
38
39
40
41                                                       TICKIT_UTF8_MBSWIDTH(3)
Impressum