CoreWidget Class Reference

#include <CoreWidget.hh>

Collaboration diagram for CoreWidget:
Collaboration graph
[legend]

List of all members.

Classes

struct  PickMode

Signals

void clearAll ()
void loadMenu ()
void addEmptyObjectMenu ()
void saveMenu ()
void saveToMenu ()
void loadIniMenu ()
void saveIniMenu ()
void recentOpen (QAction *)
void exit ()
void loadPlugin ()
void showPlugins ()
Logger



void log (Logtype _type, QString _message)
void log (QString _message)

Public Member Functions

 CoreWidget (QVector< ViewMode * > &_viewModes, std::vector< PluginInfo > &_plugins, QList< SlotInfo > &_coreSlots)
 constructor
 ~CoreWidget ()
 destructor
GUI creation



void setupMenuBar ()
 Setup the main menubar.
Recent File Menu handling



void addRecent (QString _filename, DataType _type)
 Add a recent file and update menu.
void updateRecent ()
 Update the recent files menu.

Public Attributes

Basic Gui Elements



std::vector< glViewer * > examiner_widgets_
 Examiner Widget.
QSplitter * splitter_
 Spliter between toplevel objects and the textedit at the bottom.
LoggerWidgetlogWidget_
 Textedit at the bottom for log messages.
int originalLoggerSize_
 Size of the logging window ( defaults to 240 ).
QMenu * recentFilesMenu_
 QMenu containing the recently opened files.
QMenu * helpMenu_
 Help Menu.
QGLWidget * glWidget_
 gl widget used as drawing area to paint the graphics scene
QtGLGraphicsSceneglScene_
 graphics scene used to paint gl context and widgets
QtGLGraphicsViewglView_
 graphics view that holds the gl scene
QGraphicsWidget * centerWidget_
 center widged
QtMultiViewLayoutbaseLayout_
 Base layout that holds gl views.
QtSlideWindowslidingLogger_
 Class that holds the animated log widget.
QWidget * tempLogWidget
 Temporary widget.
QWidget * toolBoxArea_
 Widget for toolBox.
QPushButton * vmChangeButton_
 Button to change viewModes.
QSplitter * toolSplitter_
 Spliter between toplevel objects and toolbox.
SideAreatoolBox_
 Toolbox.
QScrollArea * toolBoxScroll_
 Toolbox scroll area.
QtPickToolbarpickToolbar_
 Toolbar showed in pickmode.
CursorPaintercursorPainter_
 Cursor handling.
ACG::QtWidgets::QtSceneGraphDialogsceneGraphDialog_

Private Slots

void closeEvent (QCloseEvent *event)
 Called on applications close.
void slotShowSceneGraphDialog ()
void slotActivateExaminer ()
void slotLog (Logtype _type, QString _message)
 Slot writing everything to the Logger widget.
void sceneRectChanged (const QRectF &rect)
Drag and Drop



void startDrag (QMouseEvent *_event)
void dragEnterEvent (QDragEnterEvent *_event)
void dropEvent (QDropEvent *_event)

Private Attributes

std::vector< PluginInfo > & plugins_

Keys



typedef std::multimap
< std::pair< int,
Qt::KeyboardModifiers >
, std::pair< QObject *, int > > 
KeyMap
 typedefs
typedef std::multimap
< std::pair< QObject *, int >
, std::pair< int,
Qt::KeyboardModifiers > > 
InverseKeyMap
typedef std::pair
< KeyMap::iterator,
KeyMap::iterator > 
KeyRange
std::vector< KeyBindingcoreKeys_
 vector of keys registered to the core
KeyMap keys_
 mapping of all keys to registered keys and the corresponding plugins
InverseKeyMap invKeys_
 mapping of all registered keys and the corresponding plugins to currently assigned keys
QList< SlotInfo > & coreSlots_
 list of scripting slots from core
bool shiftPressed_
 Store the state of the shift key.
void loadKeyBindings (INIFile &_ini)
 Load key assignments from a given INI file.
void saveKeyBindings (INIFile &_ini)
 Store current key assignments to a given INI file.
void PluginKeyEvent (QKeyEvent *)
void PluginKeyReleaseEvent (QKeyEvent *)
void registerKey (int _key, Qt::KeyboardModifiers _modifiers, QString _description, bool _multiUse=false)
 internal signal to register CoreWidget keys
void call (QString _expression, bool &_success)
 call a scripting function
void slotRegisterKey (int _key, Qt::KeyboardModifiers _modifiers, QString _description, bool _multiUse=false)
 key registration
virtual void keyPressEvent (QKeyEvent *_e)
 Handle key events.
virtual void keyReleaseEvent (QKeyEvent *_e)
 passes keyReleaseEvents to either the Core or a Plugin depending on who has registered the key
void registerCoreKeys ()
 Register all events related to the core.
void coreKeyPressEvent ()
 handle key events for the core
void coreKeyPressEvent (QKeyEvent *_e)
 Handle core key events.
void coreKeyReleaseEvent (QKeyEvent *_e)
 if a keyReleaseEvent belongs to the core this functions is called
KeyBinding getKeyBinding (QObject *_plugin, int _keyIndex)
QString getRPCName (QObject *_plugin)
void slotAddKeyMapping (int _key, Qt::KeyboardModifiers _modifiers, QObject *_plugin, int _keyBindingID)
 add a new key Mapping
void slotRegisterSlotKeyBindings ()
 register scripting slots to allow keyBindings

GUI Controls



OpenFlipper::Options::LoggerState loggerState_
uint fullscreenState_
void toggleFullscreen ()
 Set application to Fullscreen and back.
void setFullscreen (bool _state)
 Enable or disable fullscreen mode.
void toggleLogger ()
 Hide or show logging area.
void showLogger (OpenFlipper::Options::LoggerState _state)
 Change visibility of the logger.
void toggleToolbox ()
 Hide or show toolbox area.
void showToolbox (bool _state)
 Show or hide toolbox.
void setGlCursor (bool _state)
 Use native or gl painted cursor.

Tool Widgets / View Modes



QVector< QWidget * > toolWidgets_
 a List of all widgets in the toolbar
QPushButton * viewModeButton_
QMenu * viewModeMenu_
 Submenu holding all ViewMode actions.
QVector< ViewMode * > & viewModes_
 List of currently available viewModes.
void slotRemoveViewMode (QString _name)
 Remove viewMode.
void slotSetViewMode (QAction *action)
 Slot for setting ViewMode from Menu.
void slotViewModeDialog ()
 Show a dialog in which the viewMode can be edited.
void slotViewChangeDialog ()
 Show a dialog in which the viewMode can be changed.
void initViewModes ()
 init ViewModes that were loaded via ini-file
void slotAddViewModeToolboxes (QString _mode, QStringList _usedWidgets)
 Add or change Toolboxes for a ViewMode (non-userdefined viewMode).
void slotAddViewModeToolboxes (QString _mode, bool _custom, QStringList _usedWidgets)
 Add or change Toolboxes for a ViewMode (_custom == userdefined viewMode).
void slotAddViewModeToolbars (QString _mode, QStringList _usedToolbars)
 Add or change Toolbars for a ViewMode (non-userdefined viewMode).
void slotAddViewModeToolbars (QString _mode, bool _custom, QStringList _usedToolbars)
 Add or change Toolbars for a ViewMode (_custom == userdefined viewMode).
void slotAddViewModeComplete (QString _mode, bool _custom, QStringList _toolboxes, QStringList _toolbars)
 Completly configure a view mode ( set toolbars, toolboxes ... ).
void slotSetViewModeIcon (QString _mode, QString _iconName)
 Sets the Icon for a given View Mode (non-userdefined viewMode).
void slotSetViewModeIcon (QString _mode, bool _custom, QString _iconName)
 Sets the Icon for a given View Mode (_custom == userdefined viewMode).
void slotChangeView (QString _mode, QStringList _toolboxWidgets, QStringList _toolbars)
 Slot for Changing visible toolWidgets.
void setViewMode (QString _mode)
 Set the view Mode to the given Mode.

Menubar controls



QMenu * fileMenu_
 File Menu.
QMenu * viewMenu_
 View Menu.
QMenu * toolsMenu_
 Tools Menu.
QAction * fileMenuEnd_
 First entry after all relevant parts of the File Menu.
QMap< QString, QMenu * > menus_
 All available menus.
void slotAddMenubarAction (QAction *_action, QString _name)
void slotGetMenubarMenu (QString _name, QMenu *&_menu, bool _create)

ToolBar controls



QToolBar * viewerToolbar_
int toolbarCount_
QToolButton * stereoButton_
QToolButton * moveButton_
QToolButton * lightButton_
QToolButton * pickButton_
QToolButton * questionButton_
QComboBox * viewerLayoutBox_
QToolBar * mainToolbar_
std::vector< QToolBar * > toolbars_
void slotAddToolbar (QToolBar *_toolbar)
 Called by Plugins to add a Toolbar.
void slotRemoveToolbar (QToolBar *_toolbar)
 Called by Plugins to remove a Toolbar.
void getToolBar (QString _name, QToolBar *&_toolbar)
 Called by Plugins to get access to specific Toolbars by name.

View Menu



QMenu * globalDrawMenu_
 This variable holds the global draw menu.
QActionGroup * drawGroup_
QActionGroup * viewGroup_
 Group for all menu items.
QAction * perspectiveProjectionAction_
QAction * orthogonalProjectionAction_
QAction * globalAnimationAction_
 Action to globally set Animation.
QAction * globalBackfaceCullingAction_
 Action to globally set backface culling.
QAction * globalTwosidedLightingAction_
 Action to globally set Two-Sided lighting.
QAction * globalMultisamplingAction_
 Action to globally set multisampling.
int activeDrawModes_
int availableGlobalDrawModes_
void nextViewerLayout ()
 Switches over to the next view mode.
void slotGlobalDrawMenu (QAction *_action)
 Called when the global drawMode is selected.
void slotViewMenuAboutToShow ()
 Called before the view Menu is shown.
void slotUpdateGlobalDrawMenu ()
 Setup and update the global draw menu.
void setViewerLayout (int _idx)
 Change viewer layout that was selected in the combo box.

Context Menu



QMenu * contextMenu_
 context Menu for the gl area
QMenu * contextSelectionMenu_
 Context Menu containing all selection elements.
std::vector< MenuInfocontextMenus_
 All real context menu entries.
QActionGroup * drawGroupViewer_
 DrawGroup for per Viewer Draw Modes.
QMenu * viewerDrawMenu_
 Draw Menu for per Viewer Draw Modes.
QMenu * coordSysMenu_
void updateContextMenu (int)
 tells the plugins to update their context menu when an object is picked
void updateContextMenuNode (int)
 tells the plugins to update their context menu when a node is picked
void updateContextMenuBackground ()
 tells the plugins to update their context menu when the background is picked
void slotCustomContextMenu (const QPoint &_point)
 This slot is called by the examiner widgets gl area when a context menu is requested.
void slotAddContextItem (QAction *_entry, ContextMenuType _type)
 called by plugins to add a new context menu item
void slotAddContextItem (QAction *_entry, DataType _dataType, ContextMenuType type_)
 called by plugins to add a real context menu item depending on DataType
void slotPasteView ()
 Paste the view to the last active examiner.
void slotCopyView ()
 Copy view from the last active examiner.
void slotViewerDrawMenu (QAction *_action)
 Called when a coordsys drawMode has been changed.
void slotUpdateViewerDrawMenu ()
 Creates a draw Menu for the currently active Viewer.
void slotSnapshot ()
 Create a snapshot of the last active examiner.
void slotSwitchWheels (bool _state)
 Show / hide wheels.
void slotSwitchNavigation (bool _egomode)
 Switch navigation mode.
void slotSnapshotName ()
 Set the snapShot name for all examiners.
void slotCoordSysVisibility (bool _visible)
 Hide coordinate systems in all viewers.
void updatePopupMenu (const QPoint &_point)
 check current context and initialize context menu according to this context.
void updatePopupMenuCoordsysNode (QMenu *_menu, const int _part)
 Update context Menu when Coordsys node has been clicked on.
void updatePopupMenuObject (QMenu *_menu, BaseObjectData *_object)
 Update context Menu an object has been clicked on.
void updatePopupMenuBackground (QMenu *_menu, const QPoint &_point)
 Update context Menu when background has been clicked on.
void updatePopupMenuNode (QMenu *_menu, ACG::SceneGraph::BaseNode *_node)
 Update context Menu when an arbitrary node has been clicked on.
bool addContextMenus (QMenu *_menu, ContextMenuType _type, int _id=-1)

Snapshots



QString snapshotName_
int snapshotCounter_
void viewerSnapshotDialog ()
 Create a snapshot of the whole app with fileDialog.
void viewerSnapshot ()
 Create a snapshot of the whole app.
void applicationSnapshotDialog ()
 Create a snapshot of the whole app with fileDialog.
void applicationSnapshot ()
 Create a snapshot of the whole app.
void applicationSnapshotName (QString _name)
 Set the snapshot name.

StackWidget controls



QMenu * stackMenu_
 QMenu containing the recently opened files.
std::vector< StackWidgetInfostackWidgetList_
QStackedWidget * stackedWidget_
 Container widget for holding multiple views.
void slotGetStackWidget (QString _name, QWidget *&_widget)
void slotAddStackWidget (QString _name, QWidget *_widget)
void slotUpdateStackWidget (QString _name, QWidget *_widget)
void slotViewMenuAction (QAction *_action)
void slotUpdateStackMenu ()

Help System



HelpWidgethelpWidget_
 Pointer to the help Browser.
void showHelpBrowser ()
 Display the help Browser.

About System



AboutWidgetaboutWidget_
 Pointer to the about widget.
void showAboutWidget ()
 Display the about widget.

Options System



OptionsWidgetoptionsWidget_
 Pointer to the OptionsWidget.
void applyOptions ()
void saveOptions ()
void showOptionsWidget ()
 Display the Options Browser.

StatusBar controls



ColorStatusBarstatusBar_
QLabel * statusIcon_
void setupStatusBar ()
void statusMessage (QString _message, int _timeout=0)
void clearStatusMessage ()
void setStatus (ApplicationStatus::applicationStatus _status)

Viewer Controls



bool stereoActive_
void slotToggleStereoMode ()
 Enable or disable Stereo.
void slotSetGlobalBackgroundColor ()
 Set Background Color for all viewers at once.
void slotSetContextBackgroundColor ()
 Set Background Color for one viewer.
void slotContextHomeView ()
 Set the active viewer to home position.
void slotGlobalHomeView ()
 Set the viewer to home position.
void slotContextSetHomeView ()
 Set the active viewers home position.
void slotGlobalSetHomeView ()
 Set the home position for all viewers.
void slotContextViewAll ()
 Change view on active viewer to view complete scene.
void slotGlobalViewAll ()
 Change view on all viewers to view complete scene.
void slotContextSwitchProjection ()
 Toggle projection Mode of the active viewer.
void slotGlobalPerspectiveProjection ()
 Toggle projection Mode of all viewers to perspective projection.
void slotGlobalOrthographicProjection ()
 Toggle projection Mode of all viewers to orthographic projection.
void slotSetViewingDirection (QAction *_action)
 Change the Viewing direction from context-menu.
void slotGlobalChangeAnimation (bool _animation)
 Set the animation Mode for all viewers.
void slotLocalChangeAnimation (bool _animation)
 Set the animation Mode for active viewer.
void slotGlobalChangeBackFaceCulling (bool _backFaceCulling)
 Set Backface culling for all viewers.
void slotLocalChangeBackFaceCulling (bool _backFaceCulling)
 Set Backface culling for active viewer.
void slotGlobalChangeTwoSidedLighting (bool _lighting)
 Set two sided lighting for all viewers.
void slotLocalChangeTwoSidedLighting (bool _lighting)
 Set two sided lighting for active viewer.
void slotGlobalChangeMultisampling (bool _lighting)
 Set Multisampling for all viewers.
void slotLocalChangeMultisampling (bool _lighting)
 Set Multisampling for active viewer.
void moveBack ()
 When using first person mode move backward.
void moveForward ()
 When using first person mode move forward.
void strafeLeft ()
 When using first person mode strafe to the left.
void strafeRight ()
 When using first person mode strafe to the right.

Action Mode States



Viewer::ActionMode actionMode_
Viewer::ActionMode lastActionMode_
Viewer::ActionMode actionMode ()
Viewer::ActionMode lastActionMode ()
bool examineMode ()
bool pickingMode ()
bool lightMode ()
bool questionMode ()
void setExamineMode ()
void setPickingMode ()
void setLightMode ()
void setQuestionMode ()
void setActionMode (const Viewer::ActionMode _am)
void getActionMode (Viewer::ActionMode &_am)

PickModes



QMenu * pickMenu_
std::vector< PickModepick_modes_
std::string pick_mode_name_
int pick_mode_idx_
void addPickMode (const std::string &_name, bool _mouse_tracking=false, int _pos=-1, bool _visible=true, QCursor _cursor=Qt::ArrowCursor)
 add pick mode
void clearPickModes ()
const std::string & pickMode () const
void pickMode (int _id)
void signalPickModeChanged (const std::string &)
void hidePopupMenus ()
void updatePickMenu ()
 update pick mode menu
void setPickMode (const std::string _name)
void getPickMode (std::string &_name)
void setPickModeCursor (const std::string &_name, QCursor _cursor)
 set a new cursor for the pick mode
void setPickModeMouseTracking (const std::string &_name, bool _mouseTracking)
 set mouseTracking for the pick mode
void setPickModeToolbar (const std::string _mode, QToolBar *_toolbar)
 Set the additinal toolbar of the given PickMode.
void removePickModeToolbar (const std::string _mode)
 Removes the additinal toolbar of the given PickMode.
void actionPickMenu (QAction *_action)

Video Capturing



void startVideoCapture (QString _baseName, int _fps, bool _captureViewers)
void stopVideoCapture ()
void resizeViewers (int _width, int _height)
void resizeApplication (int _width, int _height)
void startVideoCaptureDialog ()

Detailed Description

Core Widget of the Application

Definition at line 150 of file CoreWidget.hh.


Constructor & Destructor Documentation

CoreWidget::CoreWidget ( QVector< ViewMode * > &  _viewModes,
std::vector< PluginInfo > &  _plugins,
QList< SlotInfo > &  _coreSlots 
)

Member Function Documentation

void CoreWidget::addPickMode ( const std::string &  _name,
bool  _mouse_tracking = false,
int  _pos = -1,
bool  _visible = true,
QCursor  _cursor = Qt::ArrowCursor 
)

add pick mode

Parameters:
_name Name of the Pick Mode or "Separator" to insert a separator
_mouse_tracking true: every mouse movement will emit mouse events not only when mousebutton is pressed
_pos position to insert the mode in the popup menu.

Definition at line 299 of file picking.cc.

References pick_modes_, and updatePickMenu().

Referenced by Core::slotAddHiddenPickMode(), and Core::slotAddPickMode().

void CoreWidget::applicationSnapshot (  )  [slot]

Create a snapshot of the whole app.

Take a snapshot of the whole application.

Definition at line 332 of file viewerControl.cc.

Referenced by Core::applicationSnapshot().

void CoreWidget::applicationSnapshotDialog (  )  [slot]

Create a snapshot of the whole app with fileDialog.

Take a snapshot of the whole application.

Definition at line 278 of file viewerControl.cc.

Referenced by setupMenuBar().

void CoreWidget::clearPickModes (  ) 

clear all pick modes

Definition at line 379 of file picking.cc.

References pick_mode_idx_, pick_mode_name_, pick_modes_, and updatePickMenu().

void CoreWidget::coreKeyPressEvent ( QKeyEvent *  _e  )  [private]

Handle core key events.

if a keyPressEvent belongs to the core this functions is called

Definition at line 552 of file keyHandling.cc.

References moveBack(), moveForward(), nextViewerLayout(), shiftPressed_, strafeLeft(), strafeRight(), toggleFullscreen(), toggleLogger(), and toggleToolbox().

void CoreWidget::coreKeyPressEvent (  )  [private]

handle key events for the core

This function is called to handle key events which are registered to the core

Referenced by keyPressEvent().

void CoreWidget::keyPressEvent ( QKeyEvent *  _e  )  [protected, virtual]

Handle key events.

passes keyPressEvents to either the Core or a Plugin depending on who has registered the key

Definition at line 81 of file keyHandling.cc.

References call(), coreKeyPressEvent(), keys_, and KeyInterface::slotKeyEvent().

void CoreWidget::pickMode ( int  _id  ) 
const std::string & CoreWidget::pickMode (  )  const

return the currently active pick mode

Definition at line 391 of file picking.cc.

References pick_mode_name_.

Referenced by setPickMode().

void CoreWidget::PluginKeyEvent ( QKeyEvent *   )  [signal]

When this Signal is emitted when a Keyevent Event occures The signal is connected to all Plugins implementing KeyInterface by the pluginLoader

void CoreWidget::PluginKeyReleaseEvent ( QKeyEvent *   )  [signal]

When this Signal is emitted when a Keyevent Release occures The signal is connected to all Plugins implementing KeyInterface by the pluginLoader

void CoreWidget::registerCoreKeys (  )  [private]

Register all events related to the core.

if a keyPressEvent belongs to the core this functions is called

Definition at line 518 of file keyHandling.cc.

References registerKey(), and slotRegisterKey().

Referenced by CoreWidget().

void CoreWidget::removePickModeToolbar ( const std::string  _mode  )  [slot]

Removes the additinal toolbar of the given PickMode.

Set the additional toolbar that should be shown in the pickMode

Parameters:
_mode Identifier of Picking mode

Definition at line 365 of file picking.cc.

References QtPickToolbar::detachToolbar(), pick_mode_name_, pick_modes_, and pickToolbar_.

void CoreWidget::sceneRectChanged ( const QRectF &  rect  )  [private, slot]

Updates the size of the main graphics widget in the scene

Definition at line 952 of file CoreWidget.cc.

References centerWidget_, pickToolbar_, slidingLogger_, QtPickToolbar::updateGeometry(), and QtSlideWindow::updateGeometry().

Referenced by CoreWidget().

void CoreWidget::setExamineMode (  )  [inline, slot]

Set action mode. The ActionMode determines the type of reaction on mouse events.

Definition at line 1015 of file CoreWidget.hh.

Referenced by CoreWidget().

void CoreWidget::setFullscreen ( bool  _state  ) 

Enable or disable fullscreen mode.

Enable or disable Fullscreen Mode

Definition at line 602 of file CoreWidget.cc.

Referenced by Core::fullscreen().

void CoreWidget::setPickMode ( const std::string  _name  )  [slot]

Switch to given picking mode

Parameters:
_name Name of the picking mode

Definition at line 177 of file picking.cc.

References pick_modes_, pickMode(), and updatePickMenu().

Referenced by CoreWidget().

void CoreWidget::setPickModeCursor ( const std::string &  _name,
QCursor  _cursor 
) [slot]

set a new cursor for the pick mode

Parameters:
_name Name of the Pick Mode
_cursor the new cursor

Definition at line 320 of file picking.cc.

References cursorPainter_, pick_mode_name_, pick_modes_, and CursorPainter::setCursor().

void CoreWidget::setPickModeMouseTracking ( const std::string &  _name,
bool  _mouseTracking 
) [slot]

set mouseTracking for the pick mode

Parameters:
_name Name of the Pick Mode
_mouseTracking true: every mouse movement will emit mouse events not only when mousebutton is pressed

Definition at line 335 of file picking.cc.

References examiner_widgets_, pick_mode_name_, and pick_modes_.

void CoreWidget::setPickModeToolbar ( const std::string  _mode,
QToolBar *  _toolbar 
) [slot]

Set the additinal toolbar of the given PickMode.

Set the additional toolbar that should be shown in the pickMode

Parameters:
_mode Identifier of Picking mode
_toolbar the toolbar

Definition at line 351 of file picking.cc.

References QtPickToolbar::attachToolbar(), pick_mode_name_, pick_modes_, and pickToolbar_.

void CoreWidget::setViewMode ( QString  _mode  )  [slot]

Set the view Mode to the given Mode.

Slot for setting the viewMode from menu.

Definition at line 246 of file viewMode.cc.

References slotChangeView().

Referenced by Core::init(), Core::setViewMode(), showToolbox(), slotSetViewMode(), and toggleFullscreen().

void CoreWidget::showLogger ( OpenFlipper::Options::LoggerState  _state  ) 

Change visibility of the logger.

Hide or show logger

Definition at line 644 of file CoreWidget.cc.

References QtSlideWindow::attachWidget(), baseLayout_, QtSlideWindow::detachWidget(), logWidget_, originalLoggerSize_, slidingLogger_, splitter_, and tempLogWidget.

Referenced by Core::applyOptions(), Core::loggerState(), and toggleLogger().

void CoreWidget::showToolbox ( bool  _state  ) 

Show or hide toolbox.

Hide or show toolbox

Definition at line 779 of file CoreWidget.cc.

References setViewMode(), and toolBoxArea_.

Referenced by Core::applyOptions(), Core::showToolbox(), and toggleToolbox().

void CoreWidget::signalPickModeChanged ( const std::string &   )  [signal]

This signal is emitted when the pickMode is changed and contains the new PickMode

Referenced by pickMode().

void CoreWidget::slotActivateExaminer (  )  [private, slot]

Makes the sender examiner active

Definition at line 976 of file CoreWidget.cc.

References examiner_widgets_, and PluginFunctions::setActiveExaminer().

Referenced by CoreWidget().

void CoreWidget::slotAddKeyMapping ( int  _key,
Qt::KeyboardModifiers  _modifiers,
QObject *  _plugin,
int  _keyBindingID 
) [slot]

add a new key Mapping

add a new keyMapping (keyBindingID is the id of the keyBinding in the pluginInfo of _plugin :)

internal function that stores a new keyCombination assignment for an existing keyBinding

Definition at line 343 of file keyHandling.cc.

References invKeys_, keys_, and BaseInterface::name().

Referenced by loadKeyBindings(), and showOptionsWidget().

void CoreWidget::slotContextHomeView (  )  [private, slot]

Set the active viewer to home position.

Set the viewer to home position.

Definition at line 115 of file viewerControl.cc.

References PluginFunctions::activeExaminer(), and examiner_widgets_.

Referenced by updatePopupMenuCoordsysNode().

void CoreWidget::slotContextSetHomeView (  )  [private, slot]

Set the active viewers home position.

Set the viewers home position.

Definition at line 144 of file viewerControl.cc.

References PluginFunctions::activeExaminer(), and examiner_widgets_.

Referenced by updatePopupMenuCoordsysNode().

void CoreWidget::slotGlobalOrthographicProjection (  )  [private, slot]

Toggle projection Mode of all viewers to orthographic projection.

Toggle projection Mode of all viewers to orthogonal projection.

Definition at line 179 of file viewerControl.cc.

References examiner_widgets_, and PluginFunctions::viewers().

Referenced by setupMenuBar().

void CoreWidget::slotLog ( Logtype  _type,
QString  _message 
) [private, slot]

Slot writing everything to the Logger widget.

Display a log message in the Mainwidget

Parameters:
_type Type of Message (OUT,WARN,ERR)
_message The message to be displayed

This slot has to be called by all loggers. It is used to serialize and color the Output.

Parameters:
_type Logtype (defines the color of the output)
_message The message for output

Definition at line 76 of file CoreWidgetLogging.cc.

References logWidget_.

void CoreWidget::slotRegisterKey ( int  _key,
Qt::KeyboardModifiers  _modifiers,
QString  _description,
bool  _multiUse = false 
) [private, slot]

key registration

Register a key to the core or a plugin.

internal slot that registers a keyCombination to the sender() who emitted the registerKey() signal only after registering keyCombinations plugins receive keyEvents to the corresponding keyCombinations via KeyInterface.

Definition at line 219 of file keyHandling.cc.

References coreKeys_, invKeys_, PluginInfo::keys, keys_, and PluginInfo::plugin.

Referenced by registerCoreKeys().

void CoreWidget::slotRegisterSlotKeyBindings (  )  [slot]

register scripting slots to allow keyBindings

scripting slots will automatically registered to be assigned to an invalid key(-1)

internal function that registers all public slots without parameters of each plugin (or core) to the key management system. This allows the assignment of keyBindings for each of these slots.

Definition at line 296 of file keyHandling.cc.

References coreKeys_, coreSlots_, invKeys_, and keys_.

Referenced by Core::init().

void CoreWidget::slotRemoveViewMode ( QString  _name  )  [private, slot]

Remove viewMode.

Remove a viewMode.

Definition at line 223 of file viewMode.cc.

References viewGroup_, viewModeMenu_, and viewModes_.

Referenced by slotViewModeDialog().

void CoreWidget::slotSetViewMode ( QAction *  action  )  [private, slot]

Slot for setting ViewMode from Menu.

Slot for setting the viewMode from menu.

Definition at line 241 of file viewMode.cc.

References setViewMode().

Referenced by initViewModes().

void CoreWidget::slotSetViewModeIcon ( QString  _mode,
bool  _custom,
QString  _iconName 
) [slot]

Sets the Icon for a given View Mode (_custom == userdefined viewMode).

Sets the Icon for a given View Mode.

Definition at line 182 of file viewMode.cc.

References ViewMode::custom, ViewMode::icon, initViewModes(), ViewMode::name, and viewModes_.

void CoreWidget::slotSetViewModeIcon ( QString  _mode,
QString  _iconName 
) [slot]

Sets the Icon for a given View Mode (non-userdefined viewMode).

Sets the Icon for a given View Mode.

Definition at line 177 of file viewMode.cc.

void CoreWidget::slotShowSceneGraphDialog (  )  [private, slot]

Creates and shows the Scenegraph Dialog

Definition at line 927 of file CoreWidget.cc.

References examiner_widgets_, and PluginFunctions::getSceneGraphRootNode().

Referenced by setupMenuBar().

void CoreWidget::slotSnapshot (  )  [private, slot]

Create a snapshot of the last active examiner.

Take a snapshot of the current Viewer.

Definition at line 231 of file viewerControl.cc.

References PluginFunctions::activeExaminer(), examiner_widgets_, Viewer::ViewerProperties::snapshotBaseFileName(), Viewer::ViewerProperties::snapshotCounter(), and PluginFunctions::viewerProperties().

Referenced by updatePopupMenuCoordsysNode().

void CoreWidget::slotSwitchWheels ( bool  _state  )  [private, slot]

Show / hide wheels.

Show / hide wheels in examiner windows.

Definition at line 120 of file viewerControl.cc.

References examiner_widgets_.

Referenced by setupMenuBar().

void CoreWidget::slotViewModeDialog (  )  [private, slot]

Show a dialog in which the viewMode can be edited.

show dialog for changing ViewMode

Definition at line 256 of file viewMode.cc.

References viewModeWidget::show(), slotAddViewModeComplete(), slotChangeView(), slotRemoveViewMode(), and viewModes_.

Referenced by CoreWidget().

void CoreWidget::toggleFullscreen (  ) 

Set application to Fullscreen and back.

Set viewer to Fullscreen Mode and back

Definition at line 535 of file CoreWidget.cc.

References glView_, and setViewMode().

Referenced by coreKeyPressEvent().

void CoreWidget::toggleLogger (  ) 

Hide or show logging area.

Hide or show logger

Definition at line 622 of file CoreWidget.cc.

References showLogger().

Referenced by coreKeyPressEvent().

void CoreWidget::toggleToolbox (  ) 

Hide or show toolbox area.

Hide or show toolbox

Definition at line 768 of file CoreWidget.cc.

References showToolbox().

Referenced by coreKeyPressEvent().

void CoreWidget::updatePopupMenu ( const QPoint &  _point  )  [private]

check current context and initialize context menu according to this context.

Update the contextmenu for the given position inside an examiner widget

Parameters:
_point Picking position in coordinates of the viewer

This function is called whenever a context menu for the corewidget is requested. It will decide about the current context, collect all menus for plugins and construct the final context menu.

Definition at line 501 of file ContextMenu.cc.

References PluginFunctions::activeExaminer(), contextMenu_, contextSelectionMenu_, examiner_widgets_, ACG::SceneGraph::find_node(), PluginFunctions::getPickedObject(), PluginFunctions::getSceneGraphRootNode(), BaseObject::id(), ACG::SceneGraph::BaseNode::name(), ACG::SceneGraph::PICK_ANYTHING, updatePopupMenuBackground(), updatePopupMenuCoordsysNode(), updatePopupMenuNode(), and updatePopupMenuObject().

Referenced by slotCustomContextMenu().

void CoreWidget::updatePopupMenuBackground ( QMenu *  _menu,
const QPoint &  _point 
) [private]

Update context Menu when background has been clicked on.

This function is called when the background in a viewer has been clicked on. This context menu will show functions which are related to the background of the viewer.

Parameters:
_menu Pointer to the context Menu
_point position in the viewer where the user clicked.

Definition at line 332 of file ContextMenu.cc.

References coordSysMenu_, ACG::SceneGraph::BaseNode::find(), PluginFunctions::getSceneGraphRootNode(), slotSetContextBackgroundColor(), slotUpdateViewerDrawMenu(), updateContextMenuBackground(), updatePopupMenuCoordsysNode(), viewerDrawMenu_, and ACG::SceneGraph::BaseNode::visible().

Referenced by updatePopupMenu().

void CoreWidget::updatePopupMenuCoordsysNode ( QMenu *  _menu,
const int  _part 
) [private]

Update context Menu when Coordsys node has been clicked on.

This function is called when the coordinate system in a viewer has been clicked on. This context menu will show all function relevant for the current view like the projection/viewing direction...

Parameters:
_menu Pointer to the context Menu
_part id of the coordsys part which has been clicked on.

Definition at line 112 of file ContextMenu.cc.

References PluginFunctions::activeExaminer(), examiner_widgets_, glViewer::PERSPECTIVE_PROJECTION, slotContextHomeView(), slotContextSetHomeView(), slotContextSwitchProjection(), slotContextViewAll(), slotCopyView(), slotLocalChangeAnimation(), slotLocalChangeBackFaceCulling(), slotLocalChangeMultisampling(), slotLocalChangeTwoSidedLighting(), slotPasteView(), slotSetViewingDirection(), slotSnapshot(), slotUpdateViewerDrawMenu(), viewerDrawMenu_, and PluginFunctions::viewerProperties().

Referenced by updatePopupMenu(), and updatePopupMenuBackground().

void CoreWidget::updatePopupMenuNode ( QMenu *  _menu,
ACG::SceneGraph::BaseNode _node 
) [private]

Update context Menu when an arbitrary node has been clicked on.

This function is called when a node has been clicked on not belonging to an object. This context menu will show all function relevant for the Node.

Parameters:
_menu Pointer to the context Menu
_node node which has been clicked on.

Definition at line 90 of file ContextMenu.cc.

References ACG::SceneGraph::BaseNode::id(), ACG::SceneGraph::BaseNode::name(), and updateContextMenuNode().

Referenced by updatePopupMenu().

void CoreWidget::updatePopupMenuObject ( QMenu *  _menu,
BaseObjectData _object 
) [private]

Update context Menu an object has been clicked on.

This function is called when an object has been clicked on. This context menu will show all properties for the given object.

Parameters:
_menu Pointer to the context Menu
_objectId Id of the object that has been clicked on.

Definition at line 382 of file ContextMenu.cc.

References contextMenu_, BaseObject::dataType(), BaseObject::id(), typeIcon(), typeName(), and updateContextMenu().

Referenced by updatePopupMenu().

void CoreWidget::viewerSnapshot (  )  [slot]

Create a snapshot of the whole app.

Take a snapshot of all viewers.

Definition at line 481 of file viewerControl.cc.

References PluginFunctions::activeExaminer(), baseLayout_, examiner_widgets_, and QtMultiViewLayout::mode().

Referenced by Core::viewerSnapshot().

void CoreWidget::viewerSnapshotDialog (  )  [slot]

Create a snapshot of the whole app with fileDialog.

Take a snapshot of all viewers.

Definition at line 362 of file viewerControl.cc.

References PluginFunctions::activeExaminer(), baseLayout_, examiner_widgets_, glView_, and QtMultiViewLayout::mode().

Referenced by setupMenuBar().


Member Data Documentation

QMenu* CoreWidget::coordSysMenu_ [private]

Menu which holds the context menu entries for the coordsys node if invisible

Definition at line 727 of file CoreWidget.hh.

Referenced by updatePopupMenuBackground().

Index of current pickMode

Definition at line 1156 of file CoreWidget.hh.

Referenced by clearPickModes(), pickMode(), and updatePickMenu().

std::string CoreWidget::pick_mode_name_ [private]
std::vector<PickMode> CoreWidget::pick_modes_ [private]

The documentation for this class was generated from the following files:

acg pic Project OpenFlipper, ©  Computer Graphics Group, RWTH Aachen. Documentation generated using doxygen .