XMVACREATESIMPLERADIOBOX(3)

πŸ“¦
version 2.5.2 Β· 2 versions
, in alpine 3.24, arch rolling, centos-stream 9, epel 10, fedora 43, fedora 44, nixos 26.05, nixpkgs unstable, opensuse-leap 16.0

πŸ’– NAME πŸ’–

XmVaCreateSimpleRadioBox β€” a RowColumn widget convenience creation function, bestie. That's the whole vibe. It makes a radio box. For you. Slay.


✨ SYNOPSIS ✨

#include <Xm/RowColumn.h>
Widget XmVaCreateSimpleRadioBox(
Widget parent,
String name,
int button_set,
XtCallbackProc callback);

πŸŽ€ DESCRIPTION πŸŽ€

Okay so. XmVaCreateSimpleRadioBox creates an instance of a RowColumn widget of type XmWORK_AREA and hands you back the associated widget ID. That's it, that's the job. It uses the ANSI C variable-length argument list (varargs) calling convention, which is giving "trust me, the arguments are in there somewhere" energy.

This routine creates a RadioBox and its ToggleButtonGadget children β€” a whole little friend group. The name of each button is button_n, where n is an integer from 0 (zero) to the number of buttons in the menu minus 1. Numbering from zero, as the universe intended. πŸ’…

Here are the main character arguments:

  • parent β€” specifies the parent widget ID. It's the mom of the operation. πŸ‘‘
  • name β€” specifies the name of the created widget.
  • button_set β€” specifies which button is initially set. The value is the integer n in the button name button_n. So like, if you want button_3 to be the one holding the aux, pass 3.
  • callback β€” specifies a callback procedure to be called when a button's value changes. This callback function is added to each button after creation as the button's XmNvalueChangedCallback. The callback function is called when a button's value changes, and the button number is returned in the client_data field. So the button tattles on itself. Love that for us. 🫢

The variable portion of the argument list consists of groups of arguments. The first argument in each group is a constant or a string and determines which arguments follow in that group. The last argument in the list must be NULL. Not optional, not negotiable, it's the periodt of the whole call. βœ‹

Following are the possible first arguments in each group of varargs:

  • XmVaRADIOBUTTON β€” this is followed by four additional arguments. The set specifies one button in the RadioBox and some of its resource values. Following are the additional four arguments, in order:
    • label β€” the label string, of type XmString.
    • mnemonic β€” the mnemonic, of type KeySym. This is ignored in this release. 😭
    • accelerator β€” the accelerator, of type String. This is ignored in this release. 😭
    • accelerator_text β€” the accelerator text, of type XmString. This is ignored in this release. 😭
  • resource_name β€” this is followed by one additional argument, the value of the resource, of type XtArgVal. The pair specifies a resource and its value for the RowColumn widget. Dynamic duo behavior.
  • XtVaTypedArg β€” this is followed by four additional arguments. The set specifies a resource and its value for the RowColumn widget. A resource type conversion is performed if necessary. Following are the additional four arguments, in this order:
    • name β€” the resource name, of type String
    • type β€” the type of the resource value supplied, of type String
    • value β€” the resource value (or a pointer to the resource value, depending on the type and size of the value), of type XtArgVal
    • size β€” the size of the resource value in bytes, of type int
  • XtVaNestedList β€” this is followed by one additional argument of type XtVarArgsList. This argument is a nested list of varargs returned by XtVaCreateArgsList. Nested. Lists. Inception but make it X11. πŸŒ€

For more information on variable-length argument lists, see the X Toolkit Intrinsics documentation.

A number of resources exist specifically for use with this and other simple menu creation routines. For a complete definition of RowColumn and its associated resources, see XmRowColumn(3). Go read it, iykyk. πŸ“š


🌈 RETURN 🌈

Returns the RowColumn widget ID. That's your prize. Take it. πŸ†


(the trailing comma is canon, don't @ me)


And that's the whole page, bestie β€” this was XmVaCreateSimpleRadioBox(library call) from the XmVaCreateSimpleRadioBox(library call) source, and yeah, the footer is literally just the title again because that's the energy this manpage chose. ✨ Go forth and build radio boxes. Main character energy only. πŸ’–πŸŒΈ