From 8d5da386c4880b8bd7791480e0fdbcf4218ec45e Mon Sep 17 00:00:00 2001 From: Juergen Spitzmueller Date: Wed, 3 Feb 2021 10:23:17 +0100 Subject: [PATCH] Amend [b6c089afa4/lyxgit]. --- src/Text.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/Text.cpp b/src/Text.cpp index 98d19dfb02..f596f0d2e4 100644 --- a/src/Text.cpp +++ b/src/Text.cpp @@ -895,12 +895,12 @@ void Text::insertStringAsLines(Cursor & cur, docstring const & str, ++pos; space_inserted = true; } - } else if (specialchars.find(ch) != specialchars.end()) { - if (par.insertInset(pos, new InsetSpecialChar(specialchars.find(ch)->second), - font, bparams.track_changes ? - Change(Change::INSERTED) - : Change(Change::UNCHANGED))) - ++pos; + } else if (specialchars.find(ch) != specialchars.end() + && (par.insertInset(pos, new InsetSpecialChar(specialchars.find(ch)->second), + font, bparams.track_changes + ? Change(Change::INSERTED) + : Change(Change::UNCHANGED)))) { + ++pos; space_inserted = false; } else if (!isPrintable(ch)) { // Ignore (other) unprintables