From ed79aee921d09e1cbaf9a2d369d78739d4a63185 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Andr=C3=A9=20P=C3=B6nitz?= Date: Tue, 2 Apr 2002 07:33:38 +0000 Subject: [PATCH] don't assert() on missing macro arguments git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@3878 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/mathed/math_cursor.C | 5 +++++ src/mathed/math_macrotable.C | 1 + src/mathed/math_parser.C | 4 ++-- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/mathed/math_cursor.C b/src/mathed/math_cursor.C index 3a17efa565..4280c68ebe 100644 --- a/src/mathed/math_cursor.C +++ b/src/mathed/math_cursor.C @@ -1465,6 +1465,11 @@ bool MathCursor::interpret(char c) macroModeClose(); + if (c == '{' || c == '}') { + insert(MathAtom(new MathSpecialCharInset(c))); + return true; + } + if (c != ' ') interpret(c); diff --git a/src/mathed/math_macrotable.C b/src/mathed/math_macrotable.C index d6436c9d51..d2cd7d6f67 100644 --- a/src/mathed/math_macrotable.C +++ b/src/mathed/math_macrotable.C @@ -89,6 +89,7 @@ void MathMacroTable::builtinMacros() //define("\\def\\emptyset{\\not0}"); define("\\def\\notin{\\not\\in}"); define("\\def\\slash{/}"); + //define("\\def\\mathcircumflex{\\^}"); // fontmath.ltx diff --git a/src/mathed/math_parser.C b/src/mathed/math_parser.C index 70e827a319..64cb40acdc 100644 --- a/src/mathed/math_parser.C +++ b/src/mathed/math_parser.C @@ -1031,8 +1031,8 @@ void Parser::parse_into1(MathArray & array, unsigned flags, MathTextCodes code) dump(); lyxerr << "found '}' unexpectedly, array: '" << array << "'\n"; //lyxerr << "found '}' unexpectedly\n"; - lyx::Assert(0); - add(array, '}', LM_TC_TEX); + //lyx::Assert(0); + //add(array, '}', LM_TC_TEX); } else if (t.cat() == catAlign) { -- 2.39.2