]> git.lyx.org Git - lyx.git/blobdiff - src/BufferView.h
SCons: msvc does not need this /TP option any more after we rename .C => .cpp. Also...
[lyx.git] / src / BufferView.h
index 7da1a08d94d54f4474118520b60d25b4b342bba5..21d49f91e95f93bd34d3af613ef2f6479baed40f 100644 (file)
@@ -79,22 +79,14 @@ struct ScrollbarParameters
  */
 class BufferView : boost::noncopyable {
 public:
-       BufferView();
+       ///
+       BufferView(Buffer & buffer);
 
        ~BufferView();
 
-       /// set the buffer we are viewing.
-       /// \todo FIXME: eventually, we will create a new BufferView
-       /// when switching Buffers, so this method should go.
-       void setBuffer(Buffer * b);
        /// return the buffer being viewed.
-       Buffer * buffer() const;
-
-       /// resize the BufferView.
-       void resize();
-
-       /// load a buffer into the view.
-       bool loadLyXFile(support::FileName const & name, bool tolastfiles = true);
+       Buffer & buffer();
+       Buffer const & buffer() const;
 
        /// perform pending metrics updates.
        /** \c Update::FitCursor means first to do a FitCursor, and to
@@ -146,8 +138,8 @@ public:
        /// return the pixel height of the document view.
        int workHeight() const;
 
-       /// switch between primary and secondary keymaps for RTL entry.
-       void switchKeyMap();
+       /// translate and insert a character, using the correct keymap.
+       void translateAndInsert(char_type c, Text * t, Cursor & cur);
 
        /// return true for events that will handle.
        FuncStatus getStatus(FuncRequest const & cmd);
@@ -245,7 +237,7 @@ public:
                std::string data)> updateDialog;
 
        /// This signal is emitted when the layout at the cursor is changed.
-       boost::signal<void(std::string layout)> layoutChanged;
+       boost::signal<void(docstring layout)> layoutChanged;
 
 private:
        ///
@@ -271,7 +263,7 @@ private:
        ///
        CoordCache coord_cache_;
        ///
-       Buffer * buffer_;
+       Buffer & buffer_;
 
        /// Estimated average par height for scrollbar.
        int wh_;