SoMenuBar Class Reference
[Dialog]

VSG extension Menu bar node. More...

#include <DialogViz/dialog/SoMenuBar.h>

Inheritance diagram for SoMenuBar:
SoTopComponent SoDialogViz SoDragger SoInteractionKit SoBaseKit SoNode SoGetView SoFieldContainer SoBase SoRefCounter SoTypedObject

List of all members.

Public Member Functions

 SoMenuBar ()
void addAuditor (SoDialogAuditor *auditor)
void removeAuditor (SoDialogAuditor *auditor)
SoDialogVizsearchForAuditorId (SbString id)
virtual void addChild (SoMenuPopup *child)
virtual void insertChild (SoMenuPopup *child, int newChildIndex)
virtual SoNodegetChild (int index) const
virtual int getNumChildren () const
virtual int findChild (const SoMenuPopup *child) const
virtual void removeChild (int index)
virtual void removeChild (SoMenuPopup *child)
virtual void removeAllChildren ()
virtual void replaceChild (int index, SoMenuPopup *newChild)
virtual void replaceChild (SoMenuPopup *oldChild, SoMenuPopup *newChild)

Detailed Description

VSG extension Menu bar node.

This node defines a menu bar component.

MenuBar.jpg

If several SoMenuBar objects are added to an SoTopLevelDialog, only the first one is used; the others are ignored. An SoMenuBar node consists of a set of SoMenuPopup nodes. You can add, insert, and remove popup menus (SoMenuPopup) by using the addChild(), insertChild(), and removeChild() methods.

You can change the parts in any instance of this menu bar using setPart(). The default part geometries are defined as resources for this SoMenuBar class. They are detailed below in the Catalog Parts section of the online reference page for this class. You can make your program use different default resources for the parts by copying the file $OIVHOME/data/DialogViz/Skins/default/MenuBar.iv into your own directory, editing the file, and then setting the environment variable DIALOGVIZ_SKINS_DIR to be a path to that directory, or by using the setSkinDirectory() method in your application.

FILE FORMAT/DEFAULT

SEE ALSO

SoTopLevelDialog, SoMenuPopup, SoMenuItem

See related examples:

ShowAll, Simple, SetSkin, Simple3DMenu


Constructor & Destructor Documentation

SoMenuBar::SoMenuBar (  ) 

Constructor.


Member Function Documentation

void SoMenuBar::addAuditor ( SoDialogAuditor auditor  ) 

Adds a DialogAuditor to current menu bar component.

virtual void SoMenuBar::addChild ( SoMenuPopup child  )  [virtual]

Adds a child as last one in group.

virtual int SoMenuBar::findChild ( const SoMenuPopup child  )  const [virtual]

Finds index of given child within group.

Returns -1 if not found.

virtual SoNode* SoMenuBar::getChild ( int  index  )  const [virtual]

Returns pointer to child node with the given index.

Reimplemented from SoBaseKit.

virtual int SoMenuBar::getNumChildren (  )  const [virtual]

Returns number of children.

Reimplemented from SoBaseKit.

virtual void SoMenuBar::insertChild ( SoMenuPopup child,
int  newChildIndex 
) [virtual]

Adds a child so that it becomes the one with the given index.

virtual void SoMenuBar::removeAllChildren (  )  [virtual]

Removes all children from group.

Reimplemented from SoBaseKit.

void SoMenuBar::removeAuditor ( SoDialogAuditor auditor  ) 

Removes the specified DialogAuditor from the auditor list.

virtual void SoMenuBar::removeChild ( SoMenuPopup child  )  [virtual]

Removes first instance of given child from group.

virtual void SoMenuBar::removeChild ( int  index  )  [virtual]

Removes child with given index from group.

Reimplemented from SoBaseKit.

virtual void SoMenuBar::replaceChild ( SoMenuPopup oldChild,
SoMenuPopup newChild 
) [virtual]

Replaces first instance of given child with new child.

virtual void SoMenuBar::replaceChild ( int  index,
SoMenuPopup newChild 
) [virtual]

Replaces child with given index with new child.

SoDialogViz* SoMenuBar::searchForAuditorId ( SbString  id  ) 

Retrieves the DialogViz object from the specified auditorID field in an SoMenuBar structure.

NULL is returned if auditorID string is not found.


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

Open Inventor Toolkit reference manual, generated on 12 Feb 2024
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/