charmap 中文man页面

系统
一个字符集描述(字符映射-charmap)定义了一个有效字符集合及它们的编码。所有被支持的字符集都应该把 可移植字符集 作为其一个子集。

名字

charmap - 定义字符编码的字符符号

描述

一个字符集描述(字符映射-charmap)定义了一个有效字符集合及它们的编码。所有被支持的字符集都应该把 可移植字符集 作为其一个子集。

语法

一个字符映射文件开始于一个头,它可能包含下面关键字:

<codeset>
其后给出编码集名字。
<mb_cur_max>
其后给出多字节字符的最大字节数。多字节字符目前还不支持。默认值是 1。
<mb_cur_min>
其后给出一个字符最少需要的字节个数。这个值必须小于或等于 mb_cur_max。如果没有指定,它的默认值是 mb_cur_max
<escape_char>
其后是一个被用于转义的字符,转义字符用于标记本文件后需要特殊处理的字符。默认地,它是反斜杠(\)。
<comment_char>
其后是一个在本文件后用于注释用的字符。默认值是井号(#)。

字符映射定义自身开始于第一列的关键字 CHARMAP

下面行可能含有下面两种定义字符编码的形式:

<symbolic-name> <encoding> <comments>
这个形式直接定义一个字符和它的编码。
<symbolic-name>...<symbolic-name> <encoding> <comments>
这个形式定义一组编码。这只对多字节字符有用,但目前还没有实现。

字符映射文件的最后一行必须包含 END CHARMAP

符号名

一个字符的 符号名 只包含 可移植字符集 字符。名字本身被尖括号包围。跟随在 <escape_char> 之后的字符被处理为其自身;如序列 <\\\>> 代表被尖括号包围的符号名 \>

字符编码

编码可能有下面三种形式:

<escape_char>d<number>
使用十进制数字
<escape_char>x<number>
使用十六进制数字
<escape_char><number>
使用八进制数字

文件

/usr/share/i18n/charmaps/*

遵循于

POSIX.2。

参看

locale(1), localedef(1), localeconv(3), setlocale(3), locale(5)

#p#

NAME

charmap - character symbols to define character encodings  

DESCRIPTION

A character set description (charmap) defines a characterset of available characters and their encodings. All supported character sets should have the portable character set as a proper subset.  

SYNTAX

The charmap file starts with a header, that may consist of the following keywords:

<codeset>
is followed by the name of the codeset.
<mb_cur_max>
is followed by the max number of bytes for a multibyte-character. Multibyte characters are currently not supported. The default value is 1.
<mb_cur_min>
is followed by the min number of bytes for a character. This value must be less or equal than mb_cur_max. If not specified, it defaults to mb_cur_max.
<escape_char>
is followed by a character that should be used as the escape-character for the rest of the file to mark characters that should be interpreted in a special way. It defaults to the backslash ( \\ ).
<comment_char>
is followed by a character that will be used as the comment-character for the rest of the file. It defaults to the number sign ( # ).

The charmap-definition itself starts with the keyword CHARMAP in column 1.

The following lines may have one of the two following forms to define the character-encodings:

<symbolic-name> <encoding> <comments>
This form defines exactly one character and its encoding.
<symbolic-name>...<symbolic-name> <encoding> <comments>
This form defines a couple of characters. This is only useful for mutlibyte-characters, which are currently not implemented.

The last line in a charmap-definition file must contain END CHARMAP.  

SYMBOLIC NAMES

A symbolic name for a character contains only characters of the portable character set. The name itself is enclosed between angle brackets. Characters following an <escape_char> are interpreted as itself; for example, the sequence '<\\\\\\>>' represents the symbolic name '\\>' enclosed in angle brackets.  

CHARACTER ENCODING

The encoding may be in each of the following three forms:

<escape_char>d<number>
with a decimal number
<escape_char>x<number>
with a hexadecimal number
<escape_char><number>
with an octal number.

FILES

/usr/share/i18n/charmaps/*  

AUTHOR

Jochen Hein (jochen.hein@delphi.central.de)  

CONFORMING TO

POSIX.2  

SEE ALSO

locale(1), localedef(1), setlocale(3), localeconv(3), locale(5)

责任编辑:韩亚珊 来源: 互联网
相关推荐

2011-08-24 16:48:36

man中文man

2011-08-15 10:21:09

man中文man

2011-08-11 16:11:49

at中文man

2011-08-25 10:21:56

man.conf中文man

2011-08-25 15:39:42

fcloseall中文man

2011-08-25 15:00:15

cfgetispeed中文man

2011-08-25 09:29:35

udp中文man

2011-08-19 18:35:50

issue中文man

2011-08-25 17:03:51

pclose中文man

2011-08-25 17:40:25

setvbuf中文man

2011-08-23 14:21:16

poweroff中文man

2011-08-24 15:52:59

intro中文man

2011-08-23 13:40:31

2011-08-25 15:54:08

ferror中文man

2011-08-25 14:40:27

basename中文man

2011-08-25 17:24:54

puts中文man

2011-08-24 18:05:31

SHOW中文man

2011-08-25 18:34:55

ungetc中文man

2011-08-23 10:03:40

useradd中文man

2011-08-16 10:42:30

rmmod中文man
点赞
收藏

51CTO技术栈公众号