]> git.lyx.org Git - lyx.git/blob - src/frontends/WorkArea.h
Make BufferView::singeParUpdate more robust
[lyx.git] / src / frontends / WorkArea.h
1 // -*- C++ -*-
2 /**
3  * \file WorkArea.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author unknown
8  * \author John Levon
9  * \author Abdelrazak Younes
10  *
11  * Full author contact details are available in file CREDITS.
12  */
13
14 #ifndef BASE_WORKAREA_H
15 #define BASE_WORKAREA_H
16
17 #include "frontends/KeyModifier.h"
18
19 namespace lyx {
20
21 class BufferView;
22
23 namespace frontend {
24
25 /**
26  * The work area class represents the widget that provides the view
27  * onto a document. It owns the BufferView, and is responsible for
28  * handing events back to its BufferView.
29  */
30 class WorkArea
31 {
32 public:
33         ///
34         virtual ~WorkArea() {}
35
36         /// Update metrics if needed and schedule a paint event
37         virtual void scheduleRedraw(bool update_metrics) = 0;
38
39         /// close this work area.
40         /// Slot for Buffer::closing signal.
41         virtual void close() = 0;
42
43         /// Update window titles of all users.
44         virtual void updateWindowTitle() = 0;
45
46         ///
47         virtual BufferView & bufferView() = 0;
48         ///
49         virtual BufferView const & bufferView() const = 0;
50 };
51
52 } // namespace frontend
53 } // namespace lyx
54
55 #endif // BASE_WORKAREA_H