]> git.lyx.org Git - lyx.git/blobdiff - src/ToolbarDefaults.C
Fix working of the spellchecker dialog with ispell when there are no
[lyx.git] / src / ToolbarDefaults.C
index 390dabb43cbf66ead2fbed8fbc7f0e30b7c16f2f..83a45ce48c41b7dd9a5ed6d05ef296ed070c3dd8 100644 (file)
@@ -20,6 +20,7 @@
 #include "lyxlex.h"
 #include "debug.h"
 #include "lyxlex.h"
+#include "support/lstrings.h"
 
 using std::endl;
 
@@ -64,9 +65,6 @@ void ToolbarDefaults::init()
        add(LFUN_DEPTH);
        add(SEPARATOR);
 
-#ifndef NO_LATEX
-       add(LFUN_TEX);
-#endif
         add(LFUN_MATH_MODE);
        add(SEPARATOR);
 
@@ -97,13 +95,13 @@ struct keyword_item toolTags[TO_LAST - 1] = {
 void ToolbarDefaults::read(LyXLex & lex) 
 {
        //consistency check
-       if (compare_no_case(lex.GetString(), "toolbar"))
+       if (compare_no_case(lex.getString(), "toolbar")) {
                lyxerr << "Toolbar::read: ERROR wrong token:`"
-                      << lex.GetString() << '\'' << endl;
+                      << lex.getString() << '\'' << endl;
+       }
 
        defaults.clear();
        
-       string func;
        bool quit = false;
        
        lex.pushTable(toolTags, TO_LAST - 1);
@@ -111,11 +109,11 @@ void ToolbarDefaults::read(LyXLex & lex)
        if (lyxerr.debugging(Debug::PARSER))
                lex.printTable(lyxerr);
 
-       while (lex.IsOK() && !quit) {
+       while (lex.isOK() && !quit) {
                switch (lex.lex()) {
                case TO_ADD:
                        if (lex.next(true)) {
-                               func = lex.GetString();
+                               string const func = lex.getString();
                                lyxerr[Debug::PARSER]
                                        << "Toolbar::read TO_ADD func: `"
                                        << func << "'" << endl;