Can you list some examples (and what is to be output for those instead of
babel)?
OK, the babel stuff works now for me - had some wrong entries in my tree.
As you all wanted that I commit it, I tested the patch again and put it in:
http://www.lyx.org/trac/changeset/18216
While testing I found the following two issues:
1. Open a new document
2. Open the View -> Source window
-> Crash: failing check for complete_ in line 197 of Encoding.cpp
The reason is the new assertion Georg has introduced:
// validate() should have been called before
BOOST_ASSERT(complete_);
I guess there's a simple fix for this.
I therefore commented the assertion out in my commit to avoid this crash, but could somebody please
fix this or delete the assertion if it isn't needed.
---
1. open the file "armenian-article.lyx" from the examples
2. change the document layout from "article (armenian)" to "article" and save
the file under a new name.
3. change the document language from Armenian to Korean
-> Crash:
Assertion triggered in int __thiscall lyx::Font::latexWriteEndChanges(class std:
:basic_ostream<unsigned long,struct std::char_traits<unsigned long> > &,const cl
ass lyx::BufferParams &,const class lyx::OutputParams &,const class lyx::Font &,
const class lyx::Font &) const by failing check "c > 0" in file D:\LyXSVN\lyx-de
vel\src\Font.cpp:924
This is a very special case that most probably no user will ever do, but I
don't want to hide this
fact. The reason are the Armenian characters in the file that are not properly
handled.
---
> What you need to do is to suppress the output of that string in
> BufferParams::babelCall() for the specific languages. You could mark those
> languages by giving them an empty babel name in the languages file and check
> for that.
That's what the patch does, when the babel language is empty in lib/languages,
babel isn't called.
This works now as expected.
> Probably the prefs ui should also be changed. Additionally to the "language
> package" line edit, there should probably be a checkbox "use default language
> package", which is babel or something else for other languages. This should
> disable the line edit and default to true.
I don't think that this is useful.
For the CJK-languages, babel should not be called as you get troubles otherwise (Georg told me).
There is also no special language package as the CJK package also sets the encoding.
For e.g. Armenian it doesn't matter if you call babel or not, the language package is in this case
armTeX but it calls also the encoding (like the CJK package).
So calling CJK or armTeX is a must and the user shouldn't have a choice not to use it or using
another one as this will only generate LaTeX-errors.
thanks and regards
Uwe