]> git.lyx.org Git - features.git/blobdiff - src/LaTeXFeatures.h
Georg\'s last patch for bug 605
[features.git] / src / LaTeXFeatures.h
index c179896daaa94f584d73a7e25d1aeb3c63230cdf..a21d7f65ba3f427925d3d6baf8ae210e551aa728 100644 (file)
@@ -39,7 +39,7 @@ struct Language;
 class LaTeXFeatures {
 public:
        ///
-       LaTeXFeatures(Buffer const &, BufferParams const &);
+       LaTeXFeatures(Buffer const &, BufferParams const &, bool);
        /// The packages needed by the document
        std::string const getPackages() const;
        /// The macros definitions needed by the document
@@ -79,9 +79,13 @@ public:
        ///
        Buffer const & buffer() const;
        ///
+       void setBuffer(Buffer const &);
+       ///
        BufferParams const & bufferParams() const;
        /// the return value is dependent upon both LyXRC and LaTeXFeatures.
        bool useBabel() const;
+       ///
+       bool nice() const { return nice_; };
 
 private:
        std::list<std::string> usedLayouts_;
@@ -104,10 +108,18 @@ private:
        typedef std::map<std::string , std::string> FileMap;
        ///
        FileMap IncludedFiles_;
-       ///
-       Buffer const & buffer_;
+       /** Buffer of the file being processed.
+        *  This may be a child buffer of the to-be-exported file and
+        *  therefore may not be the buffer that belongs to params_.
+        *  Only needed by InsetInclude::validate().
+        */
+       Buffer const * buffer_;
        ///
        BufferParams const & params_;
+       /** If we are writing a nice LaTeX file or not.
+        *  Only needed by InsetInclude::validate().
+        */
+       bool nice_;
 };
 
 #endif