XmMainWindow(3X) UNIX System V XmMainWindow(3X)
NAME
XmMainWindow - the MainWindow widget class.
SYNOPSIS
#include <Xm/MainW.h>
DESCRIPTION
MainWindow provides a standard layout for the primary window of an
application. This layout includes a MenuBar, a CommandWindow, a work
region, a MessageWindow, and ScrollBars. Any or all of these areas are
optional. The work region and ScrollBars in the MainWindow behave
identically to the work region and ScrollBars in the ScrolledWindow
widget. The user can think of the MainWindow as an extended
ScrolledWindow with an optional MenuBar and optional CommandWindow and
MessageWindow.
In a fully-loaded MainWindow, the MenuBar spans the top of the window
horizontally. The CommandWindow spans the MainWindow horizontally just
below the MenuBar, and the work region lies below the CommandWindow. The
MessageWindow is is below the work region. Any space remaining below the
MessageWindow is managed in a manner identical to ScrolledWindow. The
behavior of ScrolledWindow can be controlled by the ScrolledWindow
resources. To create a MainWindow, first create the work region
elements, a MenuBar, a CommandWindow, a MessageWindow, a horizontal
ScrollBar, and a vertical ScrollBar widget, and then call
XmMainWindowSetAreas with those widget IDs.
MainWindow can also create three Separator widgets that provide a visual
separation of MainWindow's four components.
Classes
MainWindow inherits behavior and resources from Core, Composite,
Constraint, XmManager, and ScrolledWindow classes.
The class pointer is xmMainWindowWidgetClass.
The class name is XmMainWindow.
New Resources
The following table defines a set of widget resources used by the
programmer to specify data. The programmer can also set the resource
values for the inherited classes to set attributes for this widget. To
reference a resource by name or by class in a .Xdefaults file, remove the
XmN or XmC prefix and use the remaining letters. To specify one of the
defined values for a resource in a .Xdefaults file, remove the Xm prefix
and use the remaining letters (in either lowercase or uppercase, but
include any underscores between words). The codes in the access column
indicate if the given resource can be set at creation time (C), set by
10/89 Page 1
XmMainWindow(3X) UNIX System V XmMainWindow(3X)
using XtSetValues (S), retrieved by using XtGetValues (G), or is not
applicable (N/A).
___________________________________________________________________________________________________
| XmMainWindow Resource Set |
|_________________________|___________________________|_______________|__________________|________|
|Name | Class | Type | Default | Access|
|_________________________|___________________________|_______________|__________________|________|
|_________________________|___________________________|_______________|__________________|________|
|XmNcommandWindow | XmCCommandWindow | Widget | NULL | CSG |
|_________________________|___________________________|_______________|__________________|________|
|XmNcommandWindowLocation | XmCCommandWindowLocation | unsigned char| ABOVE (SeeDesc.)| CG |
|_________________________|___________________________|_______________|__________________|________|
|XmNmainWindowMarginHeight| XmCMainWindowMarginHeight| Dimension | 0 | CSG |
|_________________________|___________________________|_______________|__________________|________|
|XmNmainWindowMarginWidth | XmCMainWindowMarginWidth | Dimension | 0 | CSG |
|_________________________|___________________________|_______________|__________________|________|
|XmNmenuBar | XmCMenuBar | Widget | NULL | CSG |
|_________________________|___________________________|_______________|__________________|________|
|XmNmessageWindow | XmCMessageWindow | Widget | NULL | CSG |
|_________________________|___________________________|_______________|__________________|________|
|XmNshowSeparator | XmCShowSeparator | Boolean | False | CSG |
|_________________________|___________________________|_______________|__________________|________|
XmNcommandWindow
Specifies the widget to be laid out as the CommandWindow. This
widget must have been previously created and managed as a child of
MainWindow.
XmNcommandWindowLocation
Controls the position of the command window.
XmCOMMAND_ABOVE_WORKSPACE locates the command window between the
menu bar and the work window. XmCOMMANDBELOWWORKSPACE locates
the command window between the work window and the message window.
XmNmainWindowMarginHeight
Specifies the margin height on the top and bottom of MainWindow.
This resource overrides any setting of the ScrolledWindow resource
XmNscrolledWindowMarginHeight.
XmNmainWindowMarginWidth
Specifies the margin width on the right and left sides of
MainWindow. This resource overrides any setting of the
ScrolledWindow resource XmNscrolledWindowMarginWidth.
XmNmenuBar
Specifies the widget to be laid out as the MenuBar. This widget
must have been previously created and managed as a child of
MainWindow.
Page 2 10/89
XmMainWindow(3X) UNIX System V XmMainWindow(3X)
XmNmessageWindow
Specifies the widget to be laid out as the MessageWindow. This
widget must have been previously created and managed as a child of
MainWindow. The MessageWindow is positioned at the bottom of the
MainWindow. If this value is NULL, no message window is included
in the MainWindow.
XmNshowSeparator
Displays separators between the components of the MainWindow when
set to True. If set to False, no separators are displayed.
Inherited Resources
MainWindow inherits behavior and resources from the following
superclasses. For a complete description of each resource, refer to the
man page for that superclass.
________________________________________________________________________________________________________________
| XmScrolledWindow Resource Set |
|_____________________________|_______________________________|_______________|_______________________|________|
|Name | Class | Type | Default | Access|
|_____________________________|_______________________________|_______________|_______________________|________|
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNclipWindow | XmCClipWindow | Widget | dynamic | G |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNhorizontalScrollBar | XmCHorizontalScrollBar | Widget | dynamic | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNscrollBarDisplayPolicy | XmCScrollBarDisplayPolicy | unsigned char| dynamic | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNscrollBarPlacement | XmCScrollBarPlacement | unsigned char| XmBOTTOM_RIGHT | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNscrolledWindowMarginHeight| XmCScrolledWindowMarginHeight| Dimension | 0 | N/A |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNscrolledWindowMarginWidth | XmCScrolledWindowMarginWidth | Dimension | 0 | N/A |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNscrollingPolicy | XmCScrollingPolicy | unsigned char| XmAPPLICATION_DEFINED| CG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNspacing | XmCSpacing | Dimension | 4 | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNverticalScrollBar | XmCVerticalScrollBar | Widget | dynamic | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNvisualPolicy | XmCVisualPolicy | unsigned char| dynamic | CG |
|_____________________________|_______________________________|_______________|_______________________|________|
|XmNworkWindow | XmCWorkWindow | Widget | NULL | CSG |
|_____________________________|_______________________________|_______________|_______________________|________|
10/89 Page 3
XmMainWindow(3X) UNIX System V XmMainWindow(3X)
_________________________________________________________________________________________________________
| XmManager Resource Set |
|_____________________|_____________________________|___________________|______________________|________|
|Name | Class | Type | Default | Access|
|_____________________|_____________________________|___________________|______________________|________|
|_____________________|_____________________________|___________________|______________________|________|
|XmNbottomShadowColor | XmCBottomShadowColor | Pixel | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNbottomShadowPixmap| XmCBottomShadowPixmap | Pixmap | XmUNSPECIFIED_PIXMAP| CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNforeground | XmCForeground | Pixel | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNhelpCallback | XmCCallback | XtCallbackList | NULL | C |
|_____________________|_____________________________|___________________|______________________|________|
|XmNhighlightColor | XmCHighlightColor | Pixel | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNhighlightPixmap | XmCHighlightPixmap | Pixmap | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNnavigationType | XmCNavigationType | XmNavigationType | XmTAB_GROUP | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNshadowThickness | XmCShadowThickness | Dimension | 0 | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNstringDirection | XmCStringDirection | XmStringDirection| dynamic | CG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNtopShadowColor | XmCBackgroundTopShadowColor| Pixel | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNtopShadowPixmap | XmCTopShadowPixmap | Pixmap | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNtraversalOn | XmCTraversalOn | Boolean | True | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNunitType | XmCUnitType | unsigned char | dynamic | CSG |
|_____________________|_____________________________|___________________|______________________|________|
|XmNuserData | XmCUserData | Pointer | NULL | CSG |
|_____________________|_____________________________|___________________|______________________|________|
_______________________________________________________________________
| Composite Resource Set |
|__________________|___________________|____________|_________|________|
| Name | Class | Type | Default| Access|
|__________________|___________________|____________|_________|________|
|__________________|___________________|____________|_________|________|
| XmNchildren | XmCReadOnly | WidgetList| NULL | G |
|__________________|___________________|____________|_________|________|
| XmNinsertPosition| XmCInsertPosition| (*)() | NULL | CSG |
|__________________|___________________|____________|_________|________|
| XmNnumChildren | XmCReadOnly | Cardinal | 0 | G |
|__________________|___________________|____________|_________|________|
Page 4 10/89
XmMainWindow(3X) UNIX System V XmMainWindow(3X)
________________________________________________________________________________________________________________
| Core Resource Set |
|_____________________________|_______________________________|________________|______________________|________|
|Name | Class | Type | Default | Access|
|_____________________________|_______________________________|________________|______________________|________|
|_____________________________|_______________________________|________________|______________________|________|
|XmNaccelerators | XmCAccelerators | XtAccelerators| dynamic | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNancestorSensitive | XmCSensitive | Boolean | dynamic | G |
|_____________________________|_______________________________|________________|______________________|________|
|XmNbackground | XmCBackground | Pixel | dynamic | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNbackgroundPixmap | XmCPixmap | Pixmap | XmUNSPECIFIED_PIXMAP| CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNborderColor | XmCBorderColor | Pixel | XtDefaultForeground | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNborderPixmap | XmCPixmap | Pixmap | XmUNSPECIFIED_PIXMAP| CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNborderWidth | XmCBorderWidth | Dimension | 0 | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNcolormap | XmCColormap | Colormap | dynamic | CG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNdepth | XmCDepth | int | dynamic | CG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNdestroyCallback | XmCCallback | XtCallbackList| NULL | C |
|_____________________________|_______________________________|________________|______________________|________|
|XmNheight | XmCHeight | Dimension | dynamic | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNinitialResourcesPersistent| XmCInitialResourcesPersistent| Boolean | True | C |
|_____________________________|_______________________________|________________|______________________|________|
|XmNmappedWhenManaged | XmCMappedWhenManaged | Boolean | True | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNscreen | XmCScreen | Screen * | dynamic | CG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNsensitive | XmCSensitive | Boolean | True | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNtranslations | XmCTranslations | XtTranslations| dynamic | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNwidth | XmCWidth | Dimension | dynamic | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNx | XmCPosition | Position | 0 | CSG |
|_____________________________|_______________________________|________________|______________________|________|
|XmNy | XmCPosition | Position | 0 | CSG |
|_____________________________|_______________________________|________________|______________________|________|
Translations
MainWindow inherits translations from ScrolledWindow.
RELATED INFORMATION
Composite(3X), Constraint(3X), Core(3X), XmCreateMainWindow(3X),
XmMainWindowSep1(3X), XmMainWindowSep2(3X), XmMainWindowSep3(3X),
10/89 Page 5
XmMainWindow(3X) UNIX System V XmMainWindow(3X)
XmMainWindowSetAreas(3X), XmManager(3X), and XmScrolledWindow(3X)
Page 6 10/89