Abstract base class for all Open Inventor components. More...
#include <Inventor/Xt/SoXtComponent.h>
Public Member Functions | |
virtual void | show () |
This shows the component. | |
virtual void | hide () |
This hides the component. | |
SbBool | isVisible () |
Returns TRUE if this component is mapped onto the screen. | |
SoWidget | getWidget () const |
This returns the base widget for this component. | |
SbBool | isTopLevelShell () const |
Returns TRUE if this component is a top level shell component (has its own window). | |
SoWidget | getShellWidget () const |
Returns the shell widget (NULL if the shell hasn't been created by this component). | |
SoWidget | getParentWidget () const |
Returns the parent widget, be it a shell or not. | |
void | setSize (const SbVec2s &size) |
Convenience routine on the widget. | |
SbVec2s | getSize () |
Convenience routine on the widget. | |
SbBool | setFullScreen (const SbBool enable) |
Switches the viewer into (or out of) fullscreen mode. | |
SbBool | isFullScreen (void) const |
Queries if the viewer is in fullscreen mode. | |
void | setFullScreenEnable (const SbBool enable) |
Enables/disables fullscreen mode. | |
SbBool | isFullScreenEnable () const |
Queries if it is possible to put the viewer in fullscreen mode. | |
Display * | getDisplay () |
Returns the X display associated with this components widget. | |
SoNONUNICODE void | setTitle (const char *newTitle) |
Sets window title. | |
void | setTitle (const SbString &newTitle) |
Sets window title. | |
SbString | getTitle () const |
Gets window title. | |
SoNONUNICODE void | setIconTitle (const char *newIconTitle) |
Sets icon title. | |
void | setIconTitle (const SbString &newIconTitle) |
Sets icon title. | |
SbString | getIconTitle () const |
Gets icon title. | |
void | setWindowCloseCallback (SoXtComponentCB *func, void *data=NULL) |
Sets which callback to call when the user closes this component (double click in the upper left corner) - by default hide() is called on this component, unless a callback is set to something other than NULL. | |
SbString | getWidgetName () const |
Returns the widget name. | |
SbString | getClassName () const |
Returns the class name. | |
Static Public Member Functions | |
static void | displayHelp (const char *filename, UINT contextID) |
Static method to display the specified topic of the specified help file. | |
static SoXtComponent * | getComponent (SoWidget w) |
This returns the SoXtComponent for this widget. | |
Abstract base class for all Open Inventor components.
Abstract base class from which all Open Inventor Xt components are derived. This class provides a basic C++ protocol for building and displaying Motif components. Components are used to encapsulate some function or task into a reusable package in the form of a Motif widget that can be used in any Open Inventor Xt program. See the Example section on how to build and use SoXtComponents.
!!------------------------------------------------ !! Xt Component ( For Light and Material Sliders Set ) !!------------------------------------------------ *IvXtComponentTitle.labelString: Xt Component *IvTGSXtComponentTitle.labelString: VSG: Xt Component
SoXt, SoXtRenderArea, SoXtViewer, SoXtMaterialEditor
Definition at line 144 of file SoXtComponent.h.
|
static |
Static method to display the specified topic of the specified help file.
This method can be used when the help file needs to be displayed from a user's application but the pointer to the viewer is not available. For example, in an MFC application where the method used to display the help file is not in the View class. Only a compiled HTML help file (.chm) can be displayed with this method.
|
inline |
Returns the class name.
The class name is predefined by each component.
Definition at line 324 of file SoXtComponent.h.
|
static |
This returns the SoXtComponent for this widget.
If the widget does not match that of any Open Inventor component, then NULL is returned.
|
inline |
Returns the X display associated with this components widget.
Definition at line 491 of file SoXtComponent.h.
|
inline |
Gets icon title.
Definition at line 291 of file SoXtComponent.h.
|
inline |
Returns the parent widget, be it a shell or not.
Definition at line 205 of file SoXtComponent.h.
|
inline |
Returns the shell widget (NULL if the shell hasn't been created by this component).
Definition at line 200 of file SoXtComponent.h.
SbVec2s SoXtComponent::getSize | ( | ) |
Convenience routine on the widget.
|
inline |
Gets window title.
Definition at line 267 of file SoXtComponent.h.
|
inline |
This returns the base widget for this component.
If the component created its own shell, this returns the topmost widget beneath the shell. Call getShellWidget() to obtain the shell.
Definition at line 187 of file SoXtComponent.h.
|
inline |
Returns the widget name.
The widget name is passed to the build method.
Definition at line 317 of file SoXtComponent.h.
|
virtual |
This hides the component.
Reimplemented in SoXtDirectionalLightEditor, SoXtMaterialEditor, and SoXtFullViewer.
SbBool SoXtComponent::isFullScreen | ( | void | ) | const |
Queries if the viewer is in fullscreen mode.
SbBool SoXtComponent::isFullScreenEnable | ( | ) | const |
Queries if it is possible to put the viewer in fullscreen mode.
|
inline |
Returns TRUE if this component is a top level shell component (has its own window).
Subclasses may use this to decide if they are allowed to resize themselves.
Definition at line 194 of file SoXtComponent.h.
SbBool SoXtComponent::isVisible | ( | ) |
Returns TRUE if this component is mapped onto the screen.
For a component to be visible, its widget and the shell containing this widget must be mapped (which is FALSE when the component is iconified).
Subclasses should call this routine before redrawing anything and in any sensor trigger methods. Calling this will check the current visibility (which is really cheap) and invoke the visibility changed callbacks if the state changes (see addVisibilityChangeCallback()).
Switches the viewer into (or out of) fullscreen mode.
void SoXtComponent::setFullScreenEnable | ( | const SbBool | enable | ) |
Enables/disables fullscreen mode.
If fullscreen mode is disabled, it is not possible to activate fullscreen mode with the right mouse button popup menu.
SoNONUNICODE void SoXtComponent::setIconTitle | ( | const char * | newIconTitle | ) |
Sets icon title.
The icon title can be set for topLevelShell components or components which are directly under a shell widget (i.e. components which have their own window).
Non Unicode: This function should not be used in a Unicode application.
void SoXtComponent::setIconTitle | ( | const SbString & | newIconTitle | ) |
Sets icon title.
The icon title can be set for topLevelShell components or components which are directly under a shell widget (i.e. components which have their own window).
void SoXtComponent::setSize | ( | const SbVec2s & | size | ) |
Convenience routine on the widget.
SoNONUNICODE void SoXtComponent::setTitle | ( | const char * | newTitle | ) |
Sets window title.
The window title can be set for topLevelShell components or components which are directly under a shell widget (i.e. components which have their own window).
Non Unicode: This function should not be used in a Unicode application.
void SoXtComponent::setTitle | ( | const SbString & | newTitle | ) |
Sets window title.
The window title can be set for topLevelShell components or components which are directly under a shell widget (i.e. components which have their own window).
|
inline |
Sets which callback to call when the user closes this component (double click in the upper left corner) - by default hide() is called on this component, unless a callback is set to something other than NULL.
A pointer to this class will be passed as the callback data.
Note: this callback is supplied because the user may wish to delete this component when it is closed.
Definition at line 304 of file SoXtComponent.h.
|
virtual |
This shows the component.
Reimplemented in SoXtDirectionalLightEditor, SoXtMaterialEditor, and SoXtSliderSetBase.