- string tmp = (lyxrc.isp_use_alt_lang) ? lyxrc.isp_alt_lang : bv->buffer()->GetLanguage();
- bool rtl = tmp == "hebrew" || tmp == "arabic";
+#ifdef USE_PSPELL
+ string tmp = (lyxrc.isp_use_alt_lang) ?
+ lyxrc.isp_alt_lang : bv->buffer()->params.language_info->code();
+#else
+ string tmp = (lyxrc.isp_use_alt_lang) ?
+ lyxrc.isp_alt_lang : bv->buffer()->GetLanguage();
+#endif
+#warning This is not good we should find a way to identify a rtl-language in a more general way. Please have a look Dekel! (Jug)
+// For now I'll change this to a bit more general solution but
+// Please comment on this if you don't like it. We probaly need
+// anoter flag something like lyxrc.isp_use_alt_lang_rtl (true/false)!
+ bool rtl;
+ if (lyxrc.isp_use_alt_lang)
+ rtl = (tmp == "hebrew" || tmp == "arabic");
+ else
+ rtl = bv->buffer()->params.language_info->RightToLeft();