Documentation/translations/zh_CN/admin-guide/unicode.rst

Source file repositories/reference/linux-study-clean/Documentation/translations/zh_CN/admin-guide/unicode.rst

File Facts

System
Linux kernel
Corpus path
Documentation/translations/zh_CN/admin-guide/unicode.rst
Extension
.rst
Size
6962 bytes
Lines
171
Domain
Support Tooling And Documentation
Bucket
Documentation
Inferred role
Support Tooling And Documentation: documentation
Status
atlas-only

Why This File Exists

Repository support layer: documentation, build tooling, samples, user-space helper tools, generated initramfs support, licenses, and validation utilities.

Dependency Surface

Detected Declarations

Annotated Snippet

.. include:: ../disclaimer-zh_CN.rst

:Original: Documentation/admin-guide/unicode.rst

:译者:

 吴想成 Wu XiangCheng <bobwxc@email.cn>

Unicode(统一码)支持
======================

	(英文版)上次更新:2005-01-17,版本号 1.4

此文档由H. Peter Anvin <unicode@lanana.org>管理,是Linux注册名称与编号管理局
(Linux Assigned Names And Numbers Authority,LANANA)项目的一部分。
现行版本请见:

	http://www.lanana.org/docs/unicode/admin-guide/unicode.rst

简介
-----

Linux内核代码已被重写以使用Unicode来将字符映射到字体。下载一个Unicode到字体
(Unicode-to-font)表,八位字符集与UTF-8模式都将改用此字体来显示。

这微妙地改变了八位字符表的语义。现在的四个字符表是:

=============== =============================== ================
映射代号        映射名称                        Escape代码 (G0)
=============== =============================== ================
LAT1_MAP        Latin-1 (ISO 8859-1)            ESC ( B
GRAF_MAP        DEC VT100 pseudographics        ESC ( 0
IBMPC_MAP       IBM code page 437               ESC ( U
USER_MAP        User defined                    ESC ( K
=============== =============================== ================

特别是 ESC ( U 不再是“直通字体”,因为字体可能与IBM字符集完全不同。
例如,即使加载了一个Latin-1字体,也允许使用块图形(block graphics)。

请注意,尽管这些代码与ISO 2022类似,但这些代码及其用途都与ISO 2022不匹配;
Linux有两个八位代码(G0和G1),而ISO 2022有四个七位代码(G0-G3)。

根据Unicode标准/ISO 10646,U+F000到U+F8FF被保留用于操作系统范围内的分配
(Unicode标准将其称为“团体区域(Corporate Zone)”,因为这对于Linux是不准确
的,所以我们称之为“Linux区域”)。选择U+F000作为起点,因为它允许直接映射
区域以2的大倍数开始(以防需要1024或2048个字符的字体)。这就留下U+E000到
U+EFFF作为最终用户区。

[v1.2]:Unicodes范围从U+F000到U+F7FF已经被硬编码为直接映射到加载的字体,
绕过了翻译表。用户定义的映射现在默认为U+F000到U+F0FF,模拟前述行为。实际上,
此范围可能较短;例如,vgacon只能处理256字符(U+F000..U+F0FF)或512字符
(U+F000..U+F1FF)字体。

Linux 区域中定义的实际字符
---------------------------

此外,还定义了Unicode 1.1.4中不存在的以下字符;这些字符由DEC VT图形映射使用。
[v1.2]此用法已过时,不应再使用;请参见下文。

====== ======================================
U+F800 DEC VT GRAPHICS HORIZONTAL LINE SCAN 1
U+F801 DEC VT GRAPHICS HORIZONTAL LINE SCAN 3
U+F803 DEC VT GRAPHICS HORIZONTAL LINE SCAN 7
U+F804 DEC VT GRAPHICS HORIZONTAL LINE SCAN 9
====== ======================================

DEC VT220使用6x10字符矩阵,这些字符在DEC VT图形字符集中形成一个平滑的过渡。
我省略了扫描5行,因为它也被用作块图形字符,因此被编码为U+2500 FORMS LIGHT
HORIZONTAL。

Annotation

Implementation Notes