From: Scott Kostyshak Date: Thu, 2 Oct 2014 05:29:00 +0000 (-0400) Subject: Remove line in text export of inline math (#9282) X-Git-Tag: 2.2.0alpha1~1643 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=3b96c6e901904cb7d5e1c13e76b84541d090075a;p=features.git Remove line in text export of inline math (#9282) If there is only one row, a new line should not be appended. If there is more than one row, the new line should not be appended for the last row. For example, if in LyX there was "as you can see in $x$ there..." a copy/paste would lead to a newline after "x". --- diff --git a/src/mathed/InsetMathHull.cpp b/src/mathed/InsetMathHull.cpp index 386c373a85..4b9e0ce66f 100644 --- a/src/mathed/InsetMathHull.cpp +++ b/src/mathed/InsetMathHull.cpp @@ -1970,7 +1970,8 @@ int InsetMathHull::plaintext(odocstringstream & os, // and do not include the newline. if (op.for_toc || op.for_tooltip || oss.str().size() >= max_length) break; - wi << "\n"; + if (r < nrows() - 1) + wi << "\n"; } } docstring const str = oss.str();