Template:rad-pr/documentation: Difference between revisions
TheNightAvl (talk | contribs) mNo edit summary |
TheNightAvl (talk | contribs) mNo edit summary |
||
Line 9: | Line 9: | ||
on a polysyllabic word's page, such as {{m|rad|Aroír}}, will generate the standard pronunciation, the corresponding rhyme and the syllabification of the word: | on a polysyllabic word's page, such as {{m|rad|Aroír}}, will generate the standard pronunciation, the corresponding rhyme and the syllabification of the word: | ||
<hr> | |||
{{rad-pronunciation|entry=Aroír}} | {{rad-pronunciation|entry=Aroír}} | ||
<hr> | |||
On a monosyllabic word's page, such as {{m|rad|hars}}, the syllabification will not be present: | On a monosyllabic word's page, such as {{m|rad|hars}}, the syllabification will not be present: | ||
<hr> | |||
{{rad-pronunciation|entry=hars}} | {{rad-pronunciation|entry=hars}} | ||
<hr> | |||
On a multi-word entry's page, such as {{m|rad|Arans ag Eurúpjeșe}}, the rhyme will not be present. Words may also appear with a narrower phonetic transcription if applicable: | On a multi-word entry's page, such as {{m|rad|Arans ag Eurúpjeșe}}, the rhyme will not be present. Words may also appear with a narrower phonetic transcription if applicable: | ||
<hr> | |||
{{rad-pronunciation|entry=Arans ag Eurúpjeșe}} | {{rad-pronunciation|entry=Arans ag Eurúpjeșe}} | ||
<hr> | |||
With words pronounced differently in the ''[[:Appendix:Radestrian_pronunciation|hjádvanþs]]'' standard, such as {{m|rad|hjárs}}, it will appear in the dialect section: | With words pronounced differently in the ''[[:Appendix:Radestrian_pronunciation|hjádvanþs]]'' standard, such as {{m|rad|hjárs}}, it will appear in the dialect section: | ||
<hr> | |||
{{rad-pronunciation|entry=hjárs}} | {{rad-pronunciation|entry=hjárs}} | ||
<hr> | |||
==Additional parameters== | ==Additional parameters== | ||
Line 27: | Line 35: | ||
All arguments given after the activation of a mode are interpreted as arguments for that mode. <code>|IPA</code>, however, is selected by default. Additional arguments given in <code>IPA</code> will come with a generated rhyme where possible. | All arguments given after the activation of a mode are interpreted as arguments for that mode. <code>|IPA</code>, however, is selected by default. Additional arguments given in <code>IPA</code> will come with a generated rhyme where possible. | ||
<hr> | |||
: <big>{{l|rad|us}}</big> | : <big>{{l|rad|us}}</big> | ||
{{tempn|rad-pronunciation|/us/}} | {{tempn|rad-pronunciation|/us/}} | ||
{{rad-pronunciation|entry=us|/us/}} | {{rad-pronunciation|entry=us|/us/}} | ||
<hr> | |||
You can toggle modes by calling their name. | You can toggle modes by calling their name. | ||
<hr> | |||
: <big>{{l|rad|às}}</big> | : <big>{{l|rad|às}}</big> | ||
{{tempn|rad-pronunciation|homophones|as|‘as}} | {{tempn|rad-pronunciation|homophones|as|‘as}} | ||
{{rad-pronunciation|entry=às|homophones|as|‘as}} | {{rad-pronunciation|entry=às|homophones|as|‘as}} | ||
<hr> | |||
In <code>syllables</code> mode, syllables are divided as arguments, with multiple entries divided by <code>||</code>, as in {{temp|syllables}}. | In <code>syllables</code> mode, syllables are divided as arguments, with multiple entries divided by <code>||</code>, as in {{temp|syllables}}. | ||
<hr> | |||
: <big>{{l|rad|asedua}}</big> | : <big>{{l|rad|asedua}}</big> | ||
{{tempn|rad-pronunciation|syllables|a|se|dua||a|sed|ua}} | {{tempn|rad-pronunciation|syllables|a|se|dua||a|sed|ua}} | ||
{{rad-pronunciation|entry=asedua|syllables|a|se|dua||a|sed|ua}} | {{rad-pronunciation|entry=asedua|syllables|a|se|dua||a|sed|ua}} | ||
<hr> | |||
Dialects and registers are <i>sub-modes</i> under <code>IPA</code>. Calling these will set the arguments to be interpreted under the previously selected dialect/register. The standard dialect and plain register are selected by default. Calling a dialect will reset the register. Calling a dialect or register outside of <code>IPA</code> mode will switch to <code>IPA</code> mode, and the dialect and register will be reset. Non-standard dialects do not contribute to the rhyme generation. | Dialects and registers are <i>sub-modes</i> under <code>IPA</code>. Calling these will set the arguments to be interpreted under the previously selected dialect/register. The standard dialect and plain register are selected by default. Calling a dialect will reset the register. Calling a dialect or register outside of <code>IPA</code> mode will switch to <code>IPA</code> mode, and the dialect and register will be reset. Non-standard dialects do not contribute to the rhyme generation. | ||
<hr> | |||
: <big>{{l|rad|ag}}</big> | : <big>{{l|rad|ag}}</big> | ||
{{tempn|rad-pronunciation|colloquial|/ɤɡ/}} | {{tempn|rad-pronunciation|colloquial|/ɤɡ/}} | ||
{{rad-pronunciation|entry=ag|colloquial|/ɤɡ/}} | {{rad-pronunciation|entry=ag|colloquial|/ɤɡ/}} | ||
<hr> | |||
: <big>{{l|rad|rvaus}}</big> | : <big>{{l|rad|rvaus}}</big> | ||
{{tempn|rad-pronunciation|insular|/rˠoːs/}} | {{tempn|rad-pronunciation|insular|/rˠoːs/}} | ||
{{rad-pronunciation|entry=rvaus|insular|/rˠoːs/}} | {{rad-pronunciation|entry=rvaus|insular|/rˠoːs/}} | ||
<hr> | |||
: <big>{{l|rad|rvaus}}</big> | : <big>{{l|rad|rvaus}}</big> | ||
{{tempn|rad-pronunciation|insular|/rˠoːs/|colloquial|[ɹoːs]}} | {{tempn|rad-pronunciation|insular|/rˠoːs/|colloquial|[ɹoːs]}} | ||
{{rad-pronunciation|entry=rvaus|insular|/rˠoːs/|colloquial|[ɹoːs]}} | {{rad-pronunciation|entry=rvaus|insular|/rˠoːs/|colloquial|[ɹoːs]}} | ||
<hr> | |||
Automatic <code>IPA</code> and <code>syllables</code> can be turned off by calling <code>|no auto</code> in their respective modes. Note that rhyme is automatically generated for each standard input regardless. Although automatic generation can be turned off, a standard IPA transcription in plain register must still be inputted. | Automatic <code>IPA</code> and <code>syllables</code> can be turned off by calling <code>|no auto</code> in their respective modes. Note that rhyme is automatically generated for each standard input regardless. Although automatic generation can be turned off, a standard IPA transcription in plain register must still be inputted. | ||
<hr> | |||
: <big>{{l|rad|Aroír}}</big> | : <big>{{l|rad|Aroír}}</big> | ||
{{tempn|rad-pronunciation|syllables|no auto}} | {{tempn|rad-pronunciation|syllables|no auto}} | ||
{{rad-pronunciation|entry=Aroír|syllables|no auto}} | {{rad-pronunciation|entry=Aroír|syllables|no auto}} | ||
<hr> | |||
: <big>{{l|rad|ag}}</big> | : <big>{{l|rad|ag}}</big> | ||
{{tempn|rad-pronunciation|no auto|/ɤɡ/}} | {{tempn|rad-pronunciation|no auto|/ɤɡ/}} | ||
{{rad-pronunciation|entry=ag|no auto|/ɤɡ/}} | {{rad-pronunciation|entry=ag|no auto|/ɤɡ/}} | ||
<hr> | |||
Otherwise you get an error: | Otherwise you get an error: | ||
<hr> | |||
: <big>{{l|rad|ag}}</big> | : <big>{{l|rad|ag}}</big> | ||
{{tempn|rad-pronunciation|no auto}} | {{tempn|rad-pronunciation|no auto}} | ||
{{rad-pronunciation|entry=ag|no auto}} | {{rad-pronunciation|entry=ag|no auto}} | ||
<hr> | |||
See? | See? | ||
Line 82: | Line 97: | ||
There is one last parameter, {{para|entry}}, which can be used to override the automatic input from the page name, though this is only applicable in exemplification settings, such as this one. | There is one last parameter, {{para|entry}}, which can be used to override the automatic input from the page name, though this is only applicable in exemplification settings, such as this one. | ||
<hr> | |||
: <big>{{l|rad|Aroír}}</big> | |||
{{tempn|rad-pronunciation|entry=Aroír|syllables|no auto}} | {{tempn|rad-pronunciation|entry=Aroír|syllables|no auto}} | ||
allows me to call {{temp|rad-pronunciation|syllables|no auto}} outside of the {{m|rad|Aroír}} page. | allows me to call {{temp|rad-pronunciation|syllables|no auto}} outside of the {{m|rad|Aroír}} page. | ||
<hr> |
Revision as of 04:43, 22 August 2023
Uses Lua: |
Usage
This template can be added to a Radestrian entry, and it will automatically generate and format the pronunciation section.
There are no mandatory parameters: the template alone will generate the pronunciation from the page title and create the relevant list of rhymes and syllabification.
{{rad-pronunciation}}
on a polysyllabic word's page, such as Aroír, will generate the standard pronunciation, the corresponding rhyme and the syllabification of the word:
On a monosyllabic word's page, such as hars, the syllabification will not be present:
On a multi-word entry's page, such as Arans ag Eurúpjeșe, the rhyme will not be present. Words may also appear with a narrower phonetic transcription if applicable:
With words pronounced differently in the hjádvanþs standard, such as hjárs, it will appear in the dialect section:
Additional parameters
Extra information can be added through extra arguments. There are three modes of extra argument:
|IPA
|syllables
|homophones
All arguments given after the activation of a mode are interpreted as arguments for that mode. |IPA
, however, is selected by default. Additional arguments given in IPA
will come with a generated rhyme where possible.
{{rad-pronunciation|/us/}}
You can toggle modes by calling their name.
{{rad-pronunciation|homophones|as|‘as}}
In syllables
mode, syllables are divided as arguments, with multiple entries divided by ||
, as in {{syllables}}
.
{{rad-pronunciation|syllables|a|se|dua||a|sed|ua}}
Dialects and registers are sub-modes under IPA
. Calling these will set the arguments to be interpreted under the previously selected dialect/register. The standard dialect and plain register are selected by default. Calling a dialect will reset the register. Calling a dialect or register outside of IPA
mode will switch to IPA
mode, and the dialect and register will be reset. Non-standard dialects do not contribute to the rhyme generation.
{{rad-pronunciation|colloquial|/ɤɡ/}}
{{rad-pronunciation|insular|/rˠoːs/}}
{{rad-pronunciation|insular|/rˠoːs/|colloquial|[ɹoːs]}}
Automatic IPA
and syllables
can be turned off by calling |no auto
in their respective modes. Note that rhyme is automatically generated for each standard input regardless. Although automatic generation can be turned off, a standard IPA transcription in plain register must still be inputted.
{{rad-pronunciation|syllables|no auto}}
{{rad-pronunciation|no auto|/ɤɡ/}}
Otherwise you get an error:
{{rad-pronunciation|no auto}}
Lua error in Module:rad-pronunciation at line 230: Missing IPA input.
See?
There is one last parameter, |entry=
, which can be used to override the automatic input from the page name, though this is only applicable in exemplification settings, such as this one.
{{rad-pronunciation|syllables|no auto|entry=Aroír}}
allows me to call {{rad-pronunciation|syllables|no auto}}
outside of the Aroír page.