Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ olFlatChkBox(3W) — Dell System V Release 4 Issue 2.2

Media Vault

Software Library

Restoration Projects

Artifacts Sought



FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


NAME
      FlatCheckBox -  is a performance improvement over the NonExclusives
      widget that is populated with CheckBox widgets

SYNOPSIS
      #include <Intrinsic.h>
      #include <StringDefs.h>
      #include <OpenLook.h>
      #include <FCheckBox.h>

      widget = XtCreateWidget(name, flatCheckBoxWidgetClass, ...);


DESCRIPTION
   Keyboard Traversal
      The FlatCheckbox widget is a Primitive widget that manages the traversal
      between a set of sub-objects.  When the user traverses to a FlatCheckbox
      widget, the first sub-object in the set will display itself as having
      input focus (see the CheckBox Widget for a description of this
      appearance.)  The MOVEUP, MOVEDOWN, MOVERIGHT, and MOVELEFT keys move the
      input focus between the sub-objects.  To traverse out of the FlatCheckbox
      widget, the following keys can be used:

     - NEXT_FIELD moves to the next traversable widget in the window

     - PREV_FIELD moves to the previous traversable widget in the window

     - NEXTWINDOW moves to the next window in the application.

     - PREVWINDOW moves to the previous window in the application.

     - NEXTAPP moves to the first window in the next application.

     - PREVAPP moves to the first window in the previous application.

   Keyboard Operation
      __________________________________________________
     |          Flat CheckBox Activation Types         |
     |________________|________________________________|
     | Activation Type|  Expected Results              |
     |||









       OL_SELECTKEY      These controls have two
                         states: "set" and "not set".


10/89                                                                    Page 1







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      __________________________________________________
     |          Flat CheckBox Activation Types         |
     |________________|________________________________|
     | Activation Type|  Expected Results              |
     |||
     |                |  (When set, its border is      |
     |                |  thickened.)  Pressing the     |
     |                |  SELECTKEY while a flat        |
     |                |  checkbox item has focus will  |
     |                |  toggle the checkbox's current |
     |                |  state.  If the control is     |
     |                |  "set", then toggling the      |
     |                |  control will call the         |
     |                |  XtNunselect callback list.  If|
     |                |  the control is "not set", then|
     |                |  toggling the control will call|
     |                |  the XtNselect callback list.  |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |                |                                |
     |________________|________________________________|



Page 2                                                                    10/89







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


   Display of Keyboard Mnemonic
      The FlatCheckbox widget displays the mnemonic accelerator of a sub-object
      as part of the sub-object's label.  If the mnemonic character is in the
      label, then that character is highlighted according to the value returned
      by XtNshowMnemonics().  If the mnemonic character is not in the label, it
      is displayed to the right of the label in parenthesis and highlighted
      according to the value returned by XtNshowMnemonics().

      If truncation is necessary, the mnemonic displayed in parenthesis is
      truncated as a unit.

   Display of Keyboard Accelerators
      The FlatCheckbox widget displays the keyboard accelerator as part of the
      sub-object's label.  The string in the XtNacceleratorText resource is
      displayed to the right of the label (or mnemonic) separated by at least
      one space.  The acceleratorText is right justified.

      If truncation is necessary, the accelerator is truncated as a unit.  The
      accelerator is truncated before the mnemonic or the label.

                            Figure 1.  Flat CheckBox Item

   FlatCheckbox Coloration
      The FlatCheckBox container inherits its background color from the
      container's parent widget.  Setting the background color affects only the
      sub-objects' background.

      On a monochrome display, the FlatCheckbox widget indicates that it has
      input focus by inverting the foreground color and parent's background
      colors within the bounding box of the first sub-object.

      On color displays, when the FlatCheckbox widget receives the input focus,
      the background color within the bounding box of the first sub-object is
      changed to the input focus color set in the XtNinputFocusColor resource.
      When the FlatCheckbox sub-object loses the input focus, the background
      color reverts to its parent's XtNbackground color or XtNbackgroundPixmap.

      EXCEPTIONS:

     - If the input focus color is the same as the parent's background color,
        then the FlatCheckbox widget inverts the foreground and background
        colors of the sub-object when it has input focus.

     - If the input focus color is the same as the font color or foreground
        color, then the FlatCheckbox widget inverts the foreground and
        background colors of the sub-object when it has input focus.

RESOURCES


      The following table lists the resources for the FlatCheckBox.  Resources
      that have a bullet (⊕) in the Access column denote sub-object resources.


10/89                                                                    Page 3







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      If these resources are not included in the XtNitemFields list, they are
      inherited from the container widget.  An application can change the
      default values for sub-object resources by setting them directly on the
      container.  Even though a sub-object resource is not included in the
      XtNitemFields list, the application can query the value of any sub-object
      resource with OlFlatGetValues().

      _____________________________________________________________________________________________
     |                                 Flat CheckBox Resource Set                                 |
     |_____________________|______________________|________________|_____________________|________|
     | Name                |  Class               |  Type          |  Default            |  Access|
     ||||||
       XtNaccelerator         XtCAccelerator         String           NULL                  SGI⊕
      _____________________________________________________________________________________________
       XtNacceleratorText     XtCAcceleratorText     String           Dynamic               SGI⊕
      _____________________________________________________________________________________________
       XtNancestorSensitive   XtCSensitive           Boolean          TRUE                  G⊕
      _____________________________________________________________________________________________
       XtNbackground          XtCBackground          Pixel            XtDefaultBackground   SGI⊕
      _____________________________________________________________________________________________
       XtNbackgroundPixmap    XtCBackgroundPixmap    Pixmap           None                  SGI⊕
      _____________________________________________________________________________________________
       XtNborderWidth         XtCBorderWidth         Dimension        0                     SGI⊕
      _____________________________________________________________________________________________
       XtNclientData          XtCClientData          XtPointer        NULL                  SGI⊕
      _____________________________________________________________________________________________
       XtNconsumeEvent        XtCConsumeEvent        XtCallbackList   NULL                  SGI
      _____________________________________________________________________________________________
       XtNdepth               XtCDepth               Cardinal         (parent's)            GI
      _____________________________________________________________________________________________
       XtNfont                XtCFont                XFontStruct *    (OPEN LOOK font)      SI⊕
      _____________________________________________________________________________________________
       XtNfontColor           XtCFontColor           Pixel            XtDefaultForeground   SGI⊕
      _____________________________________________________________________________________________
       XtNforeground          XtCForeground          Pixel            XtDefaultForeground   SGI
      _____________________________________________________________________________________________
       XtNgravity             XtCGravity             int              CenterGravity         SGI
      _____________________________________________________________________________________________
       XtNhPad                XtCHPad                Dimension        0                     SGI
      _____________________________________________________________________________________________
       XtNhSpace              XtCHSpace              Dimension        (calculated)          SGI
      _____________________________________________________________________________________________
       XtNheight              XtCHeight              Dimension        (calculated)          SGI
      _____________________________________________________________________________________________
       XtNinputFocusColor     XtCInputFocusColor     Pixel            Black                 SGI⊕
      _____________________________________________________________________________________________
       XtNitemFields          XtCItemFields          String *         NULL                  GI
      _____________________________________________________________________________________________
       XtNitemGravity         XtCItemGravity         int              NorthWestGravity      SGI
      _____________________________________________________________________________________________
       XtNitemMaxHeight       XtCItemMaxHeight       Dimension        OL_IGNORE             SGI
      _____________________________________________________________________________________________


Page 4                                                                    10/89







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      _____________________________________________________________________________________________
     |                                 Flat CheckBox Resource Set                                 |
     |_____________________|______________________|________________|_____________________|________|
     | Name                |  Class               |  Type          |  Default            |  Access|
     ||||||
       XtNitemMaxWidth        XtCItemMaxWidth        Dimension        OL_IGNORE             SGI
      _____________________________________________________________________________________________
       XtNitemMinHeight       XtCItemMinHeight       Dimension        OL_IGNORE             SGI
      _____________________________________________________________________________________________
       XtNitemMinWidth        XtCItemMinWidth        Dimension        OL_IGNORE             SGI
      _____________________________________________________________________________________________
       XtNitems               XtCItems               XtPointer        NULL                  SGI
      _____________________________________________________________________________________________
       XtNitemsTouched        XtCItemsTouched        Boolean          FALSE                 SG
      _____________________________________________________________________________________________
       XtNlabel               XtCLabel               String           NULL                  SGI⊕
      _____________________________________________________________________________________________
       XtNlabelImage          XtCLabelImage          XImage *         NULL                  SGI⊕
      _____________________________________________________________________________________________
       XtNlabelJustify        XtCLabelJustify        OlDefine         OL_LEFT               SGI⊕
      _____________________________________________________________________________________________
       XtNlabelTile           XtCLabelTile           Boolean          FALSE                 SGI⊕
      _____________________________________________________________________________________________
       XtNlayoutHeight        XtCLayoutHeight        OlDefine         OL_MINIMIZE           SGI
      _____________________________________________________________________________________________
       XtNlayoutType          XtCLayoutType          OlDefine         OL_FIXEDROWS          SGI
      _____________________________________________________________________________________________
       XtNlayoutWidth         XtCLayoutWidth         OlDefine         OL_MINIMIZE           SGI
      _____________________________________________________________________________________________
       XtNmanaged             XtCManaged             Boolean          TRUE                  SGI
      _____________________________________________________________________________________________
       XtNmappedWhenManaged   XtCMappedWhenManaged   Boolean          TRUE                  SGI⊕
      _____________________________________________________________________________________________
       XtNmeasure             XtCMeasure             int              1                     SGI
      _____________________________________________________________________________________________
       XtNmnemonic            XtCMnemonic            unsigned char    NULL                  SGI⊕
      _____________________________________________________________________________________________
       XtNnumItemFields       XtCNumItemFields       Cardinal         0                     SGI
      _____________________________________________________________________________________________
       XtNnumItems            XtCNumItems            Cardinal         0                     SGI
      _____________________________________________________________________________________________
       XtNposition            XtCPosition            OlDefine         OL_LEFT               SGI⊕
      _____________________________________________________________________________________________
       XtNreferenceName       XtCReferenceName       String           NULL                  SGI
      _____________________________________________________________________________________________
       XtNreferenceWidget     XtCReferenceWidget     Widget           NULL                  SGI
      _____________________________________________________________________________________________
       XtNsameHeight          XtCSameHeight          OlDefine         OL_ALL                SGI
      _____________________________________________________________________________________________
       XtNsameWidth           XtCSameWidth           OlDefine         OL_COLUMNS            SGI
      _____________________________________________________________________________________________
       XtNselectProc          XtCCallbackProc        XtCallbackProc   NULL                  SGI⊕


10/89                                                                    Page 5







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      _____________________________________________________________________________________________
     |                                 Flat CheckBox Resource Set                                 |
     |_____________________|______________________|________________|_____________________|________|
     | Name                |  Class               |  Type          |  Default            |  Access|
     ||||||
     |_____________________|______________________|________________|_____________________|________|
     | XtNsensitive        |  XtCSensitive        |  Boolean       |  TRUE               |  SGI⊕  |
     |_____________________|______________________|________________|_____________________|________|
     | XtNset              |  XtCSet              |  Boolean       |  FALSE              |  SGI†⊕ |
     |_____________________|______________________|________________|_____________________|________|
     | XtNtraversalOn      |  XtCTraversalOn      |  Boolean       |  TRUE               |  SGI⊕  |
     |_____________________|______________________|________________|_____________________|________|
     | XtNunselectProc     |  XtCCallbackProc     |  XtCallbackProc|  NULL               |  SGI⊕  |
     |_____________________|______________________|________________|_____________________|________|
     | XtNuserData         |  XtCUserData         |  XtPointer     |  NULL               |  SGI⊕  |
     |_____________________|______________________|________________|_____________________|________|
     | XtNvPad             |  XtCVPad             |  Dimension     |  0                  |  SGI   |
     |_____________________|______________________|________________|_____________________|________|
     | XtNvSpace           |  XtCVSpace           |  Dimension     |  (calculated)       |  SGI   |
     |_____________________|______________________|________________|_____________________|________|
     | XtNwidth            |  XtCWidth            |  Dimension     |  (calculated)       |  SGI   |
     |_____________________|______________________|________________|_____________________|________|
     | XtNx                |  XtCPosition         |  Position      |  0                  |  SGI   |
     |_____________________|______________________|________________|_____________________|________|
     | XtNy                |  XtCPosition         |  Position      |  0                  |  SGI   |
     |_____________________|______________________|________________|_____________________|________|

   XtNancestorSensitive
      Range of Values:
                           TRUE/"true"
                           FALSE/"false"

      This resource indicates the sensitivity of the sub-object's ancestors.
      If TRUE, all the sub-object's ancestors are sensitive and the sub-object
      is sensitive to user input. If FALSE, one or more of the sub-object's
      ancestors are insensitive, so the sub-object displays an inactive visual
      and is not sensitive to user input.

   XtNbackground
      This is the pixel color used to fill in the background of the check box.

   XtNbackgroundPixmap
      This resource specifies the pixmap that is displayed as the sub-object's
      label.  Any supplied pixmap must have the same depth as the flat widget's
      depth.  Pixmaps of None and ParentRelative are not considered valid
      values.  If either XtNlabel or XtNlabelImage has a non-NULL value, this
      resource is ignored.



   XtNclientData
      This is the client data supplied to all callback procedures.


Page 6                                                                    10/89







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


   XtNfont
      This resource displays the string specified by the XtNlabel resource.

   XtNfontColor
      This resource specifies the foreground color of the sub-object's label,
      even if the label is an XImage.

   XtNforeground
      This is the pixel color used when drawing the check box and the check
      within the check box.

   XtNitems
      This is the list of sub-object items.  This value must point to a static
      list since flat containers reference this list after initialization but
      do not cache its information.

   XtNitemFields
      This is the list of resource names used to parse the records in the
      XtNitems list. This resource does not have to point to static information
      since the flat container does not use this information after
      initialization.  Though the flat container does not reference this
      resource's value after initialization, it holds onto it for responding to
      an XtGetValues() request and supplying it in the OlFlatCallData structure
      during callbacks.  Therefore, if the application plans on querying this
      resource, it's recommended that the application make this resource point
      to static information.

   XtNitemsTouched
      Range of Values:
                           TRUE
                           FALSE

      Whenever the application modifies an item list directly, it must supply
      this resource (with a value of TRUE) to the flat widget container so that
      the container can update the visual.  If the resource value is supplied,
      the flat widget container treats its current item list as a new list and
      hence, updates its entire visual.  Since the list is treated as a new
      list, the flat container may request a change in geometry from its
      parent.

      Note:
      It is not necessary to use this resource if the application modifies the
      list with the OlFlatSetValues procedure; nor is it necessary to use this
      resource whenever the application supplies a new list to the flat
      container.



   XtNlabel
      This is the text string that appears in the sub-object.




10/89                                                                    Page 7







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


   XtNlabelImage
      This is an XImage pointer that can appear in a sub-object.  This resource
      is ignored if XtNlabel is non-NULL.

   XtNlabelJustify
      Range of Values:
                           OL_LEFT/"left"
                           OL_CENTER/"center"
                           OL_RIGHT/"right"

      This resource specifies the justification of the label or XImage that
      appears within a sub-object.

   XtNlabelTile
      Range of Values:
                           TRUE
                           FALSE

      This resource augments the XtNlabelImage/XtNlabelPixmap resource to allow
      tiling of the sub-object's background.  For an image/pixmap that is
      smaller than the sub-object's background, the label area is tiled with
      the image/pixmap to fill the sub-object's background if this resource is
      TRUE; otherwise, the label is placed as described by the XtNlabelJustify
      resource.

      The XtNlabelTile resource is ignored for text labels.

   XtNmappedWhenManaged
      Range of Values:
                           TRUE/"true"
                           FALSE/"false"

      This resource specifies whether or not a managed sub-object is displayed.
      Regardless of this resource's value, all managed sub-objects will be
      included when determining the layout.

      Note:
      This resource is never inherited from the container, so its default value
      is always TRUE.

   XtNnumItems
      This resource specifies the number of sub-object items.

   XtNnumItemFields
      This resource indicates the number of resource names contained in
      XtNitemFields.


   XtNposition
      Range of Values:
                           OL_LEFT/"left"
                           OL_RIGHT/"right"


Page 8                                                                    10/89







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      This resource determines on which side of the check box the label is to
      be placed.  The value of OL_LEFT or OL_RIGHT indicates the label is
      placed to the left or to the right of the check box, respectively.

   XtNsameHeight
      Range of Values:
                           OL_ALL/"all"
                           OL_ROWS/"rows"
                           OL_NONE/"none"

      This resource specifies the rows that are forced to the same height.

    XtNsameWidth
      Range of Values:
                           OL_ALL/"all"
                           OL_COLUMNS/"columns"
                           OL_NONE/"none"

      This resource specifies the columns that are forced to the same width.

   XtNselectProc
      This callback procedure is called whenever the sub-object becomes
      selected by user input.

   XtNsensitive
      Range of Values:
                           TRUE/"true"
                           FALSE/"false"

      If TRUE, the sub-object is sensitive to user input.  If FALSE, the sub-
      object is insensitive to user input and an inactive visual is displayed
      to indicate this state.

      Note:
      This resource is never inherited from the container, so its default value
      is always TRUE.

   XtNset
      Range of Values:
                           TRUE/"true"
                           FALSE/"false"

      This resource reflects the current state of the sub-object.

      Note:
      This resource is never inherited from the container, so its default value
      is always FALSE.



      Even if the application does not use XtNset in its item fields list, the
      container will correctly maintain the set item and the application can


10/89                                                                    Page 9







FlatCheckBox(3W)                 UNIX System V                 FlatCheckBox(3W)


      change the set item via OlFlatSetValues.

   XtNunselectProc
      This callback procedure is called whenever the sub-object becomes
      unselected by user input.

















































Page 10                                                                   10/89





Typewritten Software • bear@typewritten.org • Edmonds, WA 98026