]> git.lyx.org Git - lyx.git/blob - src/frontends/qt4/GuiCommandBuffer.h
370c937b9f80e3fd3cdb9be2e7450d3a5518460e
[lyx.git] / src / frontends / qt4 / GuiCommandBuffer.h
1 // -*- C++ -*-
2 /**
3  * \file GuiCommandBuffer.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author John Levon
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef QCOMMANDBUFFER_H
13 #define QCOMMANDBUFFER_H
14
15 #include "controllers/ControlCommandBuffer.h"
16
17 #include <QWidget>
18
19 class QListWidgetItem;
20
21 namespace lyx {
22 namespace frontend {
23
24 class GuiCommandEdit;
25 class GuiView;
26
27 class GuiCommandBuffer : public QWidget {
28         Q_OBJECT
29 public:
30         GuiCommandBuffer(GuiViewBase * view);
31
32 public Q_SLOTS:
33         /// cancel command compose
34         void cancel();
35         /// dispatch a command
36         void dispatch();
37         /// tab-complete
38         void complete();
39         /// select-complete
40         void complete_selected(QListWidgetItem *);
41         /// up
42         void up();
43         /// down
44         void down();
45         /// leave and hide the command buffer
46         void hideParent();
47 private:
48         /// owning view
49         GuiViewBase * view_;
50
51         /// controller
52         ControlCommandBuffer controller_;
53
54         /// command widget
55         GuiCommandEdit * edit_;
56 };
57
58 } // namespace frontend
59 } // namespace lyx
60
61 #endif // QCOMMANDBUFFER_H