'\" t .\" ArrowBuA.sgm /main/11 1996/09/08 20:24:54 rws $ .de P! .fl \!!1 setgray .fl \\&.\" .fl \!!0 setgray .fl \" force out current output buffer \!!save /psv exch def currentpoint translate 0 0 moveto \!!/showpage{}def .fl \" prolog .sy sed -e 's/^/!/' \\$1\" bring in postscript file \!!psv restore . .de pF .ie \\*(f1 .ds f1 \\n(.f .el .ie \\*(f2 .ds f2 \\n(.f .el .ie \\*(f3 .ds f3 \\n(.f .el .ie \\*(f4 .ds f4 \\n(.f .el .tm ? font overflow .ft \\$1 .. .de fP .ie !\\*(f4 \{\ . ft \\*(f4 . ds f4\" ' br \} .el .ie !\\*(f3 \{\ . ft \\*(f3 . ds f3\" ' br \} .el .ie !\\*(f2 \{\ . ft \\*(f2 . ds f2\" ' br \} .el .ie !\\*(f1 \{\ . ft \\*(f1 . ds f1\" ' br \} .el .tm ? font underflow .. .ds f1\" .ds f2\" .ds f3\" .ds f4\" .ta 8n 16n 24n 32n 40n 48n 56n 64n 72n .TH "XmArrowButton" 3 .SH "NAME" \fBXmArrowButton\fP \(em The ArrowButton widget class "XmArrowButton" "widget class" "ArrowButton" .SH "SYNOPSIS" .PP .nf #include .fi .SH "DESCRIPTION" .PP ArrowButton consists of a directional arrow surrounded by a border shadow\&. When it is selected, the shadow changes to give the appearance that the ArrowButton has been pressed in\&. When the ArrowButton is unselected, the shadow reverts to give the appearance that the ArrowButton is released, or out\&. .PP ArrowButton holds the \fBXmQTactivatable\fP trait\&. .SS "Classes" .PP ArrowButton inherits behavior, resources, and traits from the \fBCore\fP and \fBXmPrimitive\fP classes\&. .PP The class pointer is \fBxmArrowButtonWidgetClass\fP\&. .PP The class name is \fBXmArrowButton\fP\&. .SS "New Resources" .PP 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 \fB\&.Xdefaults\fP file, remove the \fBXmN\fP or \fBXmC\fP prefix and use the remaining letters\&. To specify one of the defined values for a resource in a \fB\&.Xdefaults\fP file, remove the \fBXm\fP 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 using \fBXtSetValues\fP (S), retrieved by using \fBXtGetValues\fP (G), or is not applicable (N/A)\&. .PP .TS tab() box; c s s s s l| l| l| l| l. \fBXmArrowButton Resource Set\fP \fBName\fP\fBClass\fP\fBType\fP\fBDefault\fP\fBAccess\fP _____ XmNactivateCallbackXmCCallbackXtCallbackListNULLC _____ XmNarmCallbackXmCCallbackXtCallbackListNULLC _____ XmNarrowDirectionXmCArrowDirectionunsigned charXmARROW_UPCSG _____ XmNdetailShadowThicknessXmCDetailShadowThicknessDimension2CSG _____ XmNdisarmCallbackXmCCallbackXtCallbackListNULLC _____ XmNmultiClickXmCMultiClickunsigned chardynamicCSG _____ .TE .IP "\fBXmNactivateCallback\fP" 10 Specifies a list of callbacks that is called when the ArrowButton is activated\&. To activate the button, press and release \fBBSelect\fP while the pointer is inside the ArrowButton widget\&. Activating the ArrowButton also disarms it\&. The reason sent by this callback is \fBXmCR_ACTIVATE\fP\&. This callback uses the \fBXmQTactivatable\fP trait\&. .IP "\fBXmNarmCallback\fP" 10 Specifies a list of callbacks that is called when the ArrowButton is armed\&. To arm this widget, press \fBBSelect\fP while the pointer is inside the ArrowButton\&. The reason sent by this callback is \fBXmCR_ARM\fP\&. .IP "\fBXmNarrowDirection\fP" 10 Sets the arrow direction\&. The values for this resource are .RS .IP " \(bu" 6 \fBXmARROW_UP\fP .IP " \(bu" 6 \fBXmARROW_DOWN\fP .IP " \(bu" 6 \fBXmARROW_LEFT\fP .IP " \(bu" 6 \fBXmARROW_RIGHT\fP .RE .IP "\fBXmNdetailShadowThickness\fP" 10 Specifies the thickness of the inside arrow shadows\&. The default thickness is 2 pixels\&. .IP "\fBXmNdisarmCallback\fP" 10 Specifies a list of callbacks that is called when the ArrowButton is disarmed\&. To disarm this widget, press and release \fBBSelect\fP while the pointer is inside the ArrowButton\&. The reason for this callback is \fBXmCR_DISARM\fP\&. .IP "\fBXmNmultiClick\fP" 10 If a button click is followed by another button click within the time span specified by the display\&'s multiclick time, and this resource is set to \fBXmMULTICLICK_DISCARD\fP, the second click\&. is not processed\&. If this resource is set to \fBXmMULTICLICK_KEEP\fP, the event is processed and \fIclick_count\fP is incremented in the callback structure\&. When the button is not in a menu, the default value is \fBXmMULTICLICK_KEEP\fP\&. .SS "Inherited Resources" .PP ArrowButton inherits behavior and resources from the superclasses described in the following table\&. For a complete description of each resource, refer to the reference page for that superclass\&. .PP .TS tab() box; c s s s s l| l| l| l| l. \fBXmPrimitive Resource Set\fP \fBName\fP\fBClass\fP\fBType\fP\fBDefault\fP\fBAccess\fP _____ XmNbottomShadowColorXmCBottomShadowColorPixeldynamicCSG _____ XmNbottomShadowPixmapXmCBottomShadowPixmapPixmapXmUNSPECIFIED_PIXMAPCSG _____ XmNconvertCallbackXmCCallbackXtCallbackListNULLC _____ XmNforegroundXmCForegroundPixeldynamicCSG _____ XmNhelpCallbackXmCCallbackXtCallbackListNULLC _____ XmNhighlightColorXmCHighlightColorPixeldynamicCSG _____ XmNhighlightOnEnterXmCHighlightOnEnterBooleanFalseCSG _____ XmNhighlightPixmapXmCHighlightPixmapPixmapdynamicCSG _____ XmNhighlightThicknessXmCHighlightThicknessDimension2CSG _____ XmNlayoutDirectionXmCLayoutDirectionXmDirectiondynamicCG _____ XmNnavigationTypeXmCNavigationTypeXmNavigationTypeXmNONECSG _____ XmNpopupHandlerCallbackXmCCallbackXtCallbackListNULLC _____ XmNshadowThicknessXmCShadowThicknessDimension2CSG _____ XmNtopShadowColorXmCTopShadowColorPixeldynamicCSG _____ XmNtopShadowPixmapXmCTopShadowPixmapPixmapdynamicCSG _____ XmNtraversalOnXmCTraversalOnBooleanTrueCSG _____ XmNunitTypeXmCUnitTypeunsigned chardynamicCSG _____ XmNuserDataXmCUserDataXtPointerNULLCSG _____ .TE .PP .TS tab() box; c s s s s l| l| l| l| l. \fBCore Resource Set\fP \fBName\fP\fBClass\fP\fBType\fP\fBDefault\fP\fBAccess\fP _____ XmNacceleratorsXmCAcceleratorsXtAcceleratorsdynamicCSG _____ XmNancestorSensitiveXmCSensitiveBooleandynamicG _____ XmNbackgroundXmCBackgroundPixeldynamicCSG _____ XmNbackgroundPixmapXmCPixmapPixmapXmUNSPECIFIED_PIXMAPCSG _____ XmNborderColorXmCBorderColorPixelXtDefaultForegroundCSG _____ XmNborderPixmapXmCPixmapPixmapXmUNSPECIFIED_PIXMAPCSG _____ XmNborderWidthXmCBorderWidthDimension0CSG _____ XmNcolormapXmCColormapColormapdynamicCG _____ XmNdepthXmCDepthintdynamicCG _____ XmNdestroyCallbackXmCCallbackXtCallbackListNULLC _____ XmNheightXmCHeightDimensiondynamicCSG _____ XmNinitialResourcesPersistentXmCInitialResourcesPersistentBooleanTrueC _____ XmNmappedWhenManagedXmCMappedWhenManagedBooleanTrueCSG _____ XmNscreenXmCScreenScreen *dynamicCG _____ XmNsensitiveXmCSensitiveBooleanTrueCSG _____ XmNtranslationsXmCTranslationsXtTranslationsdynamicCSG _____ XmNwidthXmCWidthDimensiondynamicCSG _____ XmNxXmCPositionPosition0CSG _____ XmNyXmCPositionPosition0CSG _____ .TE .SS "Callback Information" .PP A pointer to the following structure is passed to each callback: .PP .nf typedef struct { int \fIreason\fP; XEvent \fI* event\fP; int \fIclick_count\fP; } XmArrowButtonCallbackStruct; .fi .IP "\fIreason\fP" 10 Indicates why the callback was invoked\&. .IP "\fIevent\fP" 10 Points to the \fBXEvent\fP that triggered the callback\&. .IP "\fIclick_count\fP" 10 This value is valid only when the reason is \fBXmCR_ACTIVATE\fP\&. It contains the number of clicks in the last multiclick sequence if the \fBXmNmultiClick\fP resource is set to \fBXmMULTICLICK_KEEP\fP; otherwise it contains 1\&. The activate callback is invoked for each click if \fBXmNmultiClick\fP is set to \fBXmMULTICLICK_KEEP\fP\&. .SS "Translations" .PP XmArrowButton includes translations for XmPrimitive\&. The following key names are listed in the X standard key event translation table syntax\&. This format is the one used by Motif to specify the widget actions corresponding to a given key\&. A brief overview of the format is provided under \fBVirtualBindings\fP(3)\&. For a complete description of the format, please refer to the X Toolkit Instrinsics Documentation\&. .IP "\fB\fP:" 10 Enter() .IP "\fB\fP:" 10 Leave() .IP "\fBc\fP:" 10 ButtonTakeFocus() .IP "\fB\(apc\fP\fB\fP:" 10 Arm() .IP "\fB\(apc\fP\fB\fP\fB,\(apc\fP\fB\fP:" 10 Activate() Disarm() .IP "\fB\(apc\fP\fB\fP\fB(2+)\fP:" 10 MultiArm() .IP "\fB\(apc\fP\fB\fP\fB(2+)\fP:" 10 MultiActivate() .IP "\fB\(apc\fP\fB\fP:" 10 Activate() Disarm() .IP "\fB:\fP\fB\fP\fB\fP:" 10 PrimitiveParentActivate() .IP "\fB:\fP\fB\fP\fB\fP:" 10 PrimitiveParentCancel() .IP "\fB:\fP\fB\fP\fB\fP:" 10 ArmAndActivate() .IP "\fB:\fP\fB\fP\fB\fP:" 10 Help() .IP "\fB\(aps \(apm \(apa\fP \fB\fP\fBReturn\fP:" 10 PrimitiveParentActivate() .IP "\fB\(aps \(apm \(apa\fP \fB\fP\fBspace\fP:" 10 ArmAndActivate() .SS "Action Routines" .PP The \fBXmArrowButton\fP action routines are .IP "Activate():" 10 Draws the shadow in the unselected state\&. If the pointer is within the ArrowButton, calls the callbacks for \fBXmNactivateCallback\fP\&. .IP "Arm():" 10 Draws the shadow in the selected state and calls the callbacks for \fBXmNarmCallback\fP\&. .IP "ArmAndActivate():" 10 Draws the shadow in the selected state and calls the callbacks for \fBXmNarmCallback\fP\&. Arranges for the shadow to be drawn in the unselected state and the callbacks for \fBXmNactivateCallback\fP and \fBXmNdisarmCallback\fP to be called, either immediately or at a later time\&. .IP "ButtonTakeFocus():" 10 Causes the ArrowButton to take keyboard focus when \fBCtrl\fP is pressed, without activating the widget\&. .IP "Disarm():" 10 Draws the shadow in the unselected state and calls the callbacks for \fBXmNdisarmCallback\fP\&. .IP "Help():" 10 Calls the callbacks for \fBXmNhelpCallback\fP if any exist\&. If there are no help callbacks for this widget, this action calls the help callbacks for the nearest ancestor that has them\&. .IP "MultiActivate():" 10 If \fBXmNmultiClick\fP is \fBXmMULTICLICK_DISCARD\fP, this action does nothing\&. .IP "" 10 If \fBXmNmultiClick\fP is \fBXmMULTICLICK_KEEP\fP, this action increments \fIclick_count\fP in the callback structure and draws the shadow in the unselected state\&. If the pointer is within the ArrowButton, this action calls the callbacks for \fBXmNactivateCallback\fP and \fBXmNdisarmCallback\fP\&. .IP "MultiArm():" 10 If \fBXmNmultiClick\fP is \fBXmMULTICLICK_DISCARD\fP, this action does nothing\&. If \fBXmNmultiClick\fP is \fBXmMULTICLICK_KEEP\fP, this action draws the shadow in the selected state and calls the callbacks for \fBXmNarmCallback\fP\&. .SS "Additional Behavior" .PP This widget has the following additional behavior: .IP "\fB\fP:" 10 Draws the ArrowButton shadow in its selected state if the pointer leaves and re-enters the window while \fB\fP is pressed\&. .IP "\fB\fP:" 10 Draws the ArrowButton shadow in its unselected state if the pointer leaves the window while \fB\fP is pressed\&. .SS "Virtual Bindings" .PP The bindings for virtual keys are vendor specific\&. For information about bindings for virtual buttons and keys, see \fBVirtualBindings\fP(3)\&. .SH "RELATED" .PP \fBCore\fP(3), \fBXmCreateArrowButton\fP(3), \fBXmPrimitive\fP(3), \fBXmVaCreateArrowButton\fP(3), and \fBXmVaCreateManagedArrowButton\fP(3)\&.