Module:Hani-sortkey/documentation

From Wiktionary, the free dictionary
Jump to navigation Jump to search
Documentation for Module:Hani-sortkey. [edit]
This page contains usage information, categories, interwiki links and other content describing the module.

This module will sort text in the Han script. It is used to sort Ai-Cham, Southern Amami-Oshima, Central Bai, Panyi Bai, Southern Bai, Biao-Jiao Mien, Biyo, Eastern Min, Jin, Mandarin, Northern Pinghua, Chinese Pidgin English, Puxian Min, Macau Pidgin Portuguese, Southern Pinghua, Huizhou, Central Min, Dungan, Daur, E, Gan, Hakka, Xiang, Japanese, Hachijō, Kikai, Lama Bai, Middle Chinese, Literary Chinese, Middle Vietnamese, Caolan, Northern Min, Translingual, Miyako, Min Nan, Hokkien, Hainanese, Leizhou Min, Teochew, Nùng, Old Chinese, Old Japanese, Oki-No-Erabu, Old Uyghur, Bouyei, Baekje, Rouran, Tuyuhun, Tuoba, Wuhuan, Xianbei, Northern Amami-Oshima, Yaeyama, Okinawan, Sui, Bailang, Toku-No-Shima, Alchuka, Bala, Kyakala, Tày, Jie, Vietnamese, Wu, Waxiang, Classical Tibetan, Middle Mongol, Buyeo, Kunigami, Yonaguni, Yoron, Cantonese, Zhuang, Zauzou, Chinese, Shaozhou Tuhua, Sichuanese, Taishanese, Goguryeo, Zakhring, and Khitan. 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/testcases.

Functions

makeSortKey(text, lang, sc)
Generates a sortkey for a given piece of text written in the script specified by the code sc, and language specified by the code lang.
When the sort fails, returns nil.

The demonstration functions that generated the content shown below are housed in Module:Hani-sortkey/templates. Modifications to the module can be tested in Module:Hani-sortkey/sandbox. Sortkeys for individual characters are retrieved from one of 178 data modules. Module:Hani-sortkey/data creates documentation for these modules.

Show sortkeys[edit]

  • (乙01)
  • 𡆔 (口23)
  • 𡎇 (土09)
  • 阿坝 (阜05土04)

Ideographic description sequences[edit]