]> git.lyx.org Git - lyx.git/blobdiff - src/Buffer.h
Kornel's gcc compile fix.
[lyx.git] / src / Buffer.h
index 012f73bf67e97b9c174ce373d2cd27728a143a92..af69950eb1a74443136eac2624d64a353c617ef7 100644 (file)
@@ -155,10 +155,6 @@ public:
        */
        bool readDocument(Lexer &);
 
-       ///
-       void insertStringAsLines(ParagraphList & plist,
-               pit_type &, pos_type &,
-               Font const &, docstring const &, bool);
        ///
        DocIterator getParFromID(int id) const;
        /// do we have a paragraph with this id?
@@ -175,6 +171,9 @@ public:
 
        /// Write document to stream. Returns \c false if unsuccesful.
        bool write(std::ostream &) const;
+       /// save emergency file
+       /// \return a status message towards the user.
+       docstring emergencyWrite();
        /// Write file. Returns \c false if unsuccesful.
        bool writeFile(support::FileName const &) const;
 
@@ -263,9 +262,16 @@ public:
        ///
        void setUnnamed(bool flag = true);
 
-       ///
+       /// Whether or not a filename has been assigned to this buffer
        bool isUnnamed() const;
 
+       /// Whether or not this buffer is internal.
+       ///
+       /// An internal buffer does not contain a real document, but some auxiliary text segment.
+       /// It is not associated with a filename, it is never saved, thus it does not need to be
+       /// automatically saved, nor it needs to trigger any "do you want to save ?" question.
+       bool isInternal() const;
+
        /// Mark this buffer as dirty.
        void markDirty();
 
@@ -509,8 +515,6 @@ public:
 
        /// return a list of all used branches (also in children)
        void getUsedBranches(std::list<docstring> &, bool const from_master = false) const;
-       /// rename all branches of \p oldname in the buffer to \p newname.
-       void renameBranches(docstring const & oldname, docstring const & newname);
 
        /// sets the buffer_ member for every inset in this buffer.
        // FIXME This really shouldn't be needed, but at the moment it's not
@@ -553,6 +557,11 @@ private:
        ReadStatus readFile(Lexer &, support::FileName const & filename,
                            bool fromString = false);
 
+       /** If we have branches that use the file suffix
+           feature, return the file name with suffix appended.
+       */
+       support::FileName exportFileName() const;
+
        /// Use the Pimpl idiom to hide the internals.
        class Impl;
        /// The pointer never changes although *pimpl_'s contents may.