1
/***************************************************************************
2
* Copyright (c) 2004 Werner Mayer <werner.wm.mayer@gmx.de> *
4
* This file is part of the FreeCAD CAx development system. *
6
* This library is free software; you can redistribute it and/or *
7
* modify it under the terms of the GNU Library General Public *
8
* License as published by the Free Software Foundation; either *
9
* version 2 of the License, or (at your option) any later version. *
11
* This library is distributed in the hope that it will be useful, *
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14
* GNU Library General Public License for more details. *
16
* You should have received a copy of the GNU Library General Public *
17
* License along with this library; see the file COPYING.LIB. If not, *
18
* write to the Free Software Foundation, Inc., 59 Temple Place, *
19
* Suite 330, Boston, MA 02111-1307, USA *
21
***************************************************************************/
24
#ifndef GUI_DIALOG_DLGTOOLBARS_IMP_H
25
#define GUI_DIALOG_DLGTOOLBARS_IMP_H
27
#include "ui_DlgToolbars.h"
28
#include "PropertyPage.h"
33
/** This class implements the creation of user defined toolbars.
34
* In the left panel are shown all command groups with their command objects.
35
* If any changeable toolbar was created in the left panel are shown all commands
36
* of the currently edited toolbar, otherwise it is emtpy.
37
* All changes to a toolbar is done immediately.
39
* \author Werner Mayer
41
class DlgCustomToolbars : public CustomizeActionPage, public Ui_DlgCustomToolbars
46
enum Type { Toolbar, Toolboxbar };
48
DlgCustomToolbars(Type, QWidget* parent = 0);
49
virtual ~DlgCustomToolbars();
52
void on_categoryBox_activated(int index);
53
void on_workbenchBox_activated(int index);
54
void on_commandTreeWidget_currentItemChanged(QTreeWidgetItem*);
55
void on_toolbarTreeWidget_currentItemChanged(QTreeWidgetItem*);
56
void on_moveActionRightButton_clicked();
57
void on_moveActionLeftButton_clicked();
58
void on_moveActionUpButton_clicked();
59
void on_moveActionDownButton_clicked();
60
void on_newButton_clicked();
61
void on_renameButton_clicked();
62
void on_deleteButton_clicked();
63
void onAddMacroAction(const QByteArray&);
64
void onRemoveMacroAction(const QByteArray&);
65
void onModifyMacroAction(const QByteArray&);
68
void hideEvent(QHideEvent * event);
71
void importCustomToolbars(const QByteArray&);
72
void exportCustomToolbars(const QByteArray&);
78
/** This class implements the creation of user defined toolbars.
79
* @see DlgCustomToolbars
80
* @see DlgCustomCmdbarsImp
81
* \author Werner Mayer
83
class DlgCustomToolbarsImp : public DlgCustomToolbars
88
DlgCustomToolbarsImp(QWidget* parent = 0);
89
~DlgCustomToolbarsImp();
92
/** This class implements the creation of user defined toolbox bars.
93
* A toolbox bar is the same as a toolbar - a collection of several
94
* action objects - unless a toolbox bar is placed in a toolbox,
95
* while a toolbar is placed in the dock areas of the main window.
96
* So toolbox bars are predestinated to save place on your desktop.
97
* @see DlgCustomToolbars
98
* @see DlgCustomToolbarsImp
99
* \author Werner Mayer
101
class DlgCustomToolBoxbarsImp : public DlgCustomToolbars
106
DlgCustomToolBoxbarsImp(QWidget* parent = 0);
107
~DlgCustomToolBoxbarsImp();
110
} // namespace Dialog
113
#endif // GUI_DIALOG_DLGTOOLBARS_IMP_H