]> git.lyx.org Git - lyx.git/blobdiff - src/LyXFunc.h
Embedding: saving inzip name to .lyx file so that embedded files can always be found...
[lyx.git] / src / LyXFunc.h
index 35f29388b6dd3afd64b27aa9243f689f9cf819d7..3a0dd617dbc0f8ae776140e40dba1975b190a669 100644 (file)
@@ -17,7 +17,7 @@
 
 #include "KeySequence.h"
 #include "lfuns.h"
-#include "TextClass.h"
+#include "TextClassPtr.h"
 
 #include "support/docstring.h"
 
@@ -30,6 +30,10 @@ class FuncStatus;
 class KeySymbol;
 class Text;
 
+namespace support {
+class FileName;
+}
+
 namespace frontend {
 class LyXView;
 }
@@ -83,6 +87,19 @@ public:
        ///             not the current buffer
        void gotoBookmark(unsigned int idx, bool openFile, bool switchToBuffer);
 
+       /// load a buffer into the current workarea.
+       Buffer * loadAndViewFile(support::FileName const &  name, ///< File to load.
+               bool tolastfiles = true);  ///< append to the "Open recent" menu?
+
+       /// cursor x position before dispatch started
+       int cursorBeforeDispatchX() const {
+               return cursorPosBeforeDispatchX_;
+       }
+       /// cursor y position before dispatch started
+       int cursorBeforeDispatchY() const {
+               return cursorPosBeforeDispatchY_;
+       }
+
 private:
        ///
        BufferView * view() const;
@@ -100,6 +117,10 @@ private:
        ///
        KeyModifier meta_fake_bit;
 
+       /// cursor position before dispatch started
+       int cursorPosBeforeDispatchX_;
+       int cursorPosBeforeDispatchY_;
+
        /// Error status, only Dispatch can change this flag
        mutable bool errorstat;
 
@@ -112,9 +133,6 @@ private:
        void sendDispatchMessage(docstring const & msg,
                FuncRequest const & ev);
 
-       // I think the following should be moved to BufferView. (Asger)
-       ///
-       void menuNew(std::string const & argument, bool fromTemplate);
        ///
        void open(std::string const &);
        ///