]> git.lyx.org Git - features.git/blob - src/frontends/qt4/GuiCommand.h
move GuiCommand into hedar of its own. InsetCommandParams.h is expensive
[features.git] / src / frontends / qt4 / GuiCommand.h
1 // -*- C++ -*-
2 /**
3  * \file GuiCommand.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Angus Leeming
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef GUICOMMAND_H
13 #define GUICOMMAND_H
14
15 #include "GuiDialog.h"
16
17 #include "insets/InsetCommandParams.h"
18
19
20 namespace lyx {
21 namespace frontend {
22
23 class GuiCommand : public GuiDialog
24 {
25 public:
26         /// We need to know with what sort of inset we're associated.
27         // FIXME This should probably be an InsetCode
28         GuiCommand(GuiView &, QString const & name, QString const & title);
29         ///
30         bool initialiseParams(std::string const & data);
31         /// clean-up on hide.
32         void clearParams() { params_.clear(); }
33         /// clean-up on hide.
34         void dispatchParams();
35         ///
36         bool isBufferDependent() const { return true; }
37
38 protected:
39         ///
40         InsetCommandParams params_;
41         //FIXME It should be possible to eliminate lfun_name_
42         //now and recover that information from params().insetType().
43         //But let's not do that quite yet.
44         /// Flags what action is taken by Kernel::dispatch()
45         std::string const lfun_name_;
46 };
47
48 } // namespace frontend
49 } // namespace lyx
50
51 #endif // GUIDIALOG_H