RE6: Lots of undefined control sequences when using Arabic Babel
outlook user
RACP at outlook.fr
Sun May 12 21:26:05 CEST 2024
Running that code:
```LaTeX
\documentclass{book}
\usepackage{translations}
\usepackage[english, bidi=basic]{babel}
\babelprovide[onchar=ids fonts]{arabic}
\babelfont{rm}{Crimson}
\babelfont[*arabic]{rm}{FreeSerif}
\DeclareTranslation{Arabic}{text}{ ﻓﺼﺤﻰ اﻟﻌﺼﺮ }
\begin{document}
\GetTranslation{text}
\end{document}
```
Produces that: [cid:d83d6c0b-6996-4ffb-8426-f039806b81d6]
Where it should output Arabic characters
> you have some other issue
That problem is reproducible, you can copy-paste the MWE to see it. So it's not about me having a problem
> can not read it
No need for it. I literally copied the Arabic characters from the example you sent me in my own MWE. It's only about being able to output those rather than understand them
>> you would have an error about missing fonts
> Package fontspec Warning: Font 'Crimson' is using the default features for language 'English'. That's usually fine, because many languages require no specific features, but if the output is not as expected, consider selecting another font.
> Package fontspec Warning: Font 'FreeSerif' is using the default features for language 'Arabic'. That's usually fine, because many languages require no specific features, but if the output is not as expected, consider selecting another font.
No errors otherwise. Disappears if I delete `\babelfont{rm}{Crimson}\n\babelfont[*arabic]{rm}{FreeSerif}`
But it's not about that anyway, because if it was about font problem, there won't be "text" written. The engine would try to output Arabic and would output nothing because failing to do so. Here it outputs the tag without even trying to output it in Arabic
________________________________
De : David Carlisle <d.p.carlisle at gmail.com>
Envoyé : dimanche 12 mai 2024 20:46
À : outlook user <RACP at outlook.fr>
Objet : Re: RE4: Lots of undefined control sequences when using Arabic Babel
On Sun, 12 May 2024 at 17:12, outlook user <RACP at outlook.fr<mailto:RACP at outlook.fr>> wrote:
That code creates the same case as
> `\usepackage{babel}` with or without `\babelprovide{arabic}` doesn't output any Arabic, only latin text [...]. In fact `babelprovide` doesn't change anything to the case here
Don't produce errors but no Arabic text outputed
The code posted produces
[image.png]
If you are not seeing Arabic text you have some other issue I can't help, sorry I am no expert on Arabic, and can not read it.
If you don't have the font installed you would have an error about missing fonts.
David
```LaTeX
\documentclass{book}
\usepackage{translations}
\usepackage[english, bidi=basic]{babel}
\babelprovide[onchar=ids fonts]{arabic}
\babelfont{rm}{Crimson}
\babelfont[*arabic]{rm}{FreeSerif}
\DeclareTranslation{Arabic}{text}{ ﻓﺼﺤﻰ اﻟﻌﺼﺮ }
\begin{document}
\GetTranslation{text}
\end{document}
```
________________________________________
De : David Carlisle <d.p.carlisle at gmail.com<mailto:d.p.carlisle at gmail.com>>
Envoyé : dimanche 12 mai 2024 17:57
À : outlook user <RACP at outlook.fr<mailto:RACP at outlook.fr>>
Cc : texhax at tug.org<mailto:texhax at tug.org> <texhax at tug.org<mailto:texhax at tug.org>>
Objet : Re: RE2: Lots of undefined control sequences when using Arabic Babel
I do not read arabic, but see the babel manual for some arabic examples, eg the following (which requires lualatex)
\documentclass{book}
\usepackage[english, bidi=basic]{babel}
\babelprovide[onchar=ids fonts]{arabic}
\babelfont{rm}{Crimson}
\babelfont[*arabic]{rm}{FreeSerif}
\begin{document}
Most Arabic speakers consider the two varieties to be two registers
of one language, although the two registers can be referred to in
Arabic as \ ﻓﺼﺤﻰ اﻟﻌﺼﺮ \textit{fuṣḥā l-ʻaṣr} (MSA) and
\ ﻓﺼﺤﻰ اﻟﺘﺮاث \textit{fuṣḥā t-turāth} (CA).\end{document}
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://tug.org/pipermail/texhax/attachments/20240512/3a3d6ae8/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 19565 bytes
Desc: image.png
URL: <https://tug.org/pipermail/texhax/attachments/20240512/3a3d6ae8/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: www.overleaf.com_project_64d8d3ea4e14d9b8f46185a1.png
Type: image/png
Size: 815 bytes
Desc: www.overleaf.com_project_64d8d3ea4e14d9b8f46185a1.png
URL: <https://tug.org/pipermail/texhax/attachments/20240512/3a3d6ae8/attachment-0003.png>
More information about the texhax
mailing list.