Mercurial > hg > octave-kai > gnulib-hg
annotate lib/uniname.h @ 9352:970d5cb5b003
Relax the license.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Wed, 17 Oct 2007 02:11:05 +0200 |
parents | ad8a75a45dc9 |
children | b5e42ef33b49 |
rev | line source |
---|---|
9053
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
1 /* Association between Unicode characters and their names. |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
2 Copyright (C) 2000-2002, 2005, 2007 Free Software Foundation, Inc. |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
3 |
9307
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
4 This program is free software: you can redistribute it and/or modify it |
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
5 under the terms of the GNU Lesser General Public License as published |
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
6 by the Free Software Foundation; either version 3 of the License, or |
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
7 (at your option) any later version. |
9053
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
8 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
9 This program is distributed in the hope that it will be useful, |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
10 but WITHOUT ANY WARRANTY; without even the implied warranty of |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
9307
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
12 Lesser General Public License for more details. |
9053
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
13 |
9307
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
14 You should have received a copy of the GNU Lesser General Public License |
ad8a75a45dc9
Change copyright notice from LGPLv2.0+ to LGPLv3+.
Bruno Haible <bruno@clisp.org>
parents:
9053
diff
changeset
|
15 along with this program. If not, see <http://www.gnu.org/licenses/>. */ |
9053
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
16 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
17 #ifndef _UNINAME_H |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
18 #define _UNINAME_H |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
19 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
20 #include "unitypes.h" |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
21 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
22 #ifdef __cplusplus |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
23 extern "C" { |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
24 #endif |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
25 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
26 /* Required size of buffer for a Unicode character name. */ |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
27 #define UNINAME_MAX 256 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
28 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
29 /* Looks up the name of a Unicode character, in uppercase ASCII. |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
30 Returns the filled buf, or NULL if the character does not have a name. */ |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
31 extern char * |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
32 unicode_character_name (ucs4_t uc, char *buf); |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
33 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
34 /* Looks up the Unicode character with a given name, in upper- or lowercase |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
35 ASCII. Returns the character if found, or UNINAME_INVALID if not found. */ |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
36 extern ucs4_t |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
37 unicode_name_character (const char *name); |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
38 #define UNINAME_INVALID ((ucs4_t) 0xFFFF) |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
39 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
40 #ifdef __cplusplus |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
41 } |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
42 #endif |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
43 |
1d22b1ee9970
New modules uniname/base and uniname/uniname.
Bruno Haible <bruno@clisp.org>
parents:
diff
changeset
|
44 #endif /* _UNINAME_H */ |