diff --git a/src/output_latex.cpp b/src/output_latex.cpp index 103a8bc42a..e6deb6179a 100644 --- a/src/output_latex.cpp +++ b/src/output_latex.cpp @@ -583,7 +583,8 @@ void TeXOnePar(Buffer const & buf, os << "\\L{"; } // With CJK, the CJK tag has to be closed first (see below) - if (runparams.encoding->package() != Encoding::CJK) { + if (runparams.encoding->package() != Encoding::CJK + && !par_lang.empty()) { os << from_ascii(subst( lang_begin_command, "$$lang", @@ -644,7 +645,8 @@ void TeXOnePar(Buffer const & buf, os << "%\n"; } // With CJK, the CJK tag had to be closed first (see above) - if (runparams.encoding->package() == Encoding::CJK) { + if (runparams.encoding->package() == Encoding::CJK + && !par_lang.empty()) { os << from_ascii(subst( lang_begin_command, "$$lang",