]> git.lyx.org Git - features.git/commitdiff
Rename \mathsym -> \lyxmathsym in order to avoid potential clashes.
authorEnrico Forestieri <forenr@lyx.org>
Sun, 1 Jun 2008 14:11:36 +0000 (14:11 +0000)
committerEnrico Forestieri <forenr@lyx.org>
Sun, 1 Jun 2008 14:11:36 +0000 (14:11 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25049 a592a061-630c-0410-9148-cb99ea01b6c8

src/LaTeXFeatures.cpp
src/mathed/InsetMathChar.cpp
src/mathed/InsetMathString.cpp

index 3d7b11a61f5cbb32179d9dac23da0db0fc536430..e31fc75c31ef723cb416b19a144fb08de4b2fb59 100644 (file)
@@ -199,8 +199,8 @@ static string const textcyr_def =
        "\\DeclareRobustCommand{\\textcyr}[1]{\\leavevmode{\\cyrtext #1}}\n"
        "\\DeclareFontEncoding{T2A}{}{}\n";
 
-static string const mathsym_def =
-       "\\DeclareRobustCommand{\\mathsym}[1]{%\n"
+static string const lyxmathsym_def =
+       "\\DeclareRobustCommand{\\lyxmathsym}[1]{%\n"
        " \\begingroup\n"
        " \\edef\\b@ld{bold}%\n"
        " \\def\\rmorbf##1{\\ifx\\math@version\\b@ld\\textbf{##1}\\else\\textrm{##1}\\fi}%\n"
@@ -654,8 +654,8 @@ string const LaTeXFeatures::getMacros() const
        if (mustProvide("textcyr"))
                macros << textcyr_def << '\n';
 
-       if (mustProvide("mathsym"))
-               macros << mathsym_def << '\n';
+       if (mustProvide("lyxmathsym"))
+               macros << lyxmathsym_def << '\n';
 
        // quotes.
        if (mustProvide("quotesinglbase"))
index 857dbcea905de34b4dda7745e36c64bbecb8e437..e7c590ca2c325812d0a198f1d1cb02d81fb11c55 100644 (file)
@@ -142,7 +142,7 @@ void InsetMathChar::validate(LaTeXFeatures & features) const
        if (char_ >= 0x80) {
                encodings.validate(char_, features);
                features.require("relsize");
-               features.require("mathsym");
+               features.require("lyxmathsym");
        }
 }
 
index 0599ef79dea557e74817023ae1a3b6e3b8a9872f..cf5d7e179cfe3316763fcf025a9e3da55f4db8a8 100644 (file)
@@ -115,20 +115,20 @@ void InsetMathString::write(WriteStream & os) const
        docstring::const_iterator cit = str_.begin();
        docstring::const_iterator end = str_.end();
 
-       bool in_mathsym = false;
+       bool in_lyxmathsym = false;
        while (cit != end) {
                char_type const c = *cit;
                try {
                        if (c < 0x80) {
-                               if (in_mathsym) {
+                               if (in_lyxmathsym) {
                                        os << '}';
-                                       in_mathsym = false;
+                                       in_lyxmathsym = false;
                                }
                                os << docstring(1, c);
                        } else if (can_encode) {
-                               if (!in_mathsym) {
-                                       os << "\\mathsym{";
-                                       in_mathsym = true;
+                               if (!in_lyxmathsym) {
+                                       os << "\\lyxmathsym{";
+                                       in_lyxmathsym = true;
                                }
                                os << encit->latexChar(c, true);
                        } else {
@@ -149,7 +149,7 @@ void InsetMathString::write(WriteStream & os) const
                }
                ++cit;
        }
-       if (in_mathsym)
+       if (in_lyxmathsym)
                os << '}';
 }