commit 6a3ced3cfb14c851053ddada9abaa9c3cd4f659d
Author: Enrico Forestieri <[email protected]>
Date: Sun Sep 25 02:00:55 2016 +0200
Do not confuse global commands with ERT macros
---
src/Cursor.cpp | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/src/Cursor.cpp b/src/Cursor.cpp
index bdd6986..2658d45 100644
--- a/src/Cursor.cpp
+++ b/src/Cursor.cpp
@@ -1479,7 +1479,8 @@ bool Cursor::macroModeClose()
bool keep_mathmode = it != words.end() && (it->second.inset == "font"
|| it->second.inset == "oldfont"
|| it->second.inset == "mbox");
- bool ert_macro = !user_macro && it == words.end();
+ bool ert_macro = !user_macro && it == words.end()
+ && !atom.nucleus()->asInsetMath();
if (in && in->currentMode() == Inset::TEXT_MODE
&& atom.nucleus()->currentMode() == Inset::MATH_MODE