模组:Hani-sortkey/doc
这是Module:Hani-sortkey的文档页面
This module will sort text in the 汉字.
The module should preferably not be called directly from templates or other modules.
To use it from a template, use {{sortkey}}
.
Within a module, use Module:languages#Language:makeSortKey.
For testcases, see Module:Hani-sortkey/doc/testcases.
Functions
makeSortKey(text, lang, sc)
- Generates a sortkey for a given piece of
text
written in the script specified by the codesc
, and language specified by the codelang
. - When the sort fails, returns
nil
.
产生如下所示内容的示范函数位于Module:Hani-sortkey/templates中。模组的修改可以在Module:Hani-sortkey/sandbox中进行测试。单一字元的排序键是从178个资料模组之一检索的。Module:Hani-sortkey/data为这些模组建立文件。
显示排序键[编辑]
- PS/2接口 (
PS/2手08口00
) - gas爐/gas炉 (
gas火16
) - γ粒子 (
γ米05子00
) - 命里有时终须有,命里无时莫强求 (
口05衣07月02日06糸05頁03月02,口05衣07火08日06艸07弓08水02
) - 得个……字 (
彳08人08……子03
) - 濕𣲷𣲷/湿𣲷𣲷 (
水14水05水05
) - 赛车 (
貝10車00
)
- 鿪 (
火13
)
表意文字描述序列[编辑]
- ⿰亻革 (
⿰人00革00
) - ⿰亻革家語/⿰亻革家语 (
⿰人00革00宀07言07
) - ⿺辶⿳穴⿲月⿱⿲幺言幺⿲長馬長刂心⿺辶⿳穴⿲月⿱⿲幺言幺⿲長馬長刂心麵/⿺辶⿳穴⿲月⿱⿲幺言幺⿲长马长刂心⿺辶⿳穴⿲月⿱⿲幺言幺⿲长马长刂心面 (
⿺辵00⿳穴00⿲月00⿱⿲幺00言00幺00⿲長00馬00長00刀00心00⿺辵00⿳穴00⿲月00⿱⿲幺00言00幺00⿲長00馬00長00刀00心00麥09
)