home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cato / Xm / XmVaCreateSimplePulldownMenu.z / XmVaCreateSimplePulldownMenu
Encoding:
Text File  |  2002-10-03  |  15.1 KB  |  331 lines

  1.  
  2.  
  3.  
  4.      XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnUUUUuuuuNNNN((((IIII3333XXXXXXXX))))SSSSyyyyssssXXXXttttmmmmeeeeVVVVmmmmaaaaCCCCVVVVrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX))))
  5.  
  6.  
  7.  
  8.      NNNNAAAAMMMMEEEE
  9.           XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu - A RowColumn widget
  10.           convenience creation function
  11.  
  12.      SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  13.           ####iiiinnnncccclllluuuuddddeeee <<<<XXXXmmmm////RRRRoooowwwwCCCCoooolllluuuummmmnnnn....hhhh>>>>
  14.  
  15.           WWWWiiiiddddggggeeeetttt XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu ((((_p_a_r_e_n_t, _n_a_m_e, _p_o_s_t__f_r_o_m__b_u_t_t_o_n,
  16.                     _c_a_l_l_b_a_c_k, _a_r_g...))))
  17.                WWWWiiiiddddggggeeeetttt    _p_a_r_e_n_t;;;;
  18.                SSSSttttrrrriiiinnnngggg    _n_a_m_e;;;;
  19.                iiiinnnntttt       _p_o_s_t__f_r_o_m__b_u_t_t_o_n;;;;
  20.                XXXXttttCCCCaaaallllllllbbbbaaaacccckkkkPPPPrrrroooocccc_c_a_l_l_b_a_c_k;;;;
  21.  
  22.  
  23.      VVVVEEEERRRRSSSSIIIIOOOONNNN
  24.           This page documents version 1.2 of the Motif library.
  25.  
  26.      DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  27.           XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu creates an instance of a
  28.           RowColumn widget of type XXXXmmmmMMMMEEEENNNNUUUU____PPPPUUUULLLLLLLLDDDDOOOOWWWWNNNN and returns the
  29.           associated widget ID.  This routine uses the ANSI C
  30.           variable-length argument list (varargs) calling convention.
  31.  
  32.           This routine creates a Pulldown MenuPane and its button
  33.           children.  The name of each button is button__n, where _n is
  34.           an integer from 0 to one minus the number of buttons in the
  35.           menu.  The name of each separator is separator__n, where _n is
  36.           an integer from 0 to one minus the number of separators in
  37.           the menu.  The name of each title is label__n, where _n is an
  38.           integer from 0 to one minus the number of titles in the
  39.           menu.  Buttons, separators, and titles are named and created
  40.           in the order in which they are specified in the variable
  41.           portion of the argument list.
  42.  
  43.           This routine also attaches the PulldownMenu to a
  44.           CascadeButton or CascadeButtonGadget in the parent.  The
  45.           PulldownMenu is then posted from this button.
  46.  
  47.  
  48.           _p_a_r_e_n_t Specifies the widget ID of the parent of the
  49.                  MenuShell.
  50.  
  51.           _n_a_m_e   Specifies the name of the created widget.
  52.  
  53.           _p_o_s_t__f_r_o_m__b_u_t_t_o_n
  54.                  Specifies the CascadeButton or CascadeButtonGadget in
  55.                  the parent to which the Pulldown MenuPane is
  56.                  attached.  The value is the integer _n that
  57.                  corresponds to the _nth CascadeButton or
  58.                  CascadeButtonGadget specified for the parent of the
  59.                  Pulldown MenuPane.  A Pulldown MenuPane can be
  60.  
  61.  
  62.  
  63.      Page 1                                          (printed 4/30/98)
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70.      XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnUUUUuuuuNNNN((((IIII3333XXXXXXXX))))SSSSyyyyssssXXXXttttmmmmeeeeVVVVmmmmaaaaCCCCVVVVrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX))))
  71.  
  72.  
  73.  
  74.                  attached only to a CascadeButton or
  75.                  CascadeButtonGadget, and only CascadeButtons and
  76.                  CascadeButtonGadgets are counted in determining the
  77.                  integer _n.  The first CascadeButton or
  78.                  CascadeButtonGadget is number 0.
  79.  
  80.           _c_a_l_l_b_a_c_k
  81.                  Specifies a callback procedure to be called when a
  82.                  button is activated or when its value changes.  This
  83.                  callback function is added to each button after
  84.                  creation.  For a CascadeButtonGadget or a
  85.                  PushButtonGadget, the callback is added as the
  86.                  button's XXXXmmmmNNNNaaaaccccttttiiiivvvvaaaatttteeeeCCCCaaaallllllllbbbbaaaacccckkkk, and it is called when
  87.                  the button is activated.  For a ToggleButtonGadget,
  88.                  the callback is added as the button's
  89.                  XXXXmmmmNNNNvvvvaaaalllluuuueeeeCCCChhhhaaaannnnggggeeeeddddCCCCaaaallllllllbbbbaaaacccckkkk, and it is called when the
  90.                  button's value changes.  The button number is
  91.                  returned in the _c_l_i_e_n_t__d_a_t_a field.
  92.  
  93.  
  94.           The variable portion of the argument list consists of groups
  95.           of arguments.  The first argument in each group is a
  96.           constant or a string and determines which arguments follow
  97.           in that group.  The last argument in the list must be NULL.
  98.           Following are the possible first arguments in each group of
  99.           varargs:
  100.  
  101.  
  102.           XXXXmmmmVVVVaaaaCCCCAAAASSSSCCCCAAAADDDDEEEEBBBBUUUUTTTTTTTTOOOONNNN
  103.                  This is followed by two additional arguments.  The
  104.                  set specifies one button in the PulldownMenu and some
  105.                  of its resource values.  The button created is a
  106.                  CascadeButtonGadget.  Following are the additional
  107.                  two arguments, in this order:
  108.  
  109.  
  110.                  _l_a_b_e_l   The label string, of type XmString.
  111.  
  112.                  _m_n_e_m_o_n_i_c
  113.                          The mnemonic, of type KeySym.
  114.  
  115.  
  116.           XXXXmmmmVVVVaaaaPPPPUUUUSSSSHHHHBBBBUUUUTTTTTTTTOOOONNNN
  117.                  This is followed by four additional arguments.  The
  118.                  set specifies one button in the PulldownMenu and some
  119.                  of its resource values.  The button created is a
  120.                  PushButtonGadget.  Following are the additional four
  121.                  arguments, in this order:
  122.  
  123.  
  124.                  _l_a_b_e_l   The label string, of type XmString.
  125.  
  126.  
  127.  
  128.  
  129.      Page 2                                          (printed 4/30/98)
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136.      XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnUUUUuuuuNNNN((((IIII3333XXXXXXXX))))SSSSyyyyssssXXXXttttmmmmeeeeVVVVmmmmaaaaCCCCVVVVrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX))))
  137.  
  138.  
  139.  
  140.                  _m_n_e_m_o_n_i_c
  141.                          The mnemonic, of type KeySym.
  142.  
  143.                  _a_c_c_e_l_e_r_a_t_o_r
  144.                          The accelerator, of type String.
  145.  
  146.                  _a_c_c_e_l_e_r_a_t_o_r__t_e_x_t
  147.                          The accelerator text, of type XmString.
  148.  
  149.  
  150.           XXXXmmmmVVVVaaaaRRRRAAAADDDDIIIIOOOOBBBBUUUUTTTTTTTTOOOONNNN
  151.                  This is followed by four additional arguments.  The
  152.                  set specifies one button in the PulldownMenu and some
  153.                  of its resource values.  The button created is a
  154.                  ToggleButtonGadget.  Following are the additional
  155.                  four arguments, in this order:
  156.  
  157.  
  158.                  _l_a_b_e_l   The label string, of type XmString.
  159.  
  160.                  _m_n_e_m_o_n_i_c
  161.                          The mnemonic, of type KeySym.
  162.  
  163.                  _a_c_c_e_l_e_r_a_t_o_r
  164.                          The accelerator, of type String.
  165.  
  166.                  _a_c_c_e_l_e_r_a_t_o_r__t_e_x_t
  167.                          The accelerator text, of type XmString.
  168.  
  169.  
  170.           XXXXmmmmVVVVaaaaCCCCHHHHEEEECCCCKKKKBBBBUUUUTTTTTTTTOOOONNNN
  171.                  This is followed by four additional arguments.  The
  172.                  set specifies one button in the PulldownMenu and some
  173.                  of its resource values.  The button created is a
  174.                  ToggleButtonGadget.  Following are the additional
  175.                  four arguments, in this order:
  176.  
  177.  
  178.                  _l_a_b_e_l   The label string, of type XmString.
  179.  
  180.                  _m_n_e_m_o_n_i_c
  181.                          The mnemonic, of type KeySym.
  182.  
  183.                  _a_c_c_e_l_e_r_a_t_o_r
  184.                          The accelerator, of type String.
  185.  
  186.                  _a_c_c_e_l_e_r_a_t_o_r__t_e_x_t
  187.                          The accelerator text, of type XmString.
  188.  
  189.  
  190.           XXXXmmmmVVVVaaaaTTTTIIIITTTTLLLLEEEE
  191.                  This is followed by one additional argument.  The
  192.  
  193.  
  194.  
  195.      Page 3                                          (printed 4/30/98)
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202.      XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnUUUUuuuuNNNN((((IIII3333XXXXXXXX))))SSSSyyyyssssXXXXttttmmmmeeeeVVVVmmmmaaaaCCCCVVVVrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX))))
  203.  
  204.  
  205.  
  206.                  pair specifies a title LabelGadget in the
  207.                  PulldownMenu.  Following is the additional argument:
  208.  
  209.  
  210.                  _t_i_t_l_e   The title string, of type XmString.
  211.  
  212.  
  213.           XXXXmmmmVVVVaaaaSSSSEEEEPPPPAAAARRRRAAAATTTTOOOORRRR
  214.                  This is followed by no additional arguments.  It
  215.                  specifies one separator in the PulldownMenu.
  216.  
  217.           XXXXmmmmVVVVaaaaDDDDOOOOUUUUBBBBLLLLEEEE____SSSSEEEEPPPPAAAARRRRAAAATTTTOOOORRRR
  218.                  This is followed by no additional arguments.  It
  219.                  specifies one separator in the PulldownMenu.  The
  220.                  separator type is XXXXmmmmDDDDOOOOUUUUBBBBLLLLEEEE____LLLLIIIINNNNEEEE.
  221.  
  222.           _r_e_s_o_u_r_c_e__n_a_m_e
  223.                  This is followed by one additional argument, the
  224.                  value of the resource, of type XtArgVal.  The pair
  225.                  specifies a resource and its value for the RowColumn
  226.                  widget.
  227.  
  228.           XXXXttttVVVVaaaaTTTTyyyyppppeeeeddddAAAArrrrgggg
  229.                  This is followed by four additional arguments.  The
  230.                  set specifies a resource and its value for the
  231.                  RowColumn widget.  A resource type conversion is
  232.                  performed if necessary.  Following are the additional
  233.                  four arguments, in this order:
  234.  
  235.  
  236.                  _n_a_m_e    The resource name, of type String.
  237.  
  238.                  _t_y_p_e    The type of the resource value supplied, of
  239.                          type String.
  240.  
  241.                  _v_a_l_u_e   The resource value (or a pointer to the
  242.                          resource value, depending on the type and
  243.                          size of the value), of type XtArgVal.
  244.  
  245.                  _s_i_z_e    The size of the resource value in bytes, of
  246.                          type int.
  247.  
  248.  
  249.           XXXXttttVVVVaaaaNNNNeeeesssstttteeeeddddLLLLiiiisssstttt
  250.                  This is followed by one additional argument of type
  251.                  XtVarArgsList.  This argument is a nested list of
  252.                  varargs returned by XXXXttttVVVVaaaaCCCCrrrreeeeaaaatttteeeeAAAArrrrggggssssLLLLiiiisssstttt.
  253.  
  254.  
  255.           For more information on variable-length argument lists, see
  256.           the X Toolkit Intrinsics documentation.
  257.  
  258.  
  259.  
  260.  
  261.      Page 4                                          (printed 4/30/98)
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268.      XXXXmmmmVVVVaaaaCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnUUUUuuuuNNNN((((IIII3333XXXXXXXX))))SSSSyyyyssssXXXXttttmmmmeeeeVVVVmmmmaaaaCCCCVVVVrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX))))
  269.  
  270.  
  271.  
  272.           A number of resources exist specifically for use with this
  273.           and other simple menu creation routines.  For a complete
  274.           definition of RowColumn and its associated resources, see
  275.           XXXXmmmmRRRRoooowwwwCCCCoooolllluuuummmmnnnn((((3333XXXX)))).
  276.  
  277.      RRRREEEETTTTUUUURRRRNNNN VVVVAAAALLLLUUUUEEEE
  278.           Returns the RowColumn widget ID.
  279.  
  280.      RRRREEEELLLLAAAATTTTEEEEDDDD IIIINNNNFFFFOOOORRRRMMMMAAAATTTTIIIIOOOONNNN
  281.           XXXXmmmmCCCCrrrreeeeaaaatttteeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu((((3333XXXX)))), XXXXmmmmCCCCrrrreeeeaaaatttteeeeRRRRoooowwwwCCCCoooolllluuuummmmnnnn((((3333XXXX)))),
  282.           XXXXmmmmCCCCrrrreeeeaaaatttteeeeSSSSiiiimmmmpppplllleeeePPPPuuuullllllllddddoooowwwwnnnnMMMMeeeennnnuuuu, and XXXXmmmmRRRRoooowwwwCCCCoooolllluuuummmmnnnn((((3333XXXX)))).
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.  
  305.  
  306.  
  307.  
  308.  
  309.  
  310.  
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.      Page 5                                          (printed 4/30/98)
  328.  
  329.  
  330.  
  331.