X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Fqt4%2FGuiLabel.h;h=d616cbf1f5c5228f3a47026e3d70061f21209e31;hb=8b7584846c4e1a9c87a004fab479722fee7e3013;hp=64a9a0e8a1fa1bfb3a9ab9f86df474fd0bbf4f00;hpb=0a7705a6736a85c3c751f7b4e9998833cdb71fc9;p=lyx.git diff --git a/src/frontends/qt4/GuiLabel.h b/src/frontends/qt4/GuiLabel.h index 64a9a0e8a1..d616cbf1f5 100644 --- a/src/frontends/qt4/GuiLabel.h +++ b/src/frontends/qt4/GuiLabel.h @@ -13,48 +13,30 @@ #ifndef GUILABEL_H #define GUILABEL_H -#include "GuiDialog.h" #include "ui_LabelUi.h" -#include "insets/InsetCommandParams.h" +#include "InsetParamsWidget.h" namespace lyx { namespace frontend { -class GuiLabel : public GuiDialog, public Ui::LabelUi +class GuiLabel : public InsetParamsWidget, public Ui::LabelUi { Q_OBJECT public: - GuiLabel(GuiView & lv); - -private Q_SLOTS: - void change_adaptor(); - void reject(); - -private: - /// - bool isValid(); - /// Apply changes - void applyView(); - /// update - void updateContents(); - /// - bool initialiseParams(std::string const & data); - /// clean-up on hide. - void clearParams() { params_.clear(); } - /// clean-up on hide. - void dispatchParams(); - /// - bool isBufferDependent() const { return true; } - /// - void enableView(bool enable); - /// - bool canApply() const { return true; } + GuiLabel(QWidget * parent = 0); private: - /// - InsetCommandParams params_; + /// \name InsetParamsWidget inherited methods + //@{ + InsetCode insetCode() const { return LABEL_CODE; } + FuncCode creationCode() const { return LFUN_INSET_INSERT; } + void paramsToDialog(Inset const *); + docstring dialogToParams() const; + bool checkWidgets() const; + bool initialiseParams(std::string const &); + //@} }; } // namespace frontend