![](https://secure.gravatar.com/avatar/5955e8e90611e77ccbfc7721b6112027.jpg?s=120&d=mm&r=g)
On 8/5/24 11:31, Jürgen Hanneder via ntg-context wrote:
I have a few questions concerning the commands for setting up Indic Fonts, specifically for the use of Indologists and other academics dealing with Indian Languages.
Hi Jürgen, just in case the following might help (no Indian language experience [I just learnt that Devanagari and Nagari were both scripts]).
This seems to be out of date and for most academics (especially outside of India) it is preferable to use Sanskrit in transcription (almost all databases use transcription) for input even if printing in Nāgarī. For this we now seem to have the transliteration IAST to Devanagari (?)
This may be the way (adapted from lang-tra.mkxl): \definefontfamily [nagari] [rm] [Adishila] [features=devanagari-one] \setupbodyfont [nagari] \usetransliteration[indic] \definetransliteration [MyDeva] [lang=sa, vector={iast to deva}] \starttext Is this Sanskrit? \starttransliteration[MyDeva] idaṁ adbhutam kauśika tisraḥ garuḍavāhanan \stoptransliteration I really don’t know: \transliteration[MyDeva]{idaṁ adbhutam kauśika tisraḥ garuḍavāhanan}. \stoptext As included in the text, I don’t have the slighliest idea whether the transliterated text may be Sanskrit.
What we need are thus three elements: switching the language to Sanskrit temporarily (the main language will be english),
\sa is the language switch (which also enables hyphenation). But since you need transliteration, it is automatically added in the defined transliteration.
setting the font for Sanskrit (let us say AsishilaSan),
You already defined that in your minimal sample.
and enabling input of sanskrit in transcription (input: ānanda -> output आनन्द).
See above.
If someone could tell me how to get all these things into a few commands, I would be most grateful. My own attempts, mostly trial and error, did not succeed.
Let us know whether the previous sample worked for you (or how it is failing). BTW, feel free to improve https://wiki.contextgarden.net/Indic_Scripts#IAST_to_Devanagari. I hope it helps, Pablo