Support for Devanagari script in LaTeX

Dirk Hünniger dirk.hunniger at googlemail.com
Tue Dec 3 20:56:24 CET 2019


Hi Niranjan,

I ran into similar problems when I wrote my mediawiki2latex programm to 
convert Wikipedia Pages to LaTeX. I faced many different symbols from 
many different languages. Devanagari  was one of them. In the end I now 
use xelatex and many different fonts, and switch between them using 
fontspec commands during the course of the LaTeX document. I am quite 
happy with that solution. My program writes the LaTeX file to disk, and 
while writing it looks for possible fonts for the next character and 
switches the font if necessary. In the early days of my development I 
used pdflatex instead. I generated my own ttf font for the 16 bit 
unicode range by mixing from different existing fonts and recalculated 
the kerning. I could somehow pass that font to pdflatex and get results 
that way, the file are still available on mediawiki2latex sourceforge 
page, but I do not recommend to use them. I suggest to use xelatex 
instead. With the pdflatex approach I remember a limit 256 character per 
"font part", so I also had to do some switching there. It made me 
remember old daisy wheel printers, just that the computer was replacing 
the wheel automatically and I did have to do it by hand.

Yours Dirk

On 12/3/19 7:48 AM, निरंजन wrote:
> Hello all,
>
> Let me begin with the primary declaration that I've a very little 
> knowledge of how TeX works, I have some requests regarding the 
> compiler. Please correct me if I have understood something wrong.
>
> This <http://www.tug.org/FontCatalogue/> is a link which I found for 
> LaTeX fonts. This collection does not include Devanagari fonts. 
> Devanagari is a script which has dedicated Unicode numbers which can 
> be found here <https://unicode.org/charts/PDF/U0900.pdf>. I've 
> attached three zip files namely Yashovenu, Yashomudra and Jaini. 
> Yashovenu is a free and open source font (project link 
> <https://github.com/RajyaMarathiVikasSanstha/Yashovenu>) which is Sans 
> Serif by style. Yashomudra is the serif version of the same font. No 
> need to mention that it is also free and open source (project link 
> <https://github.com/RajyaMarathiVikasSanstha/Yashomudra>). Both of 
> these fonts are available in all the weights. Jaini is an old style 
> Devanagari font (again open source, this 
> <https://github.com/EkType/Jaini> is the project link). Unfortunately 
> this font is not available in all the weights, but it contains one 
> variant named Jaini-Purva which is an even older style of Devanagari 
> script.
>
> The point of mentioning all of this is Devanagari is a completely 
> computer-friendly script. Is it possible to include at least these 
> four fonts in the TeXLive distribution as the representatives of 
> Devanagari script? The purpose would be a step towards localization of 
> LaTeX project. Right now if Devanagari is to be used in LaTeX, one has 
> to load fontspec or polyglossia or other packages like these and 
> compile the document with XeLaTeX or LuaLaTeX. Consider this as a 
> feature request for making PdfLaTeX also able to compile Devanagari 
> characters in input and giving output in some default Devanagari 
> fonts. (Preferably the attached one.) My idea would be to have simple 
> commands like *\fontstyle* with following options of (compulsory) 
> arguments -
>
>  1. "\sansserif" - (Yashovenu)
>  2. "\serif" - (Yashomudra)
>  3. "\olddeva" - (Jaini)
>  4. "\traditionaldeva - (Jaini Purva)
>
> Please let me know if I can help you in any ways. If there are some 
> technical (or TeXnical) problems, please make me aware of the same. I 
> would be very happy to work for this small step of localization if needed.
>
> Waiting for your response.
>
> Regards,
> Niranjan
> Department of Linguistics,
> University of Mumbai.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/texhax/attachments/20191203/37c70c43/attachment.html>


More information about the texhax mailing list