 |
Index for Section 3 |
|
 |
Alphabetical listing for D |
|
 |
Bottom of page |
|
DtMenuButton(3)
CDE
NAME
DtMenuButton - the MenuButton widget class
SYNOPSIS
#include <Dt/MenuButton.h>
DESCRIPTION
The DtMenuButton widget is a command widget that complements the menu
cascading functionality of an XmCascadeButton widget. As a complement to
the XmCascadeButton widget, DtMenuButton can only be instantiated outside a
MenuPane; the application must use XmCascadeButton widget inside a
MenuPane.
The DtMenuButton widget belongs to a subclass of the XmLabel class.
Visually, the DtMenuButton widget consists of a label string and a menu
glyph. The menu glyph always appears on the right end of the widget and, by
default, is a downward pointing arrow.
The DtMenuButton widget has an implicitly created submenu attached to it.
The submenu is a popup MenuPane and has this DtMenuButton widget as its
parent. The name of the implicitly created submenu is obtained by adding
submenu_ as a prefix to the name of this DtMenuButton widget. The widget ID
of the submenu can be obtained by doing an XtGetValues on the DtNsubMenuId
resource of this DtMenuButton widget. The implicitly created submenu must
not be destroyed by the user of this widget.
The submenu can be popped up by pressing the menu post Button (see the
XmNmenuPost resource of the XmRowColumn (3X) widget) anywhere on the
DtMenuButton widget.
Widget subclassing is not supported for the DtMenuButton widget class.
Classes
The DtMenuButton widget inherits behavior and resources from the Core,
Composite, XmPrimitive and XmLabel classes.
The class pointer is dtMenuButtonWidgetClass.
The class name is DtMenuButtonWidget.
New Resources
The following table defines a set of widget resources used by the
application to specify data. The application 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, the
application must remove the DtN or DtC prefix and use the remaining
letters. To specify one of the defined values for a resource in a
.Xdefaults file, the application must remove the Dt prefix and use the
remaining letters (in either lower case or upper case, but including any
underscores between words). The codes in the access column indicate if the
given resource can be set at creation time (C), set by using XtSetValues
(S), retrieved by using XtGetValues (G), or is not applicable (N/A).
DtMenuButton Resource Set:
_______________________________________________________________________________
Name Class Type Default Access
_______________________________________________________________________________
DtCCallback NULL C
DtNcascadingCallback
XtCallbackList
DtCPixmap Pixmap CSG
DtNcascadePixmap
XmUNSPECIFIED-
_PIXMAP
DtNsubMenuId DtCMenuWidget Widget NULL SG
_______________________________________________________________________________
DtNcascadingCallback
Specifies the list of callbacks that is called before the popping up of
the attached submenu. The reason for the callback is DtCR_CASCADING.
DtNcascadePixmap
Specifies the pixmap displayed as the menu glyph. If no pixmap is
specified, a downward pointing arrow is displayed.
DtNsubMenuId
Specifies the widget ID of the popup MenuPane to be associated with
this DtMenuButton widget. The popup MenuPane must be created with this
DtMenuButton as its parent. This resource cannot be specified at the
time of widget creation. The implicit submenu is automatically
destroyed by DtMenuButton when this resource is set.
Inherited Resources
The DtMenuButton widget inherits behavior and resources from the following
named superclasses. For a complete description of each resource, see the
man page for that superclass.
XmLabel Resource Set:
__________________________________________________________________________________________
Name Class Type Default Access
__________________________________________________________________________________________
String NULL CSG
XmNaccelerator
XmCAccelerator
XmString NULL CSG
XmNacceleratorText
XmCAcceleratorText
XmNalignment XmCAlignment unsigned char dynamic CSG
XmNfontList XmCFontList XmFontList dynamic CSG
Pixmap CSG
XmNlabelInsensitive-
XmCLabelInsensitive-
XmUNSPECIFIED-
Pixmap Pixmap _PIXMAP
Pixmap CSG
XmNlabelPixmap
XmCLabelPixmap
XmUNSPECIFIED-
_PIXMAP
XmCXmString XmString dynamic CSG
XmNlabelString
XmNlabelType XmCLabelType unsigned char XmSTRING CSG
Dimension 0 CSG
XmNmarginBottom
XmCMarginBottom
Dimension 2 CSG
XmNmarginHeight
XmCMarginHeight
XmNmarginLeft XmCMarginLeft Dimension 0 CSG
Dimension 0 CSG
XmNmarginRight
XmCMarginRight
XmNmarginTop XmCMarginTop Dimension 0 CSG
Dimension 2 CSG
XmNmarginWidth
XmCMarginWidth
XmNmnemonic XmCMnemonic KeySym NULL CSG
String XmFONTLIST- CSG
XmNmnemonicCharSet
XmCMnemonicCharSet
_DEFAULT_TAG
Boolean True CSG
XmNrecomputeSize
XmCRecomputeSize
dynamic CSG
XmNstringDirection
XmCStringDirection
XmStringDirection
__________________________________________________________________________________________
XmPrimitive Resource Set:
__________________________________________________________________________________________
Name Class Type Default Access
__________________________________________________________________________________________
XmNbottom- XmCBottom- Pixel dynamic CSG
ShadowColor
ShadowColor
XmNbottom- XmCBottom- Pixmap CSG
XmUNSPECIFIED-
_PIXMAP
ShadowPixmap
ShadowPixmap
XmNforeground XmCForeground Pixel dynamic CSG
XmCCallback NULL C
XmNhelpCallback
XtCallbackList
Pixel dynamic CSG
XmNhighlightColor
XmCHighlightColor
Boolean False CSG
XmNhighlightOnEnter
XmCHighlightOnEnter
Pixmap dynamic CSG
XmNhighlightPixmap
XmCHighlightPixmap
Dimension 0 CSG
XmNhighlightThickness
XmCHighlightThickness
XmNONE CSG
XmNnavigationType
XmCNavigationType
XmNavigationType
Dimension 0 CSG
XmNshadowThickness
XmCShadowThickness
Pixel dynamic CSG
XmNtopShadowColor
XmCTopShadowColor
Pixmap dynamic CSG
XmNtopShadowPixmap
XmCTopShadowPixmap
Boolean False CSG
XmNtraversalOn
XmCTraversalOn
XmNunitType XmCUnitType unsigned char dynamic CSG
XmNuserData XmCUserData XtPointer NULL CSG
__________________________________________________________________________________________
Core Resource Set:
___________________________________________________________________________________________
Name Class Type Default Access
___________________________________________________________________________________________
dynamic CSG
XmNaccelerators
XmCAccelerators
XtAccelerators
XmCSensitive Boolean dynamic G
XmNancestorSensitive
XmNbackground XmCBackground Pixel dynamic CSG
XmCPixmap Pixmap CSG
XmNbackgroundPixmap
XmUNSPECIFIED-
_PIXMAP
Pixel CSG
XmNborderColor
XmCBorderColor
XtDefaultForeground
XmCPixmap Pixmap CSG
XmNborderPixmap
XmUNSPECIFIED-
_PIXMAP
Dimension 0 CSG
XmNborderWidth
XmCBorderWidth
XmNcolormap XmCColormap Colormap dynamic CG
XmNdepth XmCDepth int dynamic CG
XmCCallback NULL C
XmNdestroyCallback
XtCallbackList
XmNheight XmCHeight Dimension dynamic CSG
Boolean True C
XmNinitialResources-
XmCInitialResources-
Persistent Persistent
Boolean True CSG
XmNmappedWhen-
XmCMappedWhen-
Managed Managed
XmNscreen XmCScreen Screen * dynamic CG
XmNsensitive XmCSensitive Boolean True CSG
dynamic CSG
XmNtranslations
XmCTranslations
XtTranslations
XmNwidth XmCWidth Dimension dynamic CSG
XmNx XmCPosition Position 0 CSG
XmNy XmCPosition Position 0 CSG
___________________________________________________________________________________________
Callback Information
A pointer to the following structure is passed to each DtMenuButton
callback:
typedef struct {
int reason;
XEvent *event;
} XmAnyCallbackStruct;
The reason argument indicates why the callback was invoked; it is always
DtCR_CASCADING when the DtNcascadingCallback is issued.
The event argument points to the XEvent that triggered the callback or NULL
if the callback was not triggered by an XEvent.
SEE ALSO
DtCreateMenuButton(3), Core(3X), XmLabel(3X), XmPrimitive(3X),
XmRowColumn(3X), XtGetValues(3Xt), XtSetValues(3Xt).
DtCreateMenuButton(3X); Core, XmLabel, XmPrimitive, XmRowColumn, in the
X/Open CAE Specification, X/Open Motif Toolkit API; XtGetValues,
XtSetValues in the X/Open CAE Specification, X/Open Window Management: X
Toolkit Intrinsics
 |
Index for Section 3 |
|
 |
Alphabetical listing for D |
|
 |
Top of page |
|