[XeTeX] footnotes and ArabXeTeX
Nathan Sidoli
nathan.sidoli at utoronto.ca
Wed Oct 5 16:16:59 CEST 2011
Here is one for Vafa in your new capacity as maintainer of ArabXeTeX.
Thanks for taking over this package! (I sent this to François some time
ago, but I don't think anything has been done about it.)
In certain environments, there is some problem with the input which is
controlled by ascii 'operators' such as ^ and _ and maybe some others.
For example, ش is input as ^s, ذ is input as _d, and so on. The letters
that are input using . seem to be unaffected.
The effect occurs in a number of environments, such as footnotes and
pstricks figures (it doesn't occur TikZ, and this is good, but many
people have legacy figures in pstricks). In these environments, the
operators seem to be treated as some sort of mathematical operator and
the compiler complains that a $ is missing and the file will not compile.
I have included a couple of minimal files, below.
------------------------------------------
\documentclass{article}
\usepackage{fontspec}
\setmainfont[Mapping=tex-text]{Junicode}
\usepackage[novoc,fdf2noalif]{arabxetex}
\newfontfamily\arabicfont[Script=Arabic,Scale=1.3,WordSpace=2]{Scheherazade}
\begin{document}
We have a footnote that contains the word
\textarab{al-^skl}.\footnote{\textarab{al-^skl}.}
It is the \^\ \ in the asci input of \textarab{^s} that causes the
problem. It seems that it is being read as an operator in an uncalled
math environment.
This is also true of \_ in, used in, say,
\textarab{_d}.\footnote{textarab{_d}.}
And maybe some of the other operators, but the . works fine, as in
\textarab{.z}.\footnote{\textarab{.z}.}
\end{document}
----------------------------------------
\documentclass{article}
\usepackage{pstricks}
\usepackage{pst-eps}
\usepackage{fontspec}
\setmainfont[Mapping=tex-text]{Junicode}
\usepackage[novoc,fdf2noalif]{arabxetex}
\newfontfamily\arabicfont[Script=Arabic,Scale=1.3,WordSpace=2]{Scheherazade}
\newcommand{\A}{\textarab}
\begin{document}
\begin{center}
\begin{pspicture}(0,0)(3,3)
\psline[linewidth=1pt](0,0)(0,3) %base
\psline[linewidth=1pt](0,0)(3,0) %2e base
\psline[linewidth=1pt](0,3)(3,3) %3e base
\psline[linewidth=1pt](3,0)(3,3) %oblique 1
\psline[linewidth=1pt](0,3)(3,0) %oblique 1
\rput(1.5,2.4){\A{mA'iT}}
\rput(1.5,3.278){\A{`^srT}}
\rput*[0,0]{-45}(0.23,1.74){\A{j_dr mA'ityn}}
\rput*[0,0]{-90}(3.125,2.1){}
\rput*[0,0]{-90}(-0.7,2.1){}
\rput(1.5,-0.275){}
\end{pspicture}
\end{center}
\end{document}
More information about the XeTeX
mailing list