SoWinComponent Class |
Abstract base class for all Open Inventor components.
Namespace: OIV.Inventor.Win
The SoWinComponent type exposes the following members.
Name | Description | |
---|---|---|
Equals | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) | |
GetClassName | Returns the class name. | |
GetComponent | Returns the OIV.Inventor.Win.SoWinComponent for this window handle. | |
GetHashCode |
Overrides GetHashCode().
(Inherited from SoNetBase.) | |
GetIconTitle | Included for portability only. | |
GetSize | Convenience routine on the window handle. | |
GetTitle | Gets window title. | |
GetType | Gets the Type of the current instance. (Inherited from Object.) | |
GetWidgetName | Returns the window handle name. | |
Hide | This hides the component. | |
IsFullScreen | Queries if the viewer is in fullscreen mode. | |
IsFullScreenEnable | Queries if it is possible to put the viewer in fullscreen mode. | |
IsTopLevelShell | Returns true if this component is a top level shell component (has its own window). | |
IsVisible | Returns true if this component is mapped onto the screen. | |
SetFullScreen | Switches the viewer into (or out of) fullscreen mode. | |
SetFullScreenEnable | Enables/disables fullscreen mode. | |
SetIconTitle | Included for portability only. | |
SetSize | Convenience routine on the window handle. | |
SetTitle | Sets window title. | |
Show | This shows the component. | |
ToString | Returns a string that represents the current object. (Inherited from Object.) |
Name | Description | |
---|---|---|
Handle |
Implements Handle.
| |
WindowCloseCallback | Sets the delegate to invoke when the user closes this component (double click in the upper left corner) - by default Hide() is called on this component, unless a delegate is specified. |
Abstract base class from which all Open Inventor Windows components are derived. This class provides a basic C++ protocol for building and displaying Windows components. Components are used to encapsulate some function or task into a reusable package in the form of a Windows window handle that can be used in any Open Inventor Windows program. See the Example section on how to build and use SoWinComponents.
This example shows how an Open Inventor component can be built inside a program using the Windows window handle set. The example uses the OIV.Inventor.Win.Viewers.SoWinExaminerViewer window handle to view some simple geometry.
#include <Inventor/Win/SoWin.h> #include <Inventor/nodes/SoCone.h> #include <Inventor/Win/viewers/SoWinExaminerViewer.h> void main(int, char* *argv) HWND myWindow = SoWin.init(argv[0]); SoWinExaminerViewer *myViewer = new SoWinExaminerViewer(myWindow); myViewer->setSceneGraph( new SoCone() ); myViewer->show(); SoWin.show(myWindow); // calls Show() SoWin.mainLoop();