KXmlGui

kedittoolbar.h
1 /*
2  This file is part of the KDE libraries
3  SPDX-FileCopyrightText: 2000 Kurt Granroth <[email protected]>
4  SPDX-FileCopyrightText: 2006 Hamish Rodda <[email protected]>
5 
6  SPDX-License-Identifier: LGPL-2.0-only
7 */
8 
9 #ifndef KEDITTOOLBAR_H
10 #define KEDITTOOLBAR_H
11 
12 #include <QDialog>
13 
14 #include <kxmlgui_export.h>
15 
16 class KActionCollection;
17 
18 class KEditToolBarPrivate;
19 class KXMLGUIFactory;
61 class KXMLGUI_EXPORT KEditToolBar : public QDialog
62 {
63  Q_OBJECT
64 public:
76  explicit KEditToolBar(KActionCollection *collection,
77  QWidget *parent = nullptr);
78 
97  explicit KEditToolBar(KXMLGUIFactory *factory,
98  QWidget *parent = nullptr);
99 
101  ~KEditToolBar() override;
102 
110  void setDefaultToolBar(const QString &toolBarName);
111 
129  void setResourceFile(const QString &file, bool global = true);
130 
138  static void setGlobalDefaultToolBar(const char *toolBarName); // TODO should be const QString&
139 
140 Q_SIGNALS:
146  void newToolBarConfig();
147 
148 #if KXMLGUI_ENABLE_DEPRECATED_SINCE(4, 0)
149 
152  KXMLGUI_DEPRECATED_VERSION(4, 0, "Use KEditToolBar::newToolBarConfig()")
153  QT_MOC_COMPAT void newToolbarConfig();
154 #endif
155 
156 protected:
157  void showEvent(QShowEvent *event) override;
158  void hideEvent(QHideEvent *event) override;
159 
160 private:
161  friend class KEditToolBarPrivate;
162  KEditToolBarPrivate *const d;
163 
164  Q_PRIVATE_SLOT(d, void _k_slotButtonClicked(QAbstractButton *))
165  Q_PRIVATE_SLOT(d, void _k_acceptOK(bool))
166  Q_PRIVATE_SLOT(d, void _k_enableApply(bool))
167 
169 };
170 
171 #endif // _KEDITTOOLBAR_H
A container for a set of QAction objects.
virtual void hideEvent(QHideEvent *event)
A dialog used to customize or configure toolbars.
Definition: kedittoolbar.h:61
KXMLGUIFactory, together with KXMLGUIClient objects, can be used to create a GUI of container widgets...
Q_DISABLE_COPY(Class)
virtual void showEvent(QShowEvent *event) override
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Fri Nov 27 2020 22:52:14 by doxygen 1.8.11 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.