]> git.lyx.org Git - lyx.git/blobdiff - src/tex2lyx/Parser.h
Remove wmf2eps as EMF > EPS converter
[lyx.git] / src / tex2lyx / Parser.h
index ca0a917f43ee967f81809a58fdea2386d3190029..cbdfcf723470a88a2cc2825db046172487b405c5 100644 (file)
@@ -126,7 +126,8 @@ public:
        iparserdocstream(idocstream & is) : is_(is) {}
 
        /// Like std::istream::operator bool()
-       operator bool() const { return s_.empty() ? is_ : true; }
+       /// Do not convert is_ implicitly to bool, since that is forbidden in C++11.
+       explicit operator bool() const { return s_.empty() ? !is_.fail() : true; }
 
        /// change the encoding of the input stream to \p e (iconv name)
        void setEncoding(std::string const & e);
@@ -172,7 +173,7 @@ class Parser {
        Parser & operator=(Parser const & p);
 public:
        ///
-       Parser(idocstream & is);
+       Parser(idocstream & is, std::string const & fixedenc);
        ///
        Parser(std::string const & s);
        ///
@@ -285,7 +286,7 @@ public:
         * found and the member \p second is the value. If \p
         * allow_linebreak is false, then the parsing is limited to one line
         */
-       Arg verbatimStuff(std::string const & end_string, 
+       Arg verbatimStuff(std::string const & end_string,
                          bool allow_linebreak = true);
        /*
         * \returns the contents of the environment \p name.
@@ -351,10 +352,12 @@ private:
        std::string encoding_iconv_;
        ///
        CatCode theCatcode_[256];
-       //
+       ///
        cat_type theCatcodesType_;
-       //
+       ///
        cat_type curr_cat_;
+       ///
+       bool fixed_enc_;
 };