Developer Documentation
viewMode.cc
1 /*===========================================================================*\
2 * *
3 * OpenFlipper *
4  * Copyright (c) 2001-2015, RWTH-Aachen University *
5  * Department of Computer Graphics and Multimedia *
6  * All rights reserved. *
7  * www.openflipper.org *
8  * *
9  *---------------------------------------------------------------------------*
10  * This file is part of OpenFlipper. *
11  *---------------------------------------------------------------------------*
12  * *
13  * Redistribution and use in source and binary forms, with or without *
14  * modification, are permitted provided that the following conditions *
15  * are met: *
16  * *
17  * 1. Redistributions of source code must retain the above copyright notice, *
18  * this list of conditions and the following disclaimer. *
19  * *
20  * 2. Redistributions in binary form must reproduce the above copyright *
21  * notice, this list of conditions and the following disclaimer in the *
22  * documentation and/or other materials provided with the distribution. *
23  * *
24  * 3. Neither the name of the copyright holder nor the names of its *
25  * contributors may be used to endorse or promote products derived from *
26  * this software without specific prior written permission. *
27  * *
28  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS *
29  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED *
30  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A *
31  * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER *
32  * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, *
33  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, *
34  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR *
35  * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF *
36  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING *
37  * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS *
38  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *
39 * *
40 \*===========================================================================*/
41 
42 /*===========================================================================*\
43 * *
44 * $Revision$ *
45 * $LastChangedBy$ *
46 * $Date$ *
47 * *
48 \*===========================================================================*/
49 
50 
51 
52 #include "CoreWidget.hh"
53 
54 #include <OpenFlipper/widgets/viewModeWidget/viewModeWidget.hh>
55 #include <OpenFlipper/widgets/viewModeWidget/viewModeChangeWidget.hh>
56 
57 //=============================================================================
58 
61  //init viewMode subMenu
62  if (!viewModeMenu_){
63  viewModeMenu_ = new QMenu(tr("View Modes"));
65  viewGroup_ = new QActionGroup(0);
66  viewGroup_->setExclusive(true);
67  connect( viewGroup_, SIGNAL( triggered( QAction* ) ), this, SLOT( slotSetViewMode( QAction* ) ) );
68  }
69 
70  viewModeMenu_->clear();
71 
72  bool seenCustom = false;
73 
74  for (int i=0; i < viewModes_.size(); i++){
75 
76  //Add Separator above the custom widgets
77  if (viewModes_[i]->custom && !seenCustom){
78  viewModeMenu_->addSeparator();
79  seenCustom = true;
80  }
81 
82  //add Action to viewMenu
83  QAction* acViewMode = new QAction(viewModes_[i]->name, this);
84  acViewMode->setStatusTip(tr("Change ViewMode"));
85  viewGroup_->addAction(acViewMode);
86  viewModeMenu_->addAction(acViewMode);
87 
88  //add Separator after viewMode 'all'
89  if (viewModes_[i]->name == "All")
90  viewModeMenu_->addSeparator();
91  }
92 
93 
94  if ( OpenFlipperSettings().value("Core/Gui/TaskSwitcher/Hide",false).toBool() ) {
95  viewModeButton_->setVisible(false);
96  }
97 }
98 
99 void CoreWidget::slotAddViewModeToolboxes(QString _mode, QStringList _usedWidgets){
100  slotAddViewModeToolboxes(_mode, false, _usedWidgets);
101 }
102 
103 void CoreWidget::slotAddViewModeToolboxes(QString _mode, bool _custom, QStringList _usedWidgets){
104  int id = -1;
105 
106  // Check if it already exists
107  for ( int i = 0 ; i < viewModes_.size(); i++) {
108  if ( viewModes_[i]->name == _mode ) {
109  id = i;
110  break;
111  }
112  }
113 
114  ViewMode* vm = 0;
115  if ( id == -1 ) {
116  vm = new ViewMode();
117  vm->name = _mode;
118  vm->custom = _custom;
119  vm->icon = "Unknown.png";
120 
121  vm->visibleToolbars = QString("Main Toolbar;Viewer Toolbar").split(";");
122  vm->visibleContextMenus = QString("ALL_THAT_EXIST").split(" ");
123 
124  if (_custom) {
125  viewModes_.push_back(vm);
126  } else {
127  //insert before custom viewModes
128  int i = viewModes_.size();
129  for (int k=0; k < viewModes_.size(); k++)
130  if (viewModes_[k]->custom == true){
131  i = k;
132  break;
133  }
134  viewModes_.insert(i,vm);
135  }
136 
137  } else {
138  vm = viewModes_[id];
139  }
140 
141  vm->visibleToolboxes = _usedWidgets;
142 
143  initViewModes();
144 }
145 
146 void CoreWidget::slotAddViewModeToolbars(QString _mode, QStringList _usedToolbars) {
147  slotAddViewModeToolbars(_mode,false,_usedToolbars);
148 }
149 
150 void CoreWidget::slotAddViewModeToolbars(QString _mode, bool _custom, QStringList _usedToolbars) {
151  int id = -1;
152 
153  // Check if it already exists
154  for ( int i = 0 ; i < viewModes_.size(); i++) {
155  if ( viewModes_[i]->name == _mode ) {
156  id = i;
157  break;
158  }
159  }
160 
161  ViewMode* vm = 0;
162  if ( id == -1 ) {
163  vm = new ViewMode();
164  vm->name = _mode;
165  vm->custom = _custom;
166  vm->icon = "Unknown.png";
167 
168  vm->visibleContextMenus = QString("ALL_THAT_EXIST").split(" ");
169 
170  if (_custom) {
171  viewModes_.push_back(vm);
172  } else {
173  //insert before custom viewModes
174  int i = viewModes_.size();
175  for (int k=0; k < viewModes_.size(); k++) {
176  if (viewModes_[k]->custom == true){
177  i = k;
178  break;
179  }
180  }
181 
182  viewModes_.insert(i,vm);
183  }
184  } else {
185  vm = viewModes_[id];
186  }
187 
188  // Always add the viewer Toolbar
189  if ( ! _usedToolbars.contains("Viewer Toolbar") )
190  _usedToolbars.prepend("Viewer Toolbar");
191 
192  // Always add the main Toolbar
193  if ( ! _usedToolbars.contains("Main Toolbar") )
194  _usedToolbars.prepend("Main Toolbar");
195 
196  vm->visibleToolbars = _usedToolbars;
197 
198  initViewModes();
199 }
200 
201 
202 void CoreWidget::slotAddViewModeContextMenus(QString _mode, QStringList _usedContextMenus){
203  slotAddViewModeContextMenus(_mode, false, _usedContextMenus);
204 }
205 
206 void CoreWidget::slotAddViewModeContextMenus(QString _mode, bool _custom, QStringList _usedContextMenus){
207  int id = -1;
208 
209  // Check if it already exists
210  for ( int i = 0 ; i < viewModes_.size(); i++) {
211  if ( viewModes_[i]->name == _mode ) {
212  id = i;
213  break;
214  }
215  }
216 
217  ViewMode* vm = 0;
218  if ( id == -1 ) {
219  vm = new ViewMode();
220  vm->name = _mode;
221  vm->custom = _custom;
222  vm->icon = "Unknown.png";
223 
224  vm->visibleToolbars = QString("Main Toolbar;Viewer Toolbar").split(";");
225 
226  if (_custom) {
227  viewModes_.push_back(vm);
228  } else {
229  //insert before custom viewModes
230  int i = viewModes_.size();
231  for (int k=0; k < viewModes_.size(); k++)
232  if (viewModes_[k]->custom == true){
233  i = k;
234  break;
235  }
236  viewModes_.insert(i,vm);
237  }
238 
239  } else {
240  vm = viewModes_[id];
241  }
242 
243  vm->visibleContextMenus = _usedContextMenus;
244 
245  initViewModes();
246 }
247 
249 void CoreWidget::slotSetViewModeIcon(QString _mode, QString _iconName) {
250  slotSetViewModeIcon(_mode,false,_iconName);
251 }
252 
254 void CoreWidget::slotSetViewModeIcon(QString _mode, bool _custom, QString _iconName) {
255 
256  int id = -1;
257 
258  // Check if it already exists
259  for ( int i = 0 ; i < viewModes_.size(); i++) {
260  if ( viewModes_[i]->name == _mode ) {
261  id = i;
262  break;
263  }
264  }
265 
266  ViewMode* vm = 0;
267  if ( id == -1 ) {
268  vm = new ViewMode();
269  vm->name = _mode;
270  vm->custom = _custom;
271  vm->icon = _iconName;
272 
273  if (_custom) {
274  viewModes_.push_back(vm);
275  } else {
276 
277  //insert before custom viewModes
278  int i = viewModes_.size();
279 
280  for (int k=0; k < viewModes_.size(); k++) {
281  if (viewModes_[k]->custom == true){
282  i = k;
283  break;
284  }
285  }
286 
287  viewModes_.insert(i,vm);
288  }
289  } else {
290  vm = viewModes_[id];
291  }
292 
293  vm->icon = _iconName;
294 
295  initViewModes();
296 }
297 
299 void CoreWidget::slotRemoveViewMode(QString _name){
300  for (int i=0; i < viewModes_.size(); i++)
301  if (viewModes_[i]->name == _name && viewModes_[i]->custom == true){ //remove only userdefined viewModes
302  viewModes_.remove(i);
303  //remove action from menu
304  for (int a=0; a < viewModeMenu_->actions().size(); a++)
305  if (viewModeMenu_->actions()[a]->text() == _name){
306  QAction* action = viewModeMenu_->actions()[a];
307  viewModeMenu_->removeAction(action);
308  viewGroup_->removeAction(action);
309  delete action;
310  }
311  break;
312 
313  }
314 }
315 
317 void CoreWidget::slotSetViewMode( QAction* action){
318  setViewMode( action->text() );
319 }
320 
322 void CoreWidget::setViewMode( QString _mode, bool _expandAll ){
323  slotChangeView(_mode, QStringList(), QStringList(), QStringList(), _expandAll);
324 }
325 
326 void CoreWidget::slotAddViewModeComplete(QString _mode , bool _custom, QStringList _toolboxes, QStringList _toolbars, QStringList _contextmenus) {
327  slotAddViewModeToolbars(_mode,_custom,_toolbars);
328  slotAddViewModeToolboxes(_mode,_custom,_toolboxes);
329  slotAddViewModeContextMenus(_mode,_custom,_contextmenus);
330 }
331 
334  //init widget
335  static viewModeWidget* widget = 0;
336  if ( !widget ){
337  widget = new viewModeWidget(viewModes_);
338  widget->setWindowIcon( OpenFlipper::Options::OpenFlipperIcon() );
339  connect(widget, SIGNAL(changeView(QString, QStringList, QStringList, QStringList)), this, SLOT(slotChangeView(QString, QStringList, QStringList, QStringList)) );
340  connect(widget, SIGNAL(saveMode(QString, bool, QStringList, QStringList, QStringList)), this, SLOT(slotAddViewModeComplete(QString, bool, QStringList, QStringList, QStringList)) );
341  connect(widget, SIGNAL(removeMode(QString)), this, SLOT(slotRemoveViewMode(QString)) );
342  }
343  widget->show( OpenFlipper::Options::currentViewMode() );
344 }
345 
347  QWidget *parent = qobject_cast<QWidget*>(modeChangeWidget->parent());
348  if (parent)
349  parent->close();
350 }
351 
353 void CoreWidget::slotChangeView(QString _mode, QStringList _toolboxWidgets, QStringList _toolbars, QStringList _contextmenus, bool _expandAll ){
354 
355  //try to find Widgets if they aren't given
356  if (_mode != "" && _toolboxWidgets.size() == 0 && _toolbars.size() == 0)
357  for (int i=0; i < viewModes_.size(); i++)
358  if (viewModes_[i]->name == _mode) {
359  _toolboxWidgets = viewModes_[i]->visibleToolboxes;
360  _toolbars = viewModes_[i]->visibleToolbars;
361  _contextmenus = viewModes_[i]->visibleContextMenus;
362  }
363 
364 
365  // Remove all toolbox entries if the view has changed
366  if (_mode != OpenFlipper::Options::currentViewMode()) {
367  toolBox_->saveViewModeState(OpenFlipper::Options::currentViewMode());
368  toolBox_->clear();
369  }
370 
371  //find all widgets that should be visible
372  for (int i=0; i < _toolboxWidgets.size(); i++) {
373  for (uint p=0; p < plugins_.size(); p++){
374  for ( uint j = 0 ; j < plugins_[p].toolboxWidgets.size(); ++j )
375  if (_toolboxWidgets[i] == plugins_[p].toolboxWidgets[j].first ) {
376 
377  bool skip = false;
378  if (toolBox_->plugins().contains(plugins_[p].plugin)) {
379  // account for the case, where a plugin can have several
380  // toolboxes, for example 'Scripting'
381  if (toolBox_->names().contains(_toolboxWidgets[i]))
382  skip = true;
383  }
384 
385  // only add items that have not been added yet
386  if (!skip) {
387  toolBox_->addItem (plugins_[p].plugin, plugins_[p].toolboxWidgets[j].second, plugins_[p].toolboxWidgets[j].first, plugins_[p].toolboxIcons[j], plugins_[p].headerAreaWidgets[j].second );
388 
389  // move item to the correct position
390  if (i < toolBox_->lastPos_) {
391  toolBox_->moveItemToPosition(plugins_[p].plugin, _toolboxWidgets[i], i);
392  } else
393  toolBox_->lastPos_ = i;
394 
395  // check if we have to restore the state
396  // of toolboxes added via scripts
397  if (plugins_[p].name == "Scripting") {
398 
399  QFile statesFile(OpenFlipper::Options::configDirStr() + OpenFlipper::Options::dirSeparator() + "WindowStates.dat");
400 
401  if (statesFile.exists() ) {
402  QSettings windowStates(OpenFlipper::Options::configDirStr() + OpenFlipper::Options::dirSeparator() + "WindowStates.dat", QSettings::IniFormat);
403 
404 
405  windowStates.beginGroup ("Core");
406  windowStates.beginGroup("SideArea");
407  windowStates.beginGroup(_toolboxWidgets[i]);
408  bool active = windowStates.value ("Active", false).toBool();
409  windowStates.endGroup();
410  windowStates.endGroup();
411  windowStates.endGroup();
412 
413  toolBox_->setElementActive(_toolboxWidgets[i], active);
414  }
415  }
416  }
417  }
418  }
419  }
420 
421  if (_mode != OpenFlipper::Options::currentViewMode()) {
423  }
424 
425  if (_expandAll)
426  toolBox_->expandAll();
427 
428  if ( ! OpenFlipperSettings().value("Core/Gui/Toolbar/hidden",false).toBool())
429  {
430  //find all Toolbars that should be visible and hide the others
431  for (uint p=0; p < plugins_.size(); p++)
432  for ( uint j = 0 ; j < plugins_[p].toolbars.size(); ++j )
433  if (_toolbars.contains( plugins_[p].toolbars[j].first ) )
434  plugins_[p].toolbars[j].second->show();
435  else
436  plugins_[p].toolbars[j].second->hide();
437 
438 
439  // Check the Main Toolbar:
440  if ( _toolbars.contains(tr("Main Toolbar")) )
441  mainToolbar_->show();
442  else
443  mainToolbar_->hide();
444 
445  // Check the Main Toolbar:
446  if ( _toolbars.contains(tr("Viewer Toolbar")) )
447  viewerToolbar_->show();
448  else
449  viewerToolbar_->hide();
450  }
451 
452 
453  if (_mode != "")
454  OpenFlipper::Options::currentViewMode(_mode);
455 
456 }
457 
458 void CoreWidget::moveToolBoxToTop(QString _name) {
459 
460  toolBox_->moveItemToPosition(_name, 0);
461 }
462 
463 void CoreWidget::moveToolBoxToBottom(QString _name) {
464 
466 }
467 
468 void CoreWidget::stereoButtonContextMenu(const QPoint& _pos) {
469 
470  // Grey out OpenGL stereo mode option if not available
471  if(!OpenFlipper::Options::glStereo()) {
472  stereoSettingsWidget_->stereoOpengl->setDisabled(true);
473  } else {
474  stereoSettingsWidget_->stereoOpengl->setChecked(OpenFlipper::Options::stereoMode() == OpenFlipper::Options::OpenGL);
475  }
476 
477  // Set values
478  stereoSettingsWidget_->stereoAnaglyph->setChecked(OpenFlipper::Options::stereoMode() == OpenFlipper::Options::AnaglyphRedCyan);
479  stereoSettingsWidget_->stereoCustomAnaglyph->setChecked(OpenFlipper::Options::stereoMode() == OpenFlipper::Options::AnaglyphCustom);
480 
481  stereoSettingsWidget_->eyeDistance->setValue( OpenFlipperSettings().value("Core/Stereo/EyeDistance").toDouble() );
482  stereoSettingsWidget_->focalDistance->setValue( OpenFlipperSettings().value("Core/Stereo/FocalDistance").toDouble() * 1000);
483 
484  // Move widget to the position of the cursor
485  stereoSettingsWidget_->move(stereoButton_->mapToGlobal(_pos) - QPoint((int)(stereoSettingsWidget_->width()/2), 0));
486  // Show widget
487  stereoSettingsWidget_->show();
488 }
489 
490 void CoreWidget::slotApplyStereoSettings(int /*_tmpParam*/) {
491 
492  // Update values
493  if (stereoSettingsWidget_->stereoCustomAnaglyph->isChecked()) {
494  // Update option entry
495  OpenFlipper::Options::stereoMode(OpenFlipper::Options::AnaglyphCustom);
496  // Show right stacked widget
497  stereoSettingsWidget_->stackedWidget->setCurrentIndex(0);
498  } else if (stereoSettingsWidget_->stereoAnaglyph->isChecked()) {
499  OpenFlipper::Options::stereoMode(OpenFlipper::Options::AnaglyphRedCyan);
500  stereoSettingsWidget_->stackedWidget->setCurrentIndex(0);
501  } else {
502  OpenFlipper::Options::stereoMode(OpenFlipper::Options::OpenGL);
503  stereoSettingsWidget_->stackedWidget->setCurrentIndex(0);
504  }
505 
506  // Save everything
507  OpenFlipperSettings().setValue("Core/Stereo/EyeDistance",stereoSettingsWidget_->eyeDistance->value());
508  OpenFlipperSettings().setValue("Core/Stereo/FocalDistance",double(stereoSettingsWidget_->focalDistance->value()/1000.0));
509 
510  // Update all views
511  for (unsigned int i = 0 ; i < OpenFlipper::Options::examinerWidgets() ; ++i) {
512  examiner_widgets_[i]->updateGL();
513  }
514 }
515 
517 {
518  examiner_widgets_[_id]->updateGL();
519 }
void moveItemToPosition(const QString &_name, int _position)
Move a toolbox widget to a given position.
Definition: SideArea.cc:90
QActionGroup * viewGroup_
Group for all menu items.
Definition: CoreWidget.hh:867
QToolBar * viewerToolbar_
Called by Plugins to add a Toolbar.
Definition: CoreWidget.hh:810
const QList< const QObject * > & plugins()
Get plugins in side area.
Definition: SideArea.cc:230
void show(QString _lastMode)
overloaded show function
void restoreViewModeState(const QString &_viewMode)
restores the active state of _viewMode
Definition: SideArea.cc:210
void moveToolBoxToBottom(QString _name)
Move a specific toolbox widget to the bottom of the side area.
Definition: viewMode.cc:463
bool custom
Is this a user defined custom view mode or a plugin generated one.
Definition: CoreWidget.hh:139
void slotApplyStereoSettings(int _tmpParam=0)
Definition: viewMode.cc:490
QStringList visibleToolboxes
List of Visible Toolboxes in this view mode.
Definition: CoreWidget.hh:142
ViewMode struct This struct contains a ViewMode and its status information such as used widgets...
Definition: CoreWidget.hh:129
QMenu * viewMenu_
View Menu.
Definition: CoreWidget.hh:792
StereoSettingsWidget * stereoSettingsWidget_
Widget to change stereo settings.
Definition: CoreWidget.hh:1162
SideArea * toolBox_
Toolbox.
Definition: CoreWidget.hh:726
void closeChangeViewModePopup()
Closes the change view mode popup.
Definition: viewMode.cc:346
void setViewMode(QString _mode, bool _expandAll=false)
Set the view Mode to the given Mode.
Definition: viewMode.cc:322
DLLEXPORT OpenFlipperQSettings & OpenFlipperSettings()
QSettings object containing all program settings of OpenFlipper.
void slotAddViewModeContextMenus(QString _mode, QStringList _usedToolbars)
Add or change Toolbars for a ViewMode (non-userdefined viewMode)
Definition: viewMode.cc:202
QString icon
Definition: CoreWidget.hh:136
void slotViewModeDialog()
Show a dialog in which the viewMode can be edited.
Definition: viewMode.cc:333
void slotChangeView(QString _mode, QStringList _toolboxWidgets, QStringList _toolbars, QStringList _contextmenus, bool _expandAll=false)
Slot for Changing visible toolWidgets.
Definition: viewMode.cc:353
QMenu * viewModeMenu_
Submenu holding all ViewMode actions.
Definition: CoreWidget.hh:584
void setValue(const QString &key, const QVariant &value)
Wrapper function which makes it possible to enable Debugging output with -DOPENFLIPPER_SETTINGS_DEBUG...
QAction * viewModeButton_
a List of all widgets in the toolbar
Definition: CoreWidget.hh:581
QToolBar * mainToolbar_
Called by Plugins to add a Toolbar.
Definition: CoreWidget.hh:1233
viewModeChangeWidget * modeChangeWidget
Handle to picking toolbar.
Definition: CoreWidget.hh:750
QStringList visibleToolbars
List of Toolbars in this view mode.
Definition: CoreWidget.hh:145
QToolButton * stereoButton_
Called by Plugins to add a Toolbar.
Definition: CoreWidget.hh:814
void addItem(QObject const *const _plugin, QWidget *_w, QString _name, QIcon *_icon=0, QWidget *_headerAreaWidget=0)
Definition: SideArea.cc:78
void slotAddViewModeToolboxes(QString _mode, QStringList _usedWidgets)
Add or change Toolboxes for a ViewMode (non-userdefined viewMode)
Definition: viewMode.cc:99
const QStringList & names()
Get item names.
Definition: SideArea.cc:236
QString name
Name of the View Mode.
Definition: CoreWidget.hh:132
void slotRemoveViewMode(QString _name)
Remove viewMode.
Definition: viewMode.cc:299
int getNumberOfWidgets() const
Get number of widgets.
Definition: SideArea.cc:138
std::vector< glViewer * > examiner_widgets_
Examiner Widget.
Definition: CoreWidget.hh:669
void clear()
clears the whole tool widget area
Definition: SideArea.cc:144
void initViewModes()
init ViewModes that were loaded via ini-file
Definition: viewMode.cc:60
void saveViewModeState(const QString &_viewMode)
saves the active state of _viewMode
Definition: SideArea.cc:202
QStringList visibleContextMenus
List of context Menus in this view mode.
Definition: CoreWidget.hh:148
void slotSetViewModeIcon(QString _mode, QString _iconName)
Sets the Icon for a given View Mode (non-userdefined viewMode)
Definition: viewMode.cc:249
void slotAddViewModeToolbars(QString _mode, QStringList _usedToolbars)
Add or change Toolbars for a ViewMode (non-userdefined viewMode)
Definition: viewMode.cc:146
void stereoButtonContextMenu(const QPoint &_pos)
Creates custom context menu for stereo viewer settings.
Definition: viewMode.cc:468
void slotSetViewMode(QAction *action)
Slot for setting ViewMode from Menu.
Definition: viewMode.cc:317
void slotAddViewModeComplete(QString _mode, bool _custom, QStringList _toolboxes, QStringList _toolbars, QStringList _contextmenus)
Completly configure a view mode ( set toolbars, toolboxes, context menus, ... )
Definition: viewMode.cc:326
void moveToolBoxToTop(QString _name)
Move a specific toolbox widget to the top of the side area.
Definition: viewMode.cc:458
void slotUpdateExaminer(unsigned _id)
update the content of the specified examiner
Definition: viewMode.cc:516
QVector< ViewMode * > & viewModes_
List of currently available viewModes.
Definition: CoreWidget.hh:577
void setElementActive(QString _name, bool _active)
set the active state of given element
Definition: SideArea.cc:218