}
+string const fromPolyglossiaEnvironment(string const s)
+{
+ // Since \arabic is taken by the LaTeX kernel,
+ // the Arabic polyglossia environment is upcased
+ if (s == "Arabic")
+ return "arabic";
+ else
+ return s;
+}
+
+
} // namespace
}
}
- else if (is_known(name, preamble.polyglossia_languages)) {
+ // We need to use fromPolyglossiaEnvironment die to Arabic > arabic
+ else if (is_known(fromPolyglossiaEnvironment(name), preamble.polyglossia_languages)) {
// We must begin a new paragraph if not already done
if (! parent_context.atParagraphStart()) {
parent_context.check_end_layout(os);
}
// save the language in the context so that it is
// handled by parse_text
- parent_context.font.language = preamble.polyglossia2lyx(name);
+ parent_context.font.language =
+ preamble.polyglossia2lyx(fromPolyglossiaEnvironment(name));
parse_text(p, os, FLAG_END, outer, parent_context);
// Just in case the environment is empty
parent_context.extra_stuff.erase();
continue;
}
-
// Starred section headings
// Must attempt to parse "Section*" before "Section".
if ((p.next_token().asInput() == "*") &&
* TEX2LYX
-- Consider required modules when checking for layout definitions in modules
- (bug 11156).
+- Consider required modules when checking for layout definitions in modules
+ (bug 11156).
+- Fix import of Arabic polyglossia environment (part of bug 10111).
* ADVANCED FIND AND REPLACE