> In fact, I think it makes CJK-LyX in a multilingual context (mixing of CJK and
> non-CJK languages) usable for the first time.
It does, and therefore should go into Lyx 1.5.3.
> However, it became much more complex than I wanted it to be, and it is not
> finished yet (it works perfectly for me when I use LyX's default settings; it
> fails due to unproper nesting if I set an end-language-tag in preferences,
> such as \begin{otherlanguage}{$lang$} ... \end{otherlanguage}). Fixing this
> last issue would make the whole thing even more complex, ...
I vote to open a new bug report for this issue. The problem you describe is very special and so far
I know not used by anybody (assuming that Arabic users don't use CJK). This bug has been before so
your patch doesn't introduce it.
> Before I dive in further and spend more time on it, I want to hear your
> opinions about the whole thing.
I spent yesterday more then two hours of testing and playing around, see my comments in bug 4337.
For me the patch is stable. That there are still a special issue that has been before shouldn't
prevent to apply it to LyX 1.5.3. It fixes 2 crashes and makes the CJK support now really usable.
Note that we promised and announced this for LyX 1.5.0 thus it's time to keep our promise.
regards Uwe