|
1 | 1 | #  |
2 | 2 |
|
3 | | -## font-xibo |
| 3 | +> 简体中文 | [ENGLISH](README.en.md) |
4 | 4 |
|
5 | | -<div style="display: flex; flex-direction: row; justify-content: space-between;"> |
6 | | - <div> |
| 5 | +## font-xibo |
7 | 6 |
|
8 | 7 | xibo 是一个为 Linux 设计的中文 TTY 字体,旨在在不安装诸如 [cjktty](https://github.com/zhmars/cjktty-patches) 等内核补丁且不安装 [kmscon](http://www.freedesktop.org/wiki/Software/kmscon)、[fbterm](https://salsa.debian.org/debian/fbterm) 或 [zhcon](https://zhcon.sourceforge.net/) 等第三方软件的环境下提供 TTY 中文显示。 |
9 | 8 |
|
@@ -53,72 +52,12 @@ xibo 是一个为 Linux 设计的中文 TTY 字体,旨在在不安装诸如 [c |
53 | 52 |
|
54 | 53 | ## 许可协议 |
55 | 54 |
|
| 55 | +> 感谢**文泉驿**团队提供的`文泉驿点阵宋体 v1.0.0-RC1 英雄`字体。 |
| 56 | +
|
56 | 57 | 本仓库中的脚本文件 `build.bash` 和 `build_font_from_bdf.py` 遵循 [GNU GENERAL PUBLIC LICENSE Version 3 许可协议](LICENSE), |
57 | 58 | `original/references/` 目录下的所有参照文件遵循 [Unlicense 许可协议](original/references/LICENSE), |
58 | 59 | 本项目生成的字体文件遵循[自由中文字体和 GNU GENERAL PUBLIC LICENSE Version 2 许可协议](FONT-LICENSE)。 |
59 | 60 |
|
60 | 61 | ## 做出贡献 |
61 | 62 |
|
62 | 63 | 请参照[贡献指北](CONTRIBUTING.md)。 |
63 | | - |
64 | | - </div> |
65 | | - <div> |
66 | | - |
67 | | -Xibo is a Chinese TTY font designed for Linux, aiming to provide Chinese display in TTY without installing kernel patches such as [cjktty](https://github.com/zhmars/cjktty-patches) or third-party software like [kmscon](http://www.freedesktop.org/wiki/Software/kmscon), [fbterm](https://salsa.debian.org/debian/fbterm), or [zhcon](https://zhcon.sourceforge.net/). |
68 | | - |
69 | | -The inspiration for this project comes from the [syllazh](https://github.com/oldherl/syllazh/) font. |
70 | | - |
71 | | -## Phonetic Characters |
72 | | - |
73 | | -When using this font, you may notice that characters with similar pronunciations are displayed as the same character. For example, any of the characters “用永勇拥擁涌湧咏詠蛹雍踊庸踴泳” will be uniformly displayed as “用”. |
74 | | - |
75 | | -This is because fonts on Linux TTY are generally changed using the `setfont` tool from the kbd package, which supports a maximum of 512 glyphs. However, a single glyph can map to multiple Unicode code points. |
76 | | -Therefore, Xibo maps all characters with the same pronunciation (ignoring tones) to the same glyph, allowing for Chinese character display within the limited number of glyphs. |
77 | | - |
78 | | -## Building the Font |
79 | | - |
80 | | -1. Clone the repository: |
81 | | - |
82 | | - ```shellscript |
83 | | - git clone https://github.com/PJ-568/font-xibo.git |
84 | | - cd font-xibo |
85 | | - ``` |
86 | | - |
87 | | -2. Install dependencies: |
88 | | - |
89 | | - ```shellscript |
90 | | - pip install -r requirements.txt |
91 | | - ``` |
92 | | - |
93 | | -3. Build the font: |
94 | | - |
95 | | - ```shellscript |
96 | | - bash build.bash |
97 | | - ``` |
98 | | - |
99 | | - During the build process, the script will install `psftools`, which is used to generate the font. |
100 | | - |
101 | | -After building, a PSF2 font file named `xibo.psfu.gz` will be generated in the `output/` directory. |
102 | | - |
103 | | -## Using the Font |
104 | | - |
105 | | -> Ensure that the version of the `setfont` command is `2.6rc1` or higher. |
106 | | -> Versions prior to `2.6rc1` do not support fonts larger than 65535 (approximately 64KB). |
107 | | -> After `2.6rc1`, the limit has been relaxed to 4194304 (approximately 4MB). |
108 | | -> |
109 | | -> Run `setfont -V` to check the version. |
110 | | -
|
111 | | -Place `xibo.psfu.gz` in the `consolefonts` directory (located at `/usr/share/consolefonts/` on Debian and `/usr/share/kbd/consolefonts/` on Arch Linux), then execute `setfont xibo` to change the font or `setfont -d xibo` to switch to a double-sized font. |
112 | | - |
113 | | -## License |
114 | | - |
115 | | -The script files `build.bash` and `build_font_from_bdf.py` in this repository are licensed under the [GNU GENERAL PUBLIC LICENSE Version 3](LICENSE). |
116 | | -All reference files in the `original/references/` directory are licensed under the [Unlicense](original/references/LICENSE). |
117 | | -The generated font files in this project are licensed under the [Free Chinese Font License and GNU GENERAL PUBLIC LICENSE Version 2](FONT-LICENSE). |
118 | | - |
119 | | -## Contributing |
120 | | - |
121 | | -Refer to the [Contribution Guide](CONTRIBUTING.md). |
122 | | - |
123 | | - </div> |
124 | | -</div> |
0 commit comments