]> git.lyx.org Git - lyx.git/blobdiff - src/lyxlex_pimpl.h
"Inter-word Space"
[lyx.git] / src / lyxlex_pimpl.h
index 0acc50974d2b92d6a82a4fd7fa3fd690bf269651..dd18a1262f70cce19d2ec75f66307fcd80dad229 100644 (file)
@@ -3,27 +3,20 @@
 #ifndef LYXLEX_PIMPL_H
 #define LYXLEX_PIMPL_H
 
-#include <fstream>
-#include <stack>
-
 #include "lyxlex.h"
 
-#ifdef __GNUG__
-#pragma interface
-#endif
+#include <boost/utility.hpp>
+
+#include <fstream>
+#include <stack>
+#include <vector>
 
 ///
-struct LyXLex::Pimpl : public noncopyable {
-       ///
-       enum {
-               ///
-               LEX_MAX_BUFF = 2048
-       };
-       
+struct LyXLex::Pimpl : boost::noncopyable {
        ///
        Pimpl(keyword_item * tab, int num);
        ///
-       string const GetString() const;
+       string const getString() const;
        ///
        void printError(string const & message) const;
        ///
@@ -37,13 +30,15 @@ struct LyXLex::Pimpl : public noncopyable {
        ///
        void setStream(std::istream & i);
        ///
+       void setCommentChar(char c);
+       ///
        bool next(bool esc = false);
        ///
        int search_kw(char const * const tag) const;
        ///
        int lex();
        ///
-       bool EatLine();
+       bool eatLine();
        ///
        bool nextToken();
        ///
@@ -52,20 +47,22 @@ struct LyXLex::Pimpl : public noncopyable {
        std::filebuf fb__;
        /// the stream that we use.
        std::istream is;
-       /// 
+       ///
        string name;
        ///
        keyword_item * table;
        ///
        int no_items;
        ///
-       char buff[LEX_MAX_BUFF];
+       std::vector<char> buff;
        ///
-       short status;
+       int status;
        ///
        int lineno;
        ///
        string pushTok;
+       ///
+       char commentChar;
 private:
        ///
        void verifyTable();