fix-arabic-preamble-for-luatex

This commit is contained in:
Udi Fogiel 2023-08-01 04:42:22 +03:00 committed by Juergen Spitzmueller
parent a03c442a62
commit a2ad210926

View File

@ -251,24 +251,26 @@ Language arabic_arabi
DateFormats "d MMMM، yyyy|dd/MM/yyyy|d/M/yyyy" DateFormats "d MMMM، yyyy|dd/MM/yyyy|d/M/yyyy"
RTL true RTL true
PostBabelPreamble PostBabelPreamble
% arabic + hyperref redefines \noboundary as local textcommand \@ifundefined{if@rl}{}{
\let\orig@noboundary\noboundary % arabic + hyperref redefines \noboundary as local textcommand
\DeclareTextCommandDefault{\noboundary}{\orig@noboundary} \let\orig@noboundary\noboundary
% work around too simple test for article-like classes in arabicore.sty \DeclareTextCommandDefault{\noboundary}{\orig@noboundary}
\ifdefined\chapter\else % work around too simple test for article-like classes in arabicore.sty
\def\thesection{\protect\if@rl\protect\I{\number\c@section}% \@ifundefined{chapter}{
\protect\else\protect\textLR{\number\c@section}% \def\thesection{\protect\if@rl\protect\I{\number\c@section}%
\protect\fi} \protect\else\protect\textLR{\number\c@section}%
\def\thesubsection{\protect\if@rl\protect\I{\number\c@subsection.\number\c@section}% \protect\fi}
\protect\else\protect\textLR{\number\c@section.\number\c@subsection}% \def\thesubsection{\protect\if@rl\protect\I{\number\c@subsection.\number\c@section}%
\protect\fi}% \protect\else\protect\textLR{\number\c@section.\number\c@subsection}%
\def\thetable{\protect\if@rl\protect\I{\number\c@table}% \protect\fi}
\protect\else\protect\textLR{\number\c@table}% \def\thetable{\protect\if@rl\protect\I{\number\c@table}%
\protect\fi}% \protect\else\protect\textLR{\number\c@table}%
\def\thefigure{\protect\if@rl\protect\I{\number\c@figure}% \protect\fi}
\protect\else\protect\textLR{\number\c@figure}% \def\thefigure{\protect\if@rl\protect\I{\number\c@figure}%
\protect\fi}% \protect\else\protect\textLR{\number\c@figure}%
\fi \protect\fi}
}{}
}
EndPostBabelPreamble EndPostBabelPreamble
LangCode ar_SA LangCode ar_SA
End End