Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I want to write in urdu with nastaleeq font. I have done quite a few things but i dont know how to write it. Plus i dont know how to use xetex. So can anyone give me a simple example writing urdu in the desired font and how to run it on texmaker.

share|improve this question
1  
Try patriot.net/~abdali/urdumac.html#TypesettingWithTeX, should mostly apply to non-Mac users as well. –  Khaled Hosny Sep 27 '13 at 7:37
    
Could it be persian nastaleeq? I know udro and persian are fairly similar but I'm not sure about different characters... –  Pouya Sep 27 '13 at 14:35
    
i couldnt get anything that i wanted from the above link. If you know how to run xetex in texmaker(which changes are required in the settings) then do tell me –  Shaheryar Sep 29 '13 at 9:10

1 Answer 1

Here is a typesetting of poem using IranNastaliq font and XePersian package. XePersian is included in texlive and in case you are missing it, you can get it from CTAN. One problem here is the font. IranNastaliq is designed for persian/farsi alphabet and despite of similarities between persian and urdu, it misses some of letters of urdu such as

enter image description here

This being said, I think you can find an urdu nastaliq font, just add it to you tex file and you will be good to go. I don't see any major difference between typesetting persian and urdu. Here is a sample tex file containing a poem from Saadi with nastaliq font.

\documentclass[a4paper]{article}
%\usepackage{persianpoem}
\usepackage{xepersian}
\settextfont[Scale=1.3]{IranNastaliq}
\renewcommand{\baselinestretch}{3.0}
\newcommand{\myverse}[2]{%
\makebox[4cm][s]{#1}
\makebox[2cm][s]{}
\makebox[4cm][s]{#2}%
}
\begin{document}
\pagestyle{empty}

\title{سر عشق}
\author{سعدی}
\date{\today}
\maketitle

\thispagestyle{empty}

\myverse{هزار جهد بکردم که سر عشق بپوشم}
{نبود بر سر آتش میسرم که نجوشم}


\myverse{به هوش بودم از اول که دل به کس نسپارم}
{شمایل تو بدیدم نه عقل ماند و نه هوشم}


\myverse{به راه بادیه رفتن به از نشستن باطل}
{که گر مراد نیابم به قدر وسع بکوشم}



\end{document}

which gives you this:

enter image description here

Please note that this is just a MWE and needs certain modification to be suitable for you purpose.

You can compile this from command line using:

xelatex your_poem.tex

To you use it with TexMaker, refer to this question.

enter image description here

Above tex sample is borrowed from XePersian Forum and it's respected creator.

share|improve this answer
    
i tired the things that were given in the link provided by you but it keeps on running like forever ; The texmaker i have installed on my system has a option in Option ....> configure....> Quick build -----> Xelatex + pdf i checked this one but it gives the error ! Fatal fontspec error: "cannot-use-pdftex" ! ! The fontspec package requires either XeTeX or LuaTeX to function. ! ! You must change your typesetting engine to, e.g., "xelatex" or "lualatex" What should i do now ? –  Shaheryar Oct 4 '13 at 5:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.