From e4cff097224d74c75bfff61b6bdfe87c254ebf04 Mon Sep 17 00:00:00 2001 From: Enrico Forestieri Date: Tue, 9 Feb 2010 14:01:21 +0000 Subject: [PATCH] Fix bug #6510: URL in the footnote will cause the `CJK' environment to terminate git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@33382 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/output_latex.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/output_latex.cpp b/src/output_latex.cpp index f5d6af679f..a7af2199d6 100644 --- a/src/output_latex.cpp +++ b/src/output_latex.cpp @@ -319,6 +319,15 @@ ParagraphList::const_iterator TeXOnePar(Buffer const & buf, OutputParams runparams = runparams_in; runparams.isLastPar = nextpit == paragraphs.end(); + bool const maintext = text.isMainText(); + // we are at the beginning of an inset and CJK is already open; + // we count inheritation levels to get the inset nesting right. + if (pit == paragraphs.begin() && !maintext + && (cjk_inherited_ > 0 || open_encoding_ == CJK)) { + cjk_inherited_ += 1; + open_encoding_ = none; + } + if (runparams.verbatim) { int const dist = distance(paragraphs.begin(), pit); Font const outerfont = text.outerFont(dist); @@ -341,15 +350,6 @@ ParagraphList::const_iterator TeXOnePar(Buffer const & buf, runparams.moving_arg |= style.needprotect; - bool const maintext = text.isMainText(); - // we are at the beginning of an inset and CJK is already open; - // we count inheritation levels to get the inset nesting right. - if (pit == paragraphs.begin() && !maintext - && (cjk_inherited_ > 0 || open_encoding_ == CJK)) { - cjk_inherited_ += 1; - open_encoding_ = none; - } - // This paragraph's language Language const * const par_language = pit->getParLanguage(bparams); // The document's language -- 2.39.2