]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathMacroTemplate.cpp
Make undo action no-ops when the buffer is read-only
[lyx.git] / src / mathed / InsetMathMacroTemplate.cpp
index 7b24784ae965378a1360dc8162ee0881faaf8a7e..949f161bf90c54b34d06b221dcbb18f2d25c9357 100644 (file)
@@ -678,7 +678,7 @@ int InsetMathMacroTemplate::maxArgumentInDefinition() const
                if (it.nextInset()->lyxCode() != MATH_MACROARG_CODE)
                        continue;
                InsetMathMacroArgument * arg = static_cast<InsetMathMacroArgument*>(it.nextInset());
-               maxArg = std::max(int(arg->number()), maxArg);
+               maxArg = std::max(arg->number(), maxArg);
        }
        return maxArg;
 }
@@ -1170,20 +1170,20 @@ void InsetMathMacroTemplate::write(ostream & os) const
 {
        odocstringstream oss;
        otexrowstream ots(oss);
-       WriteStream wi(ots, false, false, WriteStream::wsDefault);
+       TeXMathStream wi(ots, false, false, TeXMathStream::wsDefault);
        oss << "FormulaMacro\n";
        write(wi);
        os << to_utf8(oss.str());
 }
 
 
-void InsetMathMacroTemplate::write(WriteStream & os) const
+void InsetMathMacroTemplate::write(TeXMathStream & os) const
 {
        write(os, false);
 }
 
 
-int InsetMathMacroTemplate::write(WriteStream & os, bool overwriteRedefinition) const
+int InsetMathMacroTemplate::write(TeXMathStream & os, bool overwriteRedefinition) const
 {
        int num_lines = 0;