First, sorry for the delay. This mail never reached me, I found it by chance in 
the mail-archive.

> All of the problems you're describing are because you haven't performed the 
one-time setup
> required for Arabtex, see 
http://permalink.gmane.org/gmane.editors.lyx.devel/88100 for details.
> Note that most or all of the things I'm saying that you should add to the 
preferences file could
> also be added from within the preferences in the GUI.

>> First, I cannot process your file because the command \R is not known. It 
therefore only works
>> when I add \usepackage{arabtex} to the preamble.
>
> add the following line to your preferences file:
> \language_package "\usepackage{arabtex,cp1256} \setcode{cp1256}"

OK, yes this works. I tried this once as it is described in the arabTeX-doku. But I always got errors about the unknown package "cp1256". Works now, I don't knwo why it didn't the last time.

> The patch is not working for me. I think it's because the document language 
is not (and shouldn't
> be) arabtex --- it should be English, as in the example file I provided; in 
which case the patch
> won't kick in.

But you above said I should add

\usepackage{arabtex,cp1256} \setcode{cp1256}

to the preamble, so why does it not work. The resulting TeX-file is exactly the same because the preferences entry does nothing different. But now I see that it only works when the document language is English, so my patch therefore fails.
So why do we have the language "arabic (ArabTeX)" in LyX's menu when it can 
never be used?

> Secondly, I agree with JMarc about the hardcoding of language info --- I'm 
not sure that it really
> belongs in the source code. I don't think it's so terrible to require a 
little setup from the
> user, and if it is --- the installer could do this one-time setup.

I don't agree. We should take care of such fundamental settings. That's why we created the new language arabic_arabtex. Fiddling around wit preferences is not user friendly and will cause problems when the users wants to typeset other languages.

> Right, that's why you need to add the following two lines to the preferences 
file, so that you
> *don't* use babel's \selectlanguage:
>
> \language_command_begin "\begin{arabtext}"
> \language_command_end "\end{arabtext}"

Fine. But with this setting I can no longer compile my English-German mix documents. So this setting makes LyX only usable for arabTeX and unusable for all other languages! The correct way of fixing this is like Georg did this for the CJK-package that also uses special commands to begin/end languages.

> Uwe, before trying to patch the code, please try to perform the setup I 
described for ArabTeX

I did this know and get now the same correct output as you. I won't send further patches concerning arabtex.

I also see now the problem of the missing dummy babel language in the languages file. The fix would be the same as for the CJK-package. But to make it work for now I committed this missing part of our last change. (Because letting the user change the languages file is not acceptable for a stable release.):
http://www.lyx.org/trac/changeset/18957

regards Uwe

Reply via email to