4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Lars Gullik Bjornes
9 * \author Abdelrazak Younes
11 * Full author contact details are available in file CREDITS.
17 // Must be here because of moc.
20 #include "frontends/LyXView.h"
21 #include "funcrequest.h"
23 #include <QMainWindow>
26 #include <QCloseEvent>
39 QWidget* mainWindow();
42 * GuiView - Qt4 implementation of LyXView
44 * qt4-private implementation of the main LyX window.
46 class GuiView : public QMainWindow, public LyXView {
49 /// create a main window of the given dimensions
54 /// initialize the object
57 /// show - display the top-level window
61 virtual void busy(bool) const;
63 Toolbars::ToolbarPtr makeToolbar(ToolbarBackend::Toolbar const & tbb);
65 /// display a status message
66 virtual void message(lyx::docstring const & str);
68 /// clear status message
69 virtual void clearMessage();
71 /// update the status bar
72 virtual void updateStatusBar();
74 /// add the command buffer
75 void addCommandBuffer(QToolBar * toolbar);
77 /// menu item has been selected
78 void activated(FuncRequest const &);
80 /// returns true if this view has the focus.
81 virtual bool hasFocus() const;
85 void update_view_state_qt();
87 /// populate a toplevel menu and all its children on demand
88 void updateMenu(QAction *);
91 /// make sure we quit cleanly
92 virtual void closeEvent(QCloseEvent * e);
95 virtual void resizeEvent(QResizeEvent * e);
98 virtual void moveEvent(QMoveEvent * e);
101 /// focus the command buffer widget
102 void focus_command_widget();
105 * setWindowTitle - set title of window
106 * @param t main window title
107 * @param it iconified (short) title
109 virtual void setWindowTitle(lyx::docstring const & t, lyx::docstring const & it);
111 QTimer statusbar_timer_;
114 QCommandBuffer * commandbuffer_;
117 void updateFloatingGeometry();
119 QRect floatingGeometry_;
122 } // namespace frontend