Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/diskdance/gadget-text-spacing

Adjust spacing between Chinese and other scripts automatically
https://github.com/diskdance/gadget-text-spacing

mediawiki mediawiki-gadget wikipedia

Last synced: 2 days ago
JSON representation

Adjust spacing between Chinese and other scripts automatically

Awesome Lists containing this project

README

        

# 优化中文混排字距小工具 / Chinese Inter-script Spacing Optimization Gadget

本 MediaWiki 小工具借助 JavaScript 自动在中文和英文或数字混排时优化字距,以符合 [W3C 中文排版要求](https://www.w3.org/TR/clreq/#mixed_text_composition_in_horizontal_writing_mode),使排版更美观。

效果类似于 CSS Text Level 4 的 `text-autospace` 属性,目前(2023 年 8 月)主流浏览器并未实现该特性。

This MediaWiki gadget uses JavaScript to optimize spacing between Chinese with English and with numbers for better appearance, and to comply with [W3C's Requirements for Chinese Text Layout](https://www.w3.org/TR/clreq/#mixed_text_composition_in_horizontal_writing_mode).

The gadget works similar to `text-autospace` in CSS Text Level 4, which is not implemented in major browsers as of writing time (Aug 2023).

## 致谢 / Acknowledgements

本工具在开发过程中受到了 [CJ Typographer](https://github.com/hiugiak/cj-typo) 的启发,特此感谢。

This gadget is inspired by [CJ Typographer](https://github.com/hiugiak/cj-typo).

## 协议 / License

以 3 Clause BSD 协议授权。见 [LICENSE](./LICENSE) 以获取更多信息。

License under 3 Clause BSD. See [LICENSE](./LICENSE) file for more info.