Module:RQ:nod:NT/documentation

Documentation for Module:RQ:nod:NT. [edit]
This page contains usage information, categories, interwiki links and other content describing the module.

This module is a data module providing a catalogue of passages from one particular book or article for each passage to demonstrate the existence of multiple Northern Thai words. The modules returns a 3-D array (technically a Lua table), indexed as follows:

  1. The outer index is the page number.
  2. The second index is a character string serving as the name of the passage within the page - using the first word is the simplest scheme.
  3. The third index is an element number - the text (item 1), its transliteration (item 2) (optional) and its translation (item 3).

The table has one named element, "reference", that holds the name of the template (namely, {{RQ:nod:NT}}) used to identify the source to the reader and format the quote, its transliteration and its translation. The table structure allows fields lang, p1 and p2 for uninterpreted passage to the reference template to customise its output. This particular module's table uses p1 as the English name of the verse quoted. The field applied to the innermost of the passage, page and table is the value passed on.

The intention is that the word will be highlighted when selected by these three indices. Words are assigned positive numbers and their boundaries are marked up in the form {number-word}. This mark up can be nested, so that words may contain other words. Different sections may have the same number; this allows for repeated words, overlapping words, and discontiguous translations.

The words are transcluded into a page using an invocation of the form {{RQ:nod:NT quote|4|c1v21_T|15}}; this example produces the text:

2017, Wycliffe Bible Translators, พระคริสตธรรมคัมภีร์ [New Testament], →ISBN, Matthew i.21, page 4:
มารีย์จะเกิดลูกป้อจาย เมื่อเกิดมาแล้วหื้อตั้งจื้อว่า ‘เยซู’ ย้อนว่าต้านจะจ้วยคนของต้านหื้อรอดป๊นบาปโต้ษ
maa-rii cà kə̀ət lûuk pɔ̂ɔ-caai. mʉ̂ʉa kəət maa lɛ́ɛo, hʉ̂ʉ tâŋ cʉ̂ʉ wâa 'yeesuu' yɔ̂ɔn wâa tâan cà cûuai khon khɔ̂ɔŋ tâan hʉ̂ʉ rɔ̂ɔt pón bàap tôot
Mary shall give birth to a male child. Once he has been born, you shall give him 'Jesus' as his name for the reason that it is he who shall help his people to escape from their sins.

There is no advantage in including a passage for the sake of one word; one can use {{RQ:nod:NT}} directly for that purpose.

For Thai script passages, the 'transliteration' follows the Wiktionary rules for Siamese, except that the voicing onset times are represented as d ~ t ~ th rather than d ~ dt ~ t. Note that for voiceless stops, the Thai script does not distinguish the late falling glottalised tone from the falling tone.

Exceptionally, 4th element of passages with names ending _T may be the Lanna script form. It will then be converted to the Lanna script form of the passage with corresponding name ending in _L, and the 5th element if any will be its transliteration.