1@node uniname.h
2@chapter Names of Unicode characters @code{<uniname.h>}
3
4@cindex Unicode character, name
5This include file implements the association between a Unicode character and
6its name.
7
8The name of a Unicode character allows to distinguish it from other, similar
9looking characters.  For example, the character @samp{x} has the name
10@code{"LATIN SMALL LETTER X"} and is therefore different from the character
11named @code{"MULTIPLICATION SIGN"}.
12
13@deftypevr Macro {unsigned int} UNINAME_MAX
14This macro expands to a constant that is the required size of buffer for a
15Unicode character name.
16@end deftypevr
17
18@deftypefun {char *} unicode_character_name (ucs4_t @var{uc}, char *@var{buf})
19Looks up the name of a Unicode character, in uppercase ASCII.
20@var{buf} must point to a buffer, at least @code{UNINAME_MAX} bytes in size.
21Returns the filled @var{buf}, or NULL if the character does not have a name.
22@end deftypefun
23
24@deftypefun ucs4_t unicode_name_character (const char *@var{name})
25Looks up the Unicode character with a given name, in upper- or lowercase
26ASCII.  @var{NAME} can also be an alias name of a character.
27Returns the character if found, or @code{UNINAME_INVALID} if not found.
28@end deftypefun
29
30@deftypevr Macro ucs4_t UNINAME_INVALID
31This macro expands to a constant that is a special return value of the
32@code{unicode_name_character} function.
33@end deftypevr
34