]> git.lyx.org Git - lyx.git/blob - src/BufferView_pimpl.h
more changes, read the Changelog
[lyx.git] / src / BufferView_pimpl.h
1 // -*- C++ -*-
2
3 #ifndef BUFFERVIEW_PIMPL_H
4 #define BUFFERVIEW_PIMPL_H
5
6 #include "BufferView.h"
7 #include "UpdateInset.h"
8 #include "BackStack.h"
9 #include "Timeout.h"
10
11 #ifdef __GNUG__
12 #pragma interface
13 #endif
14
15 class LyXView;
16 class WorkArea;
17 class LyXScreen;
18
19 struct BufferView::Pimpl : public SigC::Object {
20         Pimpl(BufferView * i, LyXView * o,
21               int xpos, int ypos, int width, int height);
22         ///
23         Painter & painter();
24         ///
25         void buffer(Buffer *);
26         ///
27         void resize(int xpos, int ypos, int width, int height);
28         ///
29         void resize();
30         ///
31         void redraw();
32         /// Return true if the cursor was fitted.
33         bool fitCursor();
34         ///
35         void redoCurrentBuffer();
36         ///
37         int resizeCurrentBuffer();
38         ///
39         void update();
40         ///
41         void update(BufferView::UpdateCodes);
42         ///
43         void gotoError();
44         /// Update pixmap of screen
45         void updateScreen();
46         ///
47         void workAreaExpose();
48         ///
49         void updateScrollbar();
50         ///
51         void scrollCB(double value);
52         ///
53         Inset * checkInsetHit(LyXText *, int & x, int & y, unsigned int button);
54         /// 
55         int scrollUp(long time);
56         ///
57         int scrollDown(long time);
58         ///
59         void workAreaMotionNotify(int x, int y, unsigned int state);
60         ///
61         void workAreaButtonPress(int x, int y, unsigned int button);
62         ///
63         void workAreaButtonRelease(int x, int y, unsigned int button);
64         ///
65         void doubleClick(int x, int y, unsigned int button);
66         ///
67         void tripleClick(int x, int y, unsigned int button);
68         ///
69         void enterView();
70         ///
71         void leaveView();
72         ///
73         void cursorToggle();
74         ///
75         void cursorPrevious();
76         ///
77         void cursorNext();
78         ///
79         bool available() const;
80         ///
81         void beforeChange();
82         ///
83         void savePosition();
84         ///
85         void restorePosition();
86         ///
87         bool NoSavedPositions();
88         ///
89         void setState();
90         ///
91         void insetSleep();
92         ///
93         void insetWakeup();
94         ///
95         void insetUnlock();
96         ///
97         bool focus() const;
98         ///
99         void focus(bool);
100         ///
101         bool active() const;
102         ///
103         bool belowMouse() const;
104         ///
105         void showCursor();
106         ///
107         void hideCursor();
108         ///
109         void toggleSelection(bool = true);
110         ///
111         void toggleToggle();
112         ///
113         void center();
114         ///
115         BufferView * bv_;
116         ///
117         LyXView * owner_;
118         ///
119         Buffer * buffer_;
120         ///
121         LyXScreen * screen_;
122         ///
123         long current_scrollbar_value;
124         ///
125         FL_OBJECT * figinset_canvas;
126         ///
127         Timeout cursor_timeout;
128         ///
129         BackStack backstack;
130         ///
131         int last_click_x, last_click_y;
132         ///
133         WorkArea * workarea_;
134         ///
135         UpdateInset updatelist;
136         ///
137         void pasteClipboard(bool asPara);
138         ///
139         void stuffClipboard(string const &) const;
140 private:
141         bool using_xterm_cursor;
142 };
143 #endif