]> git.lyx.org Git - lyx.git/blob - src/lyx_gui.h
ParagraphParameters and SharedContainer
[lyx.git] / src / lyx_gui.h
1 // -*- C++ -*-
2 /* This file is part of
3  * ======================================================
4  * 
5  *           LyX, The Document Processor
6  *       
7  *           Copyright 1995 Matthias Ettrich
8  *           Copyright 1995-2000 The LyX Team.
9  *
10  * ====================================================== */
11
12 #ifndef LYX_GUI_H
13 #define LYX_GUI_H
14
15 #include <boost/utility.hpp>
16
17 #ifdef __GNUG__
18 #pragma interface
19 #endif
20
21 class LyXView;
22 class LyX;
23 class Buffer;
24
25 /**
26    This class is going to be the entry point to {\em all} GUI funcionality.
27    From this object will all the things going on be initiated. However I
28    have not clearly figured out how this class is going to be, suggestions
29    are welcome. (Lgb)
30 */
31 class LyXGUI : public noncopyable {
32 public:
33         /** The only constructor allowed.
34             If gui is false, LyX will operate in non-X mode
35         */
36         LyXGUI(LyX * owner, int * argc, char * argv[], bool gui);
37         ///
38         ~LyXGUI();
39         
40         /**
41            This functions starts the ball. For XForms it runs a loop of
42            fl_check_forms(). For QT this will probably be .exec().
43         */
44         void runTime();
45         /** This will take care of the initializaton done after the
46             main initialization.
47         */
48         void init();
49         
50         /// Register the buffer with the first found LyXView in lyxViews
51         void regBuf(Buffer *);
52         
53         /// Access to (first?) LyXView
54         LyXView * getLyXView() const;
55         
56 private:
57         ///
58         void setDefaults();
59         ///
60         void create_forms();
61         
62         /// The LyX that owns this GUI.
63         LyX * _owner;
64         ///
65         LyXView * lyxViews; // or something so that several views
66         // on the same time can be allowed.
67         /// Do we have a gui?
68         bool gui;
69 };
70
71 #endif