SoTopLevelDialog Class Reference
[Dialog]

VSG extension Top Level Dialog node. More...

#include <DialogViz/dialog/SoTopLevelDialog.h>

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

List of all members.

Public Types

enum  ScrollVisibility {
  NEVER,
  ALWAYS,
  AUTO
}

Public Member Functions

 SoTopLevelDialog ()
void buildDialog (SoWidget parent, SbBool buildInsideParent=FALSE)
void close ()
virtual void show ()
virtual void hide ()
void addAuditor (SoDialogAuditor *auditor)
void removeAuditor (SoDialogAuditor *auditor)
void applyAuditors ()
SoDialogVizsearchForAuditorId (SbString id)
virtual void addChild (SoTopComponent *child)
virtual void insertChild (SoTopComponent *child, int newChildIndex)
virtual SoNodegetChild (int index) const
virtual int getNumChildren () const
virtual int findChild (const SoTopComponent *child) const
virtual void removeChild (int index)
virtual void removeChild (SoTopComponent *child)
virtual void removeAllChildren ()
virtual void replaceChild (int index, SoTopComponent *newChild)
virtual void replaceChild (SoTopComponent *oldChild, SoTopComponent *newChild)

Public Attributes

SoSFInt32 width
SoSFInt32 height
SoSFVec2i32 position
SoSFVec3f position3D
SoSFVec3f minimized3DPosition
SoSFBool resizable
SoSFBool minimized
SoSFBool independentMinimizedPosition
SoSFInt32 minWidth
SoSFInt32 maxWidth
SoSFInt32 minHeight
SoSFInt32 maxHeight
SoSFInt32 margin
SoSFInt32 rowSpacing
SoSFEnum vScrollVisibility
SoSFEnum hScrollVisibility
SoSFBool windowResizedByChildren
SoSFBool modalFrame
SoSFBool hideChildren

Detailed Description

VSG extension Top Level Dialog node.

The SoTopLevelDialog class manages a list of SoTopComponent children. Typically, a top level component is composed of at most one SoMenuBar and a set of SoDialogComponents. You can add, insert, and remove top components (SoTopComponent) by using the addChild(), insertChild(), and removeChild() methods.

The SoTopLevelDialog components has numerous sizing constraints. In fact, the user can define the width and height of the dialog window, and can also add size limits to it using the fields minWidth, minHeight, maxWidth, and maxHeight. The limits will be considered when the resizable field is set to TRUE. Otherwise, the size of the window is static and the minimize and maximize title bar buttons are removed on Windows systems.

Note: While 2D rendering, when triggering the window close button, the window is only hidden. If this dialog is the main window of an application (i.e., buildInsideParent parameter has been defined as TRUE), the dialog window is destroyed and the application is ended. Otherwise, the dialog window is not destroyed until closeDialog() is called.

You can change the parts in any instance of this top level component using setPart(). The default part geometries are defined as resources for this SoTopLevelDialog 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/TopLevelDialog.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

SoTopComponent, SoMenuBar, SoDialogComponent

See related examples:

MultiViewers, ShowAll, Simple, SetSkin, Simple3DMenu


Member Enumeration Documentation

Enumerator:
NEVER 

Scroll bar never displayed.

ALWAYS 

Scroll bar always visible.

AUTO 

Automatic scroll bar: displayed when needed (default).


Constructor & Destructor Documentation

SoTopLevelDialog::SoTopLevelDialog (  ) 

Constructor.


Member Function Documentation

void SoTopLevelDialog::addAuditor ( SoDialogAuditor auditor  ) 

Adds a dialogAuditor to the current topLevelDialog component.

virtual void SoTopLevelDialog::addChild ( SoTopComponent child  )  [virtual]

Adds a child as last one in group.

void SoTopLevelDialog::applyAuditors (  ) 

Applies all DialogAuditors in the auditor list.

void SoTopLevelDialog::buildDialog ( SoWidget  parent,
SbBool  buildInsideParent = FALSE 
)

Builds the dialog window.

If buildInsideParent is set to FALSE, a window is created; its title is the field label of SoDialogViz. If buildInsideParent is set to TRUE, the dialog is created inside the parent window.

void SoTopLevelDialog::close (  ) 

Destroys the dialog window.

virtual int SoTopLevelDialog::findChild ( const SoTopComponent child  )  const [virtual]

Finds index of given child within group.

Returns -1 if not found.

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

Returns pointer to child node with the given index.

Reimplemented from SoBaseKit.

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

Returns number of children.

Reimplemented from SoBaseKit.

virtual void SoTopLevelDialog::hide (  )  [virtual]

Hides the topLevelDialog widget.

virtual void SoTopLevelDialog::insertChild ( SoTopComponent child,
int  newChildIndex 
) [virtual]

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

virtual void SoTopLevelDialog::removeAllChildren (  )  [virtual]

Removes all children from group.

Reimplemented from SoBaseKit.

void SoTopLevelDialog::removeAuditor ( SoDialogAuditor auditor  ) 

Removes the defined DialogAuditor from the auditor list.

virtual void SoTopLevelDialog::removeChild ( SoTopComponent child  )  [virtual]

Removes first instance of given child from group.

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

Removes child with given index from group.

Reimplemented from SoBaseKit.

virtual void SoTopLevelDialog::replaceChild ( SoTopComponent oldChild,
SoTopComponent newChild 
) [virtual]

Replaces first instance of given child with new child.

virtual void SoTopLevelDialog::replaceChild ( int  index,
SoTopComponent newChild 
) [virtual]

Replaces child with given index with new child.

SoDialogViz* SoTopLevelDialog::searchForAuditorId ( SbString  id  ) 

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

NULL is returned if auditorID string is not found.

virtual void SoTopLevelDialog::show (  )  [virtual]

Shows the tolLevelDialog widget.


Member Data Documentation

Preferred height of the top component.

Default is zero. The default value zero indicates that the height of the top component will be computed automatically according to its content.

When rendering DialogViz as a scene, children can be hidden while the SoTopLevelDialog frame is moving by setting this field to TRUE.

(Default is FALSE). Hiding children during moves is recommended in order to preserve the frame rate while moving. This is all the more useful when the 3D DialogViz window is complex. Note: This field is not used in 2D mode.

Controls how horizontal scrollbar appears.

Default value is AUTO.

Indicates whether minimized and full size dialog have independant 3D position or not.

Default is TRUE. NOTE: field available since Open Inventor 8.1

Margin width.

Default is zero.

Maximum top component height.

Default is zero. The default value zero indicates no minimum value is specified.

Maximum top component width.

Default is zero. The default value zero indicates no minimum value is specified.

Minimum top component height.

Default is zero. The default value zero indicates no minimum value is specified.

Controls and indicates whether the dialog is minimized or not.

Default is FALSE. NOTE: field available since Open Inventor 8.1

Window world coordinate position when rendering in 3D and minimized.

Minimum top component width.

Default is zero. The default value zero indicates no minimum value is specified.

Sets window property.

If TRUE, the window will have a border and title bar but will not be resizeable. Default is FALSE.

Window screen coordinates.

Default position is (0,0).

Window world coordinate position when rendering in 3D.

Default is (0,0,0).

Indicates if the top component can be resized or not, Default is TRUE.

Space between each child.

Default is zero.

Controls how vertical scrollbar appears.

Default value is AUTO.

Preferred width of the top component.

Default is zero. The default value zero indicates that the width of the top component will be computed automatically according to its content.

Controls the window sizing when a child is added or removed.

If FALSE, the window is not resized; scrollbars appear if needed. Default is FALSE.


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

Open Inventor Toolkit reference manual, generated on 15 Mar 2023
Copyright © Thermo Fisher Scientific All rights reserved.
http://www.openinventor.com/