BabelStone Blog


Saturday, 23 December 2006

Phags-pa Shaping Behaviour

Now that I have released my first Phags-pa font, I thought it would be useful to discuss Phags-pa shaping behaviour, as very few people are familiar with the script, and it is quite complex. Further information on the Phags-pa script, its encoding model and shaping behaviour can be found in Section 10.3 of The Unicode Standard version 5.0.

First of all, here is a table of the encoded Phags-pa characters (note that you need to have BabelStone Phags-pa Book installed to see the Phags-pa characters; also note that with IE the characters should be oriented vertically, but with other browsers they may not be).


Table of Encoded Phags-pa Characters

Code Point Character Character Name Usage
U+A840 PHAGS-PA LETTER KA Chinese
Mongolian
Sanskrit
Tibetan
U+A841 PHAGS-PA LETTER KHA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A842 PHAGS-PA LETTER GA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A843 PHAGS-PA LETTER NGA Chinese
Mongolian
Sanskrit
Tibetan
U+A844 PHAGS-PA LETTER CA Chinese
Tibetan
U+A845 PHAGS-PA LETTER CHA Chinese
Mongolian
Tibetan
Uighur
U+A846 PHAGS-PA LETTER JA Chinese
Mongolian
Tibetan
Uighur
U+A847 PHAGS-PA LETTER NYA Chinese
Sanskrit
Tibetan
U+A848 PHAGS-PA LETTER TA Chinese
Mongolian
Sanskrit
Tibetan
U+A849 PHAGS-PA LETTER THA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A84A PHAGS-PA LETTER DA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A84B PHAGS-PA LETTER NA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A84C PHAGS-PA LETTER PA Chinese
Mongolian
Sanskrit
Tibetan
U+A84D PHAGS-PA LETTER PHA Chinese
Sanskrit
Tibetan
U+A84E PHAGS-PA LETTER BA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A84F PHAGS-PA LETTER MA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A850 PHAGS-PA LETTER TSA Chinese
Sanskrit
Tibetan
U+A851 PHAGS-PA LETTER TSHA Chinese
Mongolian
Sanskrit
Tibetan
U+A852 PHAGS-PA LETTER DZA Chinese
Sanskrit
Tibetan
U+A853 PHAGS-PA LETTER WA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A854 PHAGS-PA LETTER ZHA Chinese
Tibetan
U+A855 PHAGS-PA LETTER ZA Chinese
Mongolian
Tibetan
U+A856 PHAGS-PA LETTER SMALL A Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A857 PHAGS-PA LETTER YA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A858 PHAGS-PA LETTER RA Mongolian
Sanskrit
Tibetan
Uighur
U+A859 PHAGS-PA LETTER LA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85A PHAGS-PA LETTER SHA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85B PHAGS-PA LETTER SA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85C PHAGS-PA LETTER HA Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85D PHAGS-PA LETTER A Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85E PHAGS-PA LETTER I Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A85F PHAGS-PA LETTER U Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A860 PHAGS-PA LETTER E Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A861 PHAGS-PA LETTER O Chinese
Mongolian
Sanskrit
Tibetan
Uighur
U+A862 PHAGS-PA LETTER QA Mongolian
Uighur
U+A863 PHAGS-PA LETTER XA Chinese
Mongolian
U+A864 PHAGS-PA LETTER FA Chinese
Uighur
U+A865 PHAGS-PA LETTER GGA Unknown
U+A866 PHAGS-PA LETTER EE Chinese
Mongolian
Uighur
U+A867 PHAGS-PA SUBJOINED LETTER WA Chinese
Sanskrit
Tibetan
U+A868 PHAGS-PA SUBJOINED LETTER YA Chinese
Sanskrit
Tibetan
U+A869 PHAGS-PA LETTER TTA Sanskrit
U+A86A PHAGS-PA LETTER TTHA Sanskrit
U+A86B PHAGS-PA LETTER DDA Sanskrit
U+A86C PHAGS-PA LETTER NNA Sanskrit
U+A86D PHAGS-PA LETTER ALTERNATE YA Chinese
U+A86E PHAGS-PA LETTER VOICELESS SHA Chinese
U+A86F PHAGS-PA LETTER VOICED HA Chinese
U+A870 PHAGS-PA LETTER ASPIRATED FA Chinese
U+A871 PHAGS-PA SUBJOINED LETTER RA Sanskrit
Tibetan
U+A872 PHAGS-PA SUPERFIXED LETTER RA Tibetan
U+A873 PHAGS-PA LETTER CANDRABINDU Sanskrit
U+A874 PHAGS-PA SINGLE HEAD MARK Tibetan
U+A875 PHAGS-PA DOUBLE HEAD MARK Tibetan
U+A876 PHAGS-PA MARK SHAD Tibetan
U+A877 PHAGS-PA MARK DOUBLE SHAD Tibetan


1. Ligation

Phags-pa characters form syllable units in which the letters comprising a syllable ligate together, and each syllable unit is separated from each other by white space. Letters normally ligate along a stem running down the right side, but mirrored letters used for Sanskrit ligate along the left side, and the vowel o joins down a central stem. Examples of words in different languages are given below.


Chinese

mung gu wun ꡏꡟꡃ ꡂꡟ ꡓꡟꡋ

mengguwen 蒙古文 "Mongolian"


Mongolian

ta layi ꡈ ꡙꡗꡞ

dalai ᠳᠠᠯᠠᠢ "ocean"

Note that layi is considered a single syllable as ayi is used to represent a final /ai/ diphthong in Mongolian and Sanskrit.


Sanskrit

pra tish tthi te ꡌꡱ ꡈꡞꡚ ꡪꡞ ꡈꡠ

pratiṣṭhite


Tibetan

sangs rgyas ꡛꡃꡛ ꡲꡂꡨꡛ

sangs-rgyas "Buddha"


Uighur

quth luq ꡢꡟꡉ ꡙꡟꡢ

qutlugh "good fortune"



2. Vowel Forms

The four vowels I, U, E and O have distinct positional forms, as shown in the table below.



3. Mirrored Letters

A mirrored series of the letters TA, THA, DA and NA are used in the Sanskrit Phags-pa inscriptions at Juyongguan 居庸關. These letters, which represent the Sanskrit retroflex letters ṭa, ṭha, ḍa and ṇa, are not found in any other extant Phags-pa text or inscription. For example, on the 1348 Dunhuang inscription Sanskrit maṇi is represented in Phags-pa script as MA NI ꡏ ꡋꡞ with no mirroring. Note that a mirrored letter SHA representing Sanskrit ṣha does not occur, and so the kṣh combination is written with the Phags-pa letters KA followed by unmirrored SHA in the Juyongguan inscriptions.

These four mirrored letters affect the shape of the following letter as follows :


When mirrored letters are joined together they ligate along a lefthand stem rather than the righhand stem as is normally the case. If the letter TTHA is followed by an unmirrored Small A the ligature may be on the right or the left side.

As the mirrored forms of the letters I, U, E, Small A, HA and Subjoined YA are contextual glyph variants they are not encoded as separate characters, but are automatically selected by the rendering system as appropriate. In practical terms this means that an OpenType Phags-pa font will have normal and mirrored forms of theses characters and apply a substitution rule to replace the normal form with the mirrored form after a mirrored form glyph. These rules are applied automatically by the rendering system so that the normal or mirrored form, as appropriate for the particular context, is displayed automatically without any need for user intervention.

My Phags-pa fonts follow the agreed shaping behaviour for Phags-pa (see section 10.3 of The Unicode Standard version 5.0), which is to mirror the glyph for the letters Small A [U+A856], HA [U+A85C], I [U+A85E], U [U+A85F], E [U+A860] and Subjoined YA [U+A868] after the letters TTA [U+A869], TTHA [U+A86A], DDA [U+A86B] or NNA [U+A86C] or after another mirrored glyph.

However, there are times when the user may wish to override the default mirroring behaviour, for example in order to display mirrored glyph forms in isolation or in order to represent those examples of unmirrored I after the letter TTHA or unmirrored Small A after the letters TTA and TTHA that occur in the Juyongguan inscriptions. This is acheived by means of variation selectors. For Phags-pa VS1 [U+FE00] is used to produce the opposite form of a reversing letter that would be expected from its context. This is an important distinction to note, as it differs from the behaviour of mathematical standardized variants, where a particular variation sequence always produces the same glyph. Thus for Phags-pa the sequence U, VS1 <U+A85F U+FE00> will produce an unmirrored letter U glyph if it occurs after one of the letters TTA, TTHA, DDA or NNA or after a mirrored glyphform of the letters I, U, E, Small A, HA or Subjoined YA, but will produce a mirrored letter U if the sequence occurs after any other Phags-pa letter or in isolation.

Some examples of Sanskrit words that have mirrored and unmirrored glyphs are shown below.


Mirrored I after TTHA, NNA

dhish tthi te ꡊꡜꡞꡚ ꡪꡞ ꡈꡠ [dhiṣṭhite]

ush nni ꡟꡚ ꡬꡞ [uṣṇīṣa]


Unmirrored I after TTHA

dhish tthi te ꡊꡜꡞꡚ ꡪꡞ︀ ꡈꡠ [dhiṣṭhite]

pra tish tthi te ꡌꡱ ꡈꡞꡚ ꡪꡞ︀ ꡈꡠ [pratiṣṭhite]


Mirrored U after NNA

kshu nnu ꡀꡚꡟ ꡬꡟ [kṣuṇu]


Mirrored E after TTHA, DDA, NNA

nish tthe ꡋꡞꡚ ꡪꡠ [niṣṭhe]

dann dde ꡊꡬ ꡫꡠ [daṇḍaya]

ha ra nne ꡜ ꡘ ꡬꡠ [haraṇe]


Mirrored HA after DDA

'a- kad ddha ya ꡝꡖ ꡀꡊ ꡫꡜ ꡗ [ākaḍḍhaya]


Mirrored Subjoined YA after NNA

pu nnya ꡌꡟ ꡬꡨ [puṇya]


Mirrored Small A after TTHA

dhish ttha- na ꡊꡜꡞꡚ ꡪꡖ ꡋ [dhiṣṭhana]


Unmirrored Small A after TTA, TTHA

sha tta- pa ra mi ta ꡚ ꡩꡖ︀ ꡌ ꡘ ꡏꡞ ꡈ [ṣaṭ pāramitā]

dhish ttha- na ꡊꡜꡞꡚ ꡪꡖ︀ ꡋ [dhiṣṭhana]



Tags:

Phags-pa | Unicode

Index of BabelStone Blog Posts