0

I am trying to write a letter in Arabic using the KacstPen font. However, the resulting document does not show numerals nor symbols.

Does anyone know how to fix this? Below is the code and the resulting document:

\documentclass[12pt]{letter}
\usepackage[a4paper,left=2.5cm, right=2.5cm, top=0cm, bottom=0cm]{geometry}
\usepackage{graphicx}
\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage[calendar=gregorian,hijricorrection=1,locale=morocco]{arabic}
\setotherlanguage[variant=british]{english}
\setmainfont{KacstPen}


\address{سعيد  \\ دوار مديونة \\ رقم الهاتف: 0655850000}

\begin{document}
\begin{letter}{إلى السيد: المندوب الجهوي لمؤسسة وسيط المملكة\\ شارع مصطفي لحلو, حي الأدارسة\\ فاس 30040 المغرب}

\opening{\textbf{الموضوع: ملاحظات وتوضيحات حول التظلم عدد 19-24064} \\ \\ \\سلام تام بوجود مولانا الإمام:}


\closing{إمضاء:\\
%\fromsig{\includegraphics[scale=0.08]{signature4.png}} \\
\fromname{سعيد }
}


\end{letter}
\end{document}

And this is the result:

enter image description here

8
  • The font contains only the Arabic-Indic digits, not the glyphs you want.
    – Thérèse
    Jun 13 '20 at 15:26
  • @Thérèse Is there a way I can define another font only for digits and symbols? Jun 13 '20 at 15:28
  • How to do that depends on how you’re compiling: xetex? luatex?
    – Thérèse
    Jun 13 '20 at 15:31
  • @Thérèse I am compiling using Xelatex. Jun 13 '20 at 15:32
  • 1
    I don’t often use xetex, but I think the package ucharclasses will do what you want. Search for ucharclasses on this site to see examples of its usage.
    – Thérèse
    Jun 13 '20 at 15:36
1

On my system, the font is called kacstPen (not KacstPen) and has the digits.

kacstPen

MWE

\documentclass[12pt]{letter}
\usepackage[a4paper,left=2.5cm, right=2.5cm, top=0cm, bottom=0cm]{geometry}
\usepackage{graphicx}
\usepackage{fontspec}
\usepackage{polyglossia}
\setdefaultlanguage[calendar=gregorian,hijricorrection=1,locale=morocco]{arabic}
\setotherlanguage[variant=british]{english}
\setmainfont{kacstPen}


\address{سعيد  \\ دوار مديونة \\ رقم الهاتف: 0655850000}

\begin{document}
\begin{letter}{إلى السيد: المندوب الجهوي لمؤسسة وسيط المملكة\\ شارع مصطفي لحلو, حي الأدارسة\\ فاس 30040 المغرب}

\opening{\textbf{الموضوع: ملاحظات وتوضيحات حول التظلم عدد 19-24064} \\ \\ \\سلام تام بوجود مولانا الإمام:}


\closing{إمضاء:\\
%\fromsig{\includegraphics[scale=0.08]{signature4.png}} \\
\fromname{سعيد }
}


\end{letter}
\end{document}
2
  • According to various font sites, for kacstPen, KACST produce the Arabic part, and URW the Latin part. Perhaps KacstPen font is just the Arabic one??
    – Cicada
    Jun 14 '20 at 7:49
  • I had to change the font eventually, but I will try using your example. Thanks. Jun 15 '20 at 4:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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