]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_macrotemplate.C
make \newcommand{\bb}[1]{\mathbf{#1}} work for read/write/display.
[lyx.git] / src / mathed / math_macrotemplate.C
index 0f1281f9e9488c79509bc5a9404e3ce2f5f1904e..3fe31bc7b7477df0fb072a87e6973c080ebf6d9b 100644 (file)
@@ -16,10 +16,9 @@ MathMacroTemplate::MathMacroTemplate()
 MathMacroTemplate::MathMacroTemplate(string const & nm, int numargs)
        : MathNestInset(1), numargs_(numargs), name_(nm)
 {
-       if (numargs_ > 9) {
+       if (numargs_ > 9)
                lyxerr << "MathMacroTemplate::MathMacroTemplate: wrong # of arguments: "
                        << numargs_ << std::endl;
-       }
 }
 
 
@@ -68,6 +67,6 @@ void MathMacroTemplate::write(WriteStream & os) const
 {
        os << "\n\\newcommand{\\" << name_.c_str() << '}';
        if (numargs_ > 0)
-               os << '[' << ('0' + numargs_) << ']';
+               os << '[' << numargs_ << ']';
        os << '{' << cell(0) << "}\n";
 }