Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

dwttogglebuttongadgetcreate(3dwt) [ultrix man page]

DwtToggleButtonGadgetCreate(3Dwt)										 DwtToggleButtonGadgetCreate(3Dwt)

       DwtToggleButtonGadgetCreate - Creates a toggle button gadget.

       Widget DwtToggleButtonGadgetCreate (parent_widget, name,
	    Widget parent_widget;
	    char *name;
	    ArgList override_arglist;
	    int override_argcount;

		 Specifies the parent widget ID.

       name	 Specifies the name of the created widget.

		 Specifies the application override argument list.

		 Specifies the number of attributes in the application override argument list (override_arglist).

       The  DwtToggleButtonGadgetCreate  function  creates an instance of the toggle button gadget and returns its associated gadget ID.  A toggle
       button gadget is similar in appearance and semantics to a toggle button widget.	Like all  gadgets,  DwtToggleButtonGadgetCreate  does  not
       have  a	window	but  uses the window of the closest antecedent widget.	Thus, the antecedent widget provides all event dispatching for the
       gadget.	This currently restricts gadgets to being descendents of menu or dialog class (or subclass) widgets.

Inherited Attributes
       Attribute Name	       Data Type	Default
       Rectangle Attributes
       DwtNx		       Position 	Determined   by
						the    geometry
       DwtNy		       Position 	Determined   by
						the    geometry
       DwtNwidth	       Dimension	The  width   of
						the  label plus
       DwtNheight	       Dimension	The  height  of
						the  label plus
       DwtNborderWidth	       Dimension	zero
       DwtNsensitive	       Boolean		True
       DwtNancestorSensitive   Boolean		The bitwise AND
						of  the  parent
						and  DwtNances-

       Label Attributes

       DwtNlabel	       DwtCompString	Widget name

       DwtNalignment	       unsigned char	DwtAlignment-
       DwtNdirectionRToL       Boolean		False
       DwtNhelpCallback        DwtCallbackPtr	NULL

Widget-Specific Attributes
       Attribute Name		  Data Type	   Default
       DwtNshape		  unsigned char    DwtRectangular
       DwtNvalue		  Boolean	   False
       DwtNvisibleWhenOff	  Boolean	   True
       DwtNvalueChangedCallback   DwtCallbackPtr   NULL
       DwtNbuttonAccelerator	  char *	   NULL
       DwtNacceleratorText	  DwtCompString    NULL

       DwtNshape      Specifies the toggle button indicator shape.  You can pass DwtRectangular or DwtOval.

       DwtNvalue      Specifies a boolean value that, when False, indicates the button state is off.  If True, the button state is on.

		      Specifies a boolean value that, when True, indicates that the toggle button is visible when in the off state.

		      Specifies the callback function or functions called when the toggle button value was changed.  For this callback, the reason
		      is DwtCRValueChanged.

		      Sets an accelerator on a toggle button widget.  This is the same as the DwtNtranslations core attribute except that only the
		      left  side  of  the  table  is to be passed as a character string, not compiled.	The application is responsible for calling
		      XtInstallAllAccelerators to install the accelerator where the application needs it.

		      Specifies the compound-string text displayed for the accelerator.

Return Values
       This function returns the ID of the created widget.

Callback Information
       The following structure is returned to your callback:
       typedef struct {
			       int reason;
			       XEvent *event;
			       int value;
       } DwtTogglebuttonCallbackStruct;

       The reason member is set to a constant that represents the reason why this callback was invoked.  For this callback, the reason member  can
       be set to:

       DwtCRValueChanged    The  user  activated  the
			    toggle button  to  change

       DwtCRHelpRequested   The user selected Help.

       The  event  member  is a pointer to the Xlib structure XEvent, which describes the event that generated this callback.  This structure is a
       union of the individual structures declared for each event type.  For information on XEvent and event processing, see the Guide to the Xlib
       Library: C Language Binding.

       The value member is set to the toggle button's current state when the callback occurred, either True (on) or False (off).

See Also
       Guide to the XUI Toolkit: C Language Binding
       Guide to the XUI Toolkit Intrinsics: C Language Binding

Man Page