From 7e624928ef17e7986a8de9b06a186830b0407a0e Mon Sep 17 00:00:00 2001 From: Vincent van Ravesteijn Date: Sat, 1 Aug 2009 21:54:13 +0000 Subject: [PATCH] Add a pending space after math if it is not the last of the selection. This fixes problems like in bug #6094. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30821 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/Paragraph.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/Paragraph.cpp b/src/Paragraph.cpp index 8e512ceea9..1b8924a1e9 100644 --- a/src/Paragraph.cpp +++ b/src/Paragraph.cpp @@ -2554,8 +2554,11 @@ docstring Paragraph::asString(pos_type beg, pos_type end, int options) const if (isPrintable(c) || c == '\t' || (c == '\n' && options & AS_STR_NEWLINES)) os.put(c); - else if (c == META_INSET && options & AS_STR_INSETS) + else if (c == META_INSET && options & AS_STR_INSETS) { getInset(i)->tocString(os); + if (getInset(i)->asInsetMath()) + os << " "; + } } return os.str();