2007
Using Devanagari in Latex

Ever wanted to write latex documents in Hindi, Marathi or Sanskrit? This article shows you how to do just that. At the end of this article, you’ll learn to go from here:

to here:

Setting up your system
On Windows
- Download and Install MikTeX.
Start the Package Manager.

Next, locate and install the devanagari package.

- Get the Devnag Binary and copy it to
C:\Program Files\MiKTeX 2.7\miktex\bin\.
That’s it. We’re all set to write latex documents in Devanagari!
On Linux
If you’re running a debian based system, get the following packages: texlive-latex-base, texlive-lang-indic, texlive-fonts-recommended
Writing in devanagari
Now fire up your editor and add the following code:
1 2 3 4 5 6 7 8 9 10 11 12 | % Using devanagari in latex % http://pravin.insanitybegins.com/articles/ % Pravin Paratey [pravinp -at- gmail -dot- com] \documentclass[12pt]{article} \usepackage{devanagari} \begin{document} Lets write in devanagari {\dn calo devanagarI me likhate hai} \end{document} |
- Save this file as
sample.dn. - Next, go to the command line and type
devnag sample.dnto generate the corresponding sample.tex file. - Run
latex sample.texto generate sample.dvi
Figuring out what to type
Figuring out what string of English characters give a Devanagari word isn’t always apparent. This document should be somewhat useful.
8 Responses (rss) (trackback)
Bala
That is fine, but what if want to input text in Devnagari itself, and not in Roman? Is there a way to do that?
I have heard about omega, ucs.sty, etc., could you explain how to get these things working?
Dawar Praveen
achaa laga yaha aakar talash khatma ho gayI
dhanyabaad
praveen
P.C.
hi,
how do I write the letter “sha” (?) in the Devnag transliteration system?
dhanyavaada.
sindhu
is there a way i can get direct typesetting in hindi using latex? i dont want transileration, its too much of a pain to type.
Benjamin Slade
sindhu – you can use xelatex for direct typesetting in devanagari: http://scripts.sil.org/cms/scripts/page.php?site_id=nrsi&id=XeTeX
Satish
How do u type Marathi letter L which is unique to marathi only.
Is there any manual for the procedure you have explained ?
v8r
Hi,
Can you tell what is the procedure for MAC OS X?
Thanks,
v8r.



Amber Habib
Thanks – I wanted to add a comment about the pronunciation of the Greek letter chi to a TeX document and your page helped me do that using Devanagari.