25 |
25 |
26 #include "zz_setContentsDialog.h" |
26 #include "zz_setContentsDialog.h" |
27 #include "zz_configDialog.h" |
27 #include "zz_configDialog.h" |
28 #include "zz_addObjectDialog.h" |
28 #include "zz_addObjectDialog.h" |
29 #include "misc.h" |
29 #include "misc.h" |
|
30 #include "zz_colorSelectDialog.h" |
30 |
31 |
31 #define MAKE_ACTION(OBJECT, DISPLAYNAME, IMAGENAME, DESCR) \ |
32 #define MAKE_ACTION(OBJECT, DISPLAYNAME, IMAGENAME, DESCR) \ |
32 qAct_##OBJECT = new QAction (QIcon ("./icons/" IMAGENAME ".png"), tr (DISPLAYNAME), this); \ |
33 qAct_##OBJECT = new QAction (QIcon ("./icons/" IMAGENAME ".png"), tr (DISPLAYNAME), this); \ |
33 qAct_##OBJECT->setStatusTip (tr (DESCR)); \ |
34 qAct_##OBJECT->setStatusTip (tr (DESCR)); \ |
34 connect (qAct_##OBJECT, SIGNAL (triggered ()), this, SLOT (slot_##OBJECT ())); |
35 connect (qAct_##OBJECT, SIGNAL (triggered ()), this, SLOT (slot_##OBJECT ())); |
105 MAKE_ACTION (settings, "Settings", "settings", "Edit the settings of " APPNAME_DISPLAY ".") |
106 MAKE_ACTION (settings, "Settings", "settings", "Edit the settings of " APPNAME_DISPLAY ".") |
106 |
107 |
107 MAKE_ACTION (help, "Help", "help", "Shows the " APPNAME_DISPLAY " help manual.") |
108 MAKE_ACTION (help, "Help", "help", "Shows the " APPNAME_DISPLAY " help manual.") |
108 MAKE_ACTION (about, sAboutText, "ldforge", "Shows information about " APPNAME_DISPLAY ".") |
109 MAKE_ACTION (about, sAboutText, "ldforge", "Shows information about " APPNAME_DISPLAY ".") |
109 MAKE_ACTION (aboutQt, "About Qt", "aboutQt", "Shows information about Qt.") |
110 MAKE_ACTION (aboutQt, "About Qt", "aboutQt", "Shows information about Qt.") |
|
111 |
|
112 MAKE_ACTION (testColorSelect, "Test colors", "palette", "Test the color selection dialog") |
110 |
113 |
111 // Keyboard shortcuts |
114 // Keyboard shortcuts |
112 qAct_new->setShortcut (Qt::CTRL | Qt::Key_N); |
115 qAct_new->setShortcut (Qt::CTRL | Qt::Key_N); |
113 qAct_open->setShortcut (Qt::CTRL | Qt::Key_O); |
116 qAct_open->setShortcut (Qt::CTRL | Qt::Key_O); |
114 qAct_save->setShortcut (Qt::CTRL | Qt::Key_S); |
117 qAct_save->setShortcut (Qt::CTRL | Qt::Key_S); |
201 qEditToolBar->addAction (qAct_copy); |
204 qEditToolBar->addAction (qAct_copy); |
202 qEditToolBar->addAction (qAct_paste); |
205 qEditToolBar->addAction (qAct_paste); |
203 qEditToolBar->addAction (qAct_inline); |
206 qEditToolBar->addAction (qAct_inline); |
204 qEditToolBar->addAction (qAct_splitQuads); |
207 qEditToolBar->addAction (qAct_splitQuads); |
205 qEditToolBar->addAction (qAct_setContents); |
208 qEditToolBar->addAction (qAct_setContents); |
|
209 qEditToolBar->addAction (qAct_testColorSelect); |
206 addToolBar (qEditToolBar); |
210 addToolBar (qEditToolBar); |
207 } |
211 } |
208 |
212 |
209 // ============================================================================= |
213 // ============================================================================= |
210 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * |
214 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * |