XMROWCOLUMN(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

πŸ’– XmRowColumn β€” the RowColumn widget class πŸ’–

ok so bestie, welcome to XmRowColumn(library call) β€” yes it's a library call page, that's the manual name, we're just folding it in up top like a lil name tag. this is the RowColumn widget class and she is serving general-purpose layout manager realness. buckle up, this is a long one 🌸


✨ SYNOPSIS ✨

#include <Xm/RowColumn.h>

that's it. that's the whole synopsis. iconic. πŸ’…


🌈 DESCRIPTION 🌈

okay so. the RowColumn widget is a general purpose RowColumn manager β€” meaning she can hold literally any widget type as a child. she does not care. she does not need to know what your children are doing with their lives. she has no special knowledge about how her children function, and she gives you nothing beyond support for several different layout styles. lowkey a supportive queen who minds her business 🫢

BUT. she can also be configured as a menu, and in that mode she gets picky β€” she expects only certain children, and she configures herself to a particular layout. the menus she supports are:

  • MenuBar
  • Pulldown or Popup menu panes
  • OptionMenu

and for the trait girlies: RowColumn uses the XmQTmenuSavvy trait and holds the XmQTmenuSystem trait. periodt. ✨


the layout vibes

the type of layout she performs is controlled by how the application has set the various layout resources. she can be configured to lay out her children in either rows or columns. and on top of that, the application can specify how the children get laid out, like this:

  • the children are packed tightly together into either rows or columns
  • each child is placed in an identically sized box (producing a symmetrical look) β€” very aesthetically pleasing, we love symmetry πŸ’–
  • a specific layout (the current x and y positions of the children control their location)

plus, the application has control over both the spacing that occurs between each row and column and the margin spacing present between the edges of the RowColumn widget and any children that are placed against it. so you get to control the gap and the padding. we love a girl with boundaries. πŸ’…


defaults & deets (pay attention bestie)

the default XmNinsertPosition procedure for the RowColumn returns the value of XmNpositionIndex if one has been specified for the child. otherwise, this procedure returns the number of children in the RowColumn's XmNnumChildren list.

in a MenuBar, Pulldown menu pane, or Popup menu pane, the default for the XmNshadowThickness resource is 2.

in an OptionMenu or a WorkArea (such as a RadioBox or CheckBox), this resource is not applicable and its use is undefined β€” don't do it, babe. πŸ™ˆ if an application wishes to place a 3-D shadow around an OptionMenu or WorkArea, it can create the RowColumn as a child of a Frame widget instead. workaround slay.

in a MenuBar, Pulldown menu pane, or Popup menu pane, the XmNnavigationType resource is not applicable and its use is undefined.

  • in a WorkArea, the default for XmNnavigationType is XmTAB_GROUP.
  • in an OptionMenu, the default for XmNnavigationType is XmNONE.

in a MenuBar, Pulldown menu pane, or Popup menu pane, the XmNtraversalOn resource is not applicable and its use is undefined.

  • in an OptionMenu or WorkArea, the default for XmNtraversalOn is True.

if the parent of the RowColumn is a MenuShell, the XmNmappedWhenManaged resource is forced to False when the widget is realized. no take-backs, she said what she said. πŸ’€


resource file names for the auto-created babies

the user can specify resources in a resource file for the automatically created widgets and gadgets of an OptionMenu. the following list identifies the names of these widgets (or gadgets) and the associated OptionMenu areas:

  • Option Menu Label Gadget β†’ OptionLabel
  • Option Menu Cascade Button β†’ OptionButton

for the Popup and Pulldown Menupanes, popup and pulldown menus have particular behaviors when the <Btn1> button is pressed outside the menus. these behaviors are summarized here:

when there is already a popped up menu, a user can either press <Btn1> in the same area as the popped up menu, or can press <Btn1> in another area that should have a menu popped up. when <Btn1> is pressed in the same area as the already popped up menu, that menu is unposted. if <Btn1> is pressed in a different area, the associated popup menu is posted for the new area.

ngl note: if the XmNpopupHandlerCallback of either XmManager or XmPrimitive is available, then the callback may override these default behaviors. so like, don't be shocked if it does something else, okay? 😭

for pulldown menus, a user can press <Btn1> on the Cascade button to post the pulldown menu, then click on it again. upon the second click, the pulldown menu is unposted. click-click, bye bye. ✌️

Popup menus are not allowed to have NULL parents. that's the rule. no orphan popups. 🚫


πŸŽ€ Tear-off Menus πŸŽ€

Pulldown and Popup menu panes support tear-off menus, which enable the user to retain a menu pane on the display to facilitate subsequent menu selections. a menu pane that can be torn-off is identified by a tear-off button that spans the width of the menu pane and displays a dashed line.

a torn-off menu pane contains a window manager system menu icon and a title bar. the window title displays the label of the cascade button that initiated the action when the label type is XmSTRING. if the label contains a pixmap, the window title is empty. a tear-off menu from a Popup menu pane also displays an empty title.

⚠️ Tear-off menus should not be shared. just don't. sharing is not caring here bestie.

the user can tear off a menu pane using the mouse or keyboard:

  • clicking <Btn1> or pressing <osfActivate> (or <osfSelect>) on the tear-off button, tears off the menu pane at the current position.
  • pressing <Btn2> on the tear-off button tears off the menu pane and allows the user to drag the torn-off menu to a new position designated by releasing the mouse button.

tearing off a menu pane unposts the current active menu. only one tear-off copy for each menu pane is allowed. subsequent tear-off actions of a torn menu pane unpost the existing copy first. one at a time, she's monogamous like that. πŸ’…

the name of the tear-off button of a torn-off menu pane is TearOffControl. the name can be used to set resources in a resource file. an application can also obtain the tear-off button itself using XmGetTearOffControl and then set resource values by calling XtSetValues.

the tear-off button has Separator-like behavior. its appearance can be specified with the following tear-off button resources:

  • XmNbackground
  • XmNbackgroundPixmap
  • XmNbottomShadowColor
  • XmNforeground
  • XmNheight
  • XmNmargin
  • XmNseparatorType
  • XmNshadowThickness
  • XmNtopShadowColor

refer to the XmSeparator reference page for a complete description of each of these resources. πŸ‘‘

the XmNtearOffModel, XmNtearOffMenuActivateCallback, and XmNtearOffMenuDeactivateCallback are RowColumn resources that affect tear-off menu behavior. the XmNtearOffTitle resource enables the application to specify the tear-off menu's title if the menu is torn off.

by default, menus do not tear off. setting the XmNtearOffModel resource to XmTEAR_OFF_ENABLED enables tear-off functionality. there is no resource converter preregistered for XmNtearOffModel. to allow tear-off functionality to be enabled through the resource database, call the function XmRepTypeInstallTearOffModelConverter. (iykyk ✨)

tear-off menu focus policy follows standard window manager policy. it is recommended that the startupKeyFocus and autoKeyFocus mwm resources be set to True.


πŸ¦‹ Descendants πŸ¦‹

RowColumn automatically creates the descendants shown in the following table. an application can use XtNameToWidget to gain access to the named descendant. in addition, a user or an application can use the named descendant when specifying resource values.

(the og was a table bestie, so here it is in list form β€” same tea, different cup πŸ“)

  • Named Descendant: OptionButton β€” Class: XmCascadeButtonGadget β€” Identity: option menu button
  • Named Descendant: OptionLabel β€” Class: XmLabelGadget β€” Identity: option menu label
  • Named Descendant: TearOffControl β€” Class: subclass of XmPrimitive β€” Identity: tear-off button of torn-off menu pane

🌸 Classes 🌸

RowColumn inherits behavior, resources, and traits from Core, Composite, Constraint, and XmManager classes. she comes from a good family. πŸ’œ

  • the class pointer is xmRowColumnWidgetClass.
  • the class name is XmRowColumn.

⭐ New Resources ⭐

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 .Xdefaults file, remove the XmN or XmC prefix and use the remaining letters. to specify one of the defined values for a resource in a .Xdefaults file, remove the Xm 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 XtSetValues (S)
  • retrieved by using XtGetValues (G)
  • or is not applicable (N/A)

okay bestie that's the end of part 1, the resources table and everything after is coming up next β€” don't go anywhere πŸ’–

πŸ’… XmRowColumn Resource Set πŸ’…

okay bestie, here's the whole resource lineup β€” every single one, no skips, periodt. each bullet is giving you the resource name, its class, type, default, and access. keep up, you got this 🫢

  • XmNadjustLast β€” class XmCAdjustLast, type Boolean, default True, access CSG ✨
  • XmNadjustMargin β€” class XmCAdjustMargin, type Boolean, default True, access CSG πŸ’–
  • XmNentryAlignment β€” class XmCAlignment, type unsigned char, default XmALIGNMENT_BEGINNING, access CSG πŸŽ€
  • XmNentryBorder β€” class XmCEntryBorder, type Dimension, default 0, access CSG πŸ¦‹
  • XmNentryCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C 🌸
  • XmNentryClass β€” class XmCEntryClass, type WidgetClass, default dynamic, access CSG πŸ’…
  • XmNentryVerticalAlignment β€” class XmCVerticalAlignment, type unsigned char, default XmALIGNMENT_CENTER, access CSG 🫢
  • XmNisAligned β€” class XmCIsAligned, type Boolean, default True, access CSG 😭
  • XmNisHomogeneous β€” class XmCIsHomogeneous, type Boolean, default dynamic, access CG πŸ”₯
  • XmNlabelString β€” class XmCXmString, type XmString, default NULL, access C πŸ‘‘
  • XmNmapCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C 🌈
  • XmNmarginHeight β€” class XmCMarginHeight, type Dimension, default dynamic, access CSG ⭐
  • XmNmarginWidth β€” class XmCMarginWidth, type Dimension, default dynamic, access CSG πŸ’€
  • XmNmenuAccelerator β€” class XmCAccelerators, type String, default dynamic, access CSG πŸ™ˆ
  • XmNmenuHelpWidget β€” class XmCMenuWidget, type Widget, default NULL, access CSG πŸ“
  • XmNmenuHistory β€” class XmCMenuWidget, type Widget, default NULL, access CSG 🧚
  • XmNmenuPost β€” class XmCMenuPost, type String, default NULL, access CSG πŸ’œ
  • XmNmnemonic β€” class XmCMnemonic, type KeySym, default NULL, access CSG ✨
  • XmNmnemonicCharSet β€” class XmCMnemonicCharSet, type String, default XmFONTLIST_DEFAULT_TAG, access CSG πŸ’–
  • XmNnumColumns β€” class XmCNumColumns, type short, default 1, access CSG πŸŽ€
  • XmNorientation β€” class XmCOrientation, type unsigned char, default dynamic, access CSG πŸ¦‹
  • XmNpacking β€” class XmCPacking, type unsigned char, default dynamic, access CSG 🌸
  • XmNpopupEnabled β€” class XmCPopupEnabled, type int, default XmPOPUP_KEYBOARD, access CSG πŸ’…
  • XmNradioAlwaysOne β€” class XmCRadioAlwaysOne, type Boolean, default True, access CSG 🫢

and that's the whole resource set, bestie β€” every single detail kept, no cap πŸ’– more coming right up, stay tuned πŸ‘€

  • XmNradioBehavior β€” class XmCRadioBehavior, type Boolean, default False, access CSG ✨
  • XmNresizeHeight β€” class XmCResizeHeight, type Boolean, default True, access CSG
  • XmNresizeWidth β€” class XmCResizeWidth, type Boolean, default True, access CSG
  • XmNrowColumnType β€” class XmCRowColumnType, type unsigned char, default XmWORK_AREA, access CG πŸ’…
  • XmNspacing β€” class XmCSpacing, type Dimension, default dynamic, access CSG
  • XmNsubMenuId β€” class XmCMenuWidget, type Widget, default NULL, access CSG
  • XmNtearOffMenuActivateCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C
  • XmNtearOffMenuDeactivateCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C
  • XmNtearOffModel β€” class XmCTearOffModel, type unsigned char, default XmTEAR_OFF_DISABLED, access CSG πŸŽ€
  • XmNtearOffTitle β€” class XmCTearOffTitle, type XmString, default NULL, access CSG
  • XmNunmapCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C
  • XmNwhichButton β€” class XmCWhichButton, type unsigned int, default dynamic, access CSG

XmNadjustLast

Okay so this one stretches the last row of children all the way to the bottom edge of the RowColumn β€” but only when XmNorientation is XmHORIZONTAL. Flip it to XmVERTICAL and instead it stretches the last column out to the right edge. πŸ¦‹

Wanna turn the whole thing off? Set XmNadjustLast to False and the feature is done-zo.

XmNadjustMargin

This is the one that says: do all the items inside the RowColumn get their inner minor margins forced to the same value, yes or no? And bestie, "inner minor margin" here means the XmNmarginLeft, XmNmarginRight, XmNmarginTop, and XmNmarginBottom resources that XmLabel and XmLabelGadget support. πŸ’–

Here's the tea on how it plays out:

  • Horizontal orientation β†’ XmNmarginTop and XmNmarginBottom for all items in a particular row get forced to the same value. That value? The largest margin specified for one of the Label items. πŸ‘‘
  • Vertical orientation β†’ XmNmarginLeft and XmNmarginRight for all items in a particular column get forced to the same value, again the largest margin specified for one of the Label items.

Why do we care? Because it keeps all the text within each row or column lined up with all the other text in that same row or column. Aesthetic. 🌸

One lil' caveat though: if XmNrowColumnType is either XmMENU_POPUP or XmMENU_PULLDOWN and this resource is True, then only button children get their margins adjusted. Just the buttons, nobody else.

XmNentryAlignment

Sets the alignment type for children that are subclasses of XmLabel or XmLabelGadget, and it only kicks in when XmNisAligned is enabled. The textual alignment types are:

  • XmALIGNMENT_BEGINNING (the default, bestie)
  • XmALIGNMENT_CENTER
  • XmALIGNMENT_END

Wanna know what those actually do? Go read the description of XmNalignment in the XmLabel(3) reference page, it's all explained over there. ✨

XmNentryBorder

Imposes a uniform border width on every single one of RowColumn's children. Default value is 0 (zero), which β€” you guessed it β€” disables the whole feature.

XmNentryCallback

This one is lowkey powerful. It disables the XmNactivateCallback and XmNvalueChangedCallback callbacks for all CascadeButton, DrawnButton, PushButton, and ToggleButton widgets and gadgets contained within the RowColumn widget. πŸ’€

If the application supplies this resource, then XmNactivateCallback and XmNvalueChangedCallback get revectored over to the XmNentryCallback callbacks instead. Which means one single callback routine can handle every item contained in a RowColumn widget. Main character energy for real. The callback reason is XmCR_ACTIVATE.

If the application does not supply this resource, then XmNactivateCallback and XmNvalueChangedCallback for each item in the RowColumn widget just work as normal. No drama.

Heads up, bestie: the application must supply this resource when the widget is created. Changing this resource using XtSetValues is not supported. Periodt. πŸ™ˆ

XmNentryClass

Specifies the only widget class that can be added to the RowColumn widget. This resource is meaningful only when the XmNisHomogeneous resource is set to True. And good news β€” both the widget and gadget variants of the specified class may be added to the widget. 🫢

Now for the defaults, because they're kind of a lot:

  • When XmCreateRadioBox is called, or when XmNrowColumnType is set to XmWORK_AREA and XmNradioBehavior is True, the default value of XmNentryClass is xmToggleButtonGadgetClass.
  • When XmNrowColumnType is set to XmMENU_BAR, the value of XmNentryClass is forced to xmCascadeButtonWidgetClass. No negotiating, it's just forced. πŸ’…

XmNentryVerticalAlignment

Specifies the type of vertical alignment for children that are subclasses of XmLabel, XmLabelGadget, and XmText. 🌈

Real talk: this resource is invalid if XmNorientation is XmVERTICAL and XmNpacking is XmPACK_TIGHT, because that layout preserves variable heights among the children. So don't come for it there.

The vertical alignment types include:

XmALIGNMENT_BASELINE_BOTTOM

Causes the bottom baseline of all children in a row to be aligned. This one is applicable only when all children in a row contain textual data.

XmALIGNMENT_BASELINE_TOP

Causes the top baseline of all children in a row to be aligned. Same rule as above β€” applicable only when all children in a row contain textual data.

XmALIGNMENT_CONTENTS_BOTTOM

Causes the bottom of the contents (text or pixmap) of all children in a row to be aligned. πŸŽ€

XmALIGNMENT_CENTER

Causes the center of all children in a row to be aligned.

XmALIGNMENT_CONTENTS_TOP

Causes the top of the contents (text or pixmap) of all children in a row to be aligned. ⭐

  • XmNisAligned β€” tells the RowColumn widget how to align the text inside each item, and this only does anything for items that are subclasses of XmLabel or XmLabelGadget. But β€” plot twist β€” if the item is a Label widget or gadget and its parent is a Popup menu pane or a Pulldown menu pane, no alignment happens at all. In that case the Label is literally just the title of the menu pane, and whatever alignment the app set does not get overridden. The actual kind of textual alignment is handled by XmNentryAlignment. ✨
  • XmNisHomogeneous β€” do you want the RowColumn to enforce exact homogeneity among its children? Because if this is True, then the only widgets allowed in are the ones whose class matches XmNentryClass. This is the vibe check you set when you're building a MenuBar. And if you try to insert a child that isn't a member of that class? It throws a warning message at you. πŸ’€

Extra lore: in a MenuBar, XmNisHomogeneous is forced to True. In an OptionMenu, it's forced to False. When XmCreateRadioBox is called, the default is True. Everywhere else, the default is False. No takebacks, those are the rules.

  • XmNlabelString β€” when XmNrowColumnType is set to XmMENU_OPTION, this resource points at a text string that shows the label next to (well, in relation to) the selection area. Where exactly the label sits relative to the selection area depends on the layout direction in the horizontal orientation. For every other RowColumn type, this resource means nothing, bestie. And if the app wants to change the label after creation? It has to grab the LabelGadget ID (XmOptionLabelGadget) and call XtSetValues on the LabelGadget directly. Default value is no label at all. πŸ™ˆ
  • XmNmapCallback β€” a widget-specific callback function that fires when the window tied to the RowColumn widget is about to be mapped. The callback reason is XmCR_MAP. ✨
  • XmNmarginHeight β€” how much blank space lives between the top edge of the RowColumn widget and the first item in each column, plus the bottom edge and the last item in each column. Default is 0 (zero) for Pulldown and Popup menu panes, and 3 pixels for every other RowColumn type. πŸŽ€
  • XmNmarginWidth β€” same energy but sideways: blank space between the left edge of the RowColumn widget and the first item in each row, plus the right edge and the last item in each row. Default is 0 (zero) for Pulldown and Popup menu panes, and 3 pixels for every other RowColumn type. πŸŽ€
  • XmNmenuAccelerator β€” only useful when the RowColumn widget is configured as a Popup menu pane or a MenuBar. Format-wise it's like the left side of a translation string, except it has to specify a key event. For a Popup menu pane, typing the accelerator posts the pane. For a MenuBar, typing it highlights the first item in the MenuBar and enables traversal inside it. Default for a Popup menu pane is <osfMenu>. Default for a MenuBar is <osfMenuBar>. And heads up: setting XmNpopupEnabled to False disables the accelerator. πŸ’…
  • XmNmenuHelpWidget β€” the widget ID for the CascadeButton that gets treated as the Help widget, but only if XmNrowColumnType is set to XmMENU_BAR. Which corner of the MenuBar the Help widget lands in depends on the widget's XmNlayoutDirection resource. If the RowColumn widget is literally any other type besides XmMENU_BAR, this resource is not meaningful. πŸ¦‹
  • XmNmenuHistory β€” the widget ID of the last menu entry that got activated. Also super useful for setting the current selection on an OptionMenu. If XmNrowColumnType is XmMENU_OPTION, the specified menu item gets positioned under the cursor when the menu is displayed. πŸ‘‘

And if the RowColumn widget has XmNradioBehavior set to True, the widget field for this resource holds the widget ID of the last ToggleButton or ToggleButtonGadget that flipped from unselected to selected. Default value is the widget ID of the first child in the widget.

  • XmNmenuPost β€” an X event description for the button event that posts a menu system. Defaults: BMenu Press for XmMENU_POPUP; <Btn1> Press for XmMENU_OPTION, XmMENU_BAR, and XmWORK_AREA. The XmNmenuPost resource for pulldowns should stay consistent with the top-level parent menu (even though the event type itself gets ignored). ⚠️ And setting this to BTransfer Press will conflict with drag and drop operations, since those use BTransfer Press as a default button binding. So basically: this resource cannot be BTransfer Press. Periodt.
  • XmNmnemonic β€” useful only when XmNrowColumnType is set to XmMENU_OPTION. It specifies a keysym for a key that, when the user presses it together with the MAlt modifier, posts the associated Pulldown menu pane. The first character in the OptionMenu label string that exactly matches the mnemonic β€” in the character set given by XmNmnemonicCharSet β€” gets underlined. The user can post the menu with either the shifted or the unshifted mnemonic key. Default is no mnemonic. 🌸
  • XmNmnemonicCharSet β€” the character set of the mnemonic for an OptionMenu. Default is XmFONTLIST_DEFAULT_TAG. If the RowColumn widget is any type other than XmMENU_OPTION, this resource is not meaningful. πŸ’œ
  • XmNnumColumns β€” how many minor dimension extensions get made to fit the entries in; only meaningful when XmNpacking is XmPACK_COLUMN.

For vertically oriented RowColumn widgets, this says how many columns get built, and the number of entries per column is adjusted to keep that column count β€” if possible. For horizontally oriented RowColumn widgets, it says how many rows get built. 🧚

Default is 1. In an OptionMenu the value is forced to 1. And the value must be greater than 0 (zero).

  • XmNorientation β€” decides whether RowColumn layouts are row-major or column-major. Column-major means the children get laid out in columns inside the widget. Row-major means they get laid out in rows. The direction of the horizontal layout in row-major (from left or from right) and the wrapping in column-major (vertical) both depend on the widget's XmNlayoutDirection resource. XmVERTICAL picks a column-major layout. XmHORIZONTAL picks a row-major layout. 🌈

When you're creating a MenuBar or an OptionMenu, the default is XmHORIZONTAL. Otherwise the default is XmVERTICAL. And β€” important β€” specifying XmVERTICAL for a MenuBar gives you undefined results. Don't do it.

  • XmNpacking β€” how the items inside a RowColumn widget get packed. Can be XmPACK_TIGHT, XmPACK_COLUMN, or XmPACK_NONE. When a RowColumn widget packs its items, it figures out its major dimension from the XmNorientation resource. πŸ’…

XmPACK_TIGHT β€” given the current major dimension (vertical if XmNorientation is XmVERTICAL, for example), entries go one after another until the RowColumn widget has to wrap. It wraps when there's no room left for a complete child in that dimension, and wrapping works by starting a new row or column in the next available space. It keeps wrapping as many times as needed until all the children are laid out. In the vertical dimension (columns), boxes get set to the same width; in the horizontal dimension (rows), boxes get set to the same depth. Each entry's position in the major dimension is left untouched (so XmNy stays put when XmNorientation is XmVERTICAL), while its position in the minor dimension gets set to the same value as the greatest entry in that particular row or column. And the minor-dimension position of any given row or column is independent of every other row or column. 🫢

XmPACK_COLUMN β€” every entry goes into identically sized boxes, sized off the largest height and width values of all the child widgets. XmNnumColumns determines how many boxes land in the major dimension before it extends into the minor dimension.

XmPACK_NONE β€” no packing, period. The x and y attributes of each entry are left alone, and the RowColumn widget tries to grow big enough to enclose everything.

Defaults: when XmCreateRadioBox is called, or when XmNrowColumnType is XmWORK_AREA and XmNradioBehavior is True, XmNpacking defaults to XmPACK_COLUMN. In an OptionMenu it's initialized to XmPACK_TIGHT. Otherwise it defaults to XmPACK_TIGHT.

  • XmNpopupEnabled β€” lets the menu system enable keyboard input (accelerators and mnemonics) defined for the Popup menu pane and any of its submenus. The Popup menu pane needs to be told whenever its accessibility to the user changes, because posting the Popup menu pane is controlled by the application. This resource can take four values, including:

XmPOPUP_KEYBOARD

Specifies that the keyboard inputβ€”accelerators and mnemonicsβ€”defined for the Popup menu pane and any of its submenus is enabled. This is the default. ✨

XmPOPUP_DISABLED

Specifies that the keyboard input is disabled. no keyboard for you bestie πŸ’…

XmPOPUP_AUTOMATIC

Specifies that the keyboard is enabled for automatic popup menus.

XmPOPUP_AUTOMATIC_RECURSIVE

Specifies that the keyboard is enabled for recursive automatic popup menus.


XmNradioAlwaysOne

If True, forces the active ToggleButton or ToggleButtonGadget to be automatically selected after having been unselected (if no other toggle was activated). If False, the active toggle may be unselected. The default value is True. This resource is important only when XmNradioBehavior is True.

The application can always add and subtract toggles from RowColumn regardless of the selected/unselected state of the toggle. The application can also manage and unmanage toggle children of RowColumn at any time regardless of state. Therefore, the application can sometimes create a RowColumn that has XmNradioAlwaysOne set to True and none of the toggle children selected. The result is undefined if the value of this resource is True and the application sets more than one ToggleButton at a time. 😭


XmNradioBehavior

Specifies a Boolean value that when True, indicates that the RowColumn widget should enforce a RadioBox-type behavior on all of its children that are ToggleButtons or ToggleButtonGadgets. πŸ“»

When the value of this resource is True, XmNindicatorType defaults to XmONE_OF_MANY for ToggleButton and ToggleButtonGadget children.

RadioBox behavior dictates that when one toggle is selected and the user selects another toggle, the first toggle is unselected automatically. The RowColumn usually does not enforce this behavior if the application, rather than the user, changes the state of a toggle. The RowColumn does enforce this behavior if a toggle child is selected with XmToggleButtonSetState or XmToggleButtonGadgetSetState with a notify argument of True.

When XmCreateRadioBox is called, the default value of XmNradioBehavior is True. Otherwise, the default value is False.


XmNresizeHeight

Requests a new height if necessary, when set to True. When this resource is set to False, the widget does not request a new height regardless of any changes to the widget or its children. πŸ“

XmNresizeWidth

Requests a new width if necessary, when set to True. When set to False, the widget does not request a new width regardless of any changes to the widget or its children. πŸ“


XmNrowColumnType

Specifies the type of RowColumn widget to be created. It is a nonstandard resource that cannot be changed after it is set. If an application uses any of the convenience routines, except XmCreateRowColumn, this resource is automatically forced to the appropriate value by the convenience routine. If an application uses the Xt Intrinsics API to create its RowColumn widgets, it must specify this resource itself. The set of possible settings for this resource are

  • XmWORK_AREA (default)
  • XmMENU_BAR
  • XmMENU_PULLDOWN
  • XmMENU_POPUP
  • XmMENU_OPTION
🚨 This resource cannot be changed after the RowColumn widget is created. Any changes attempted through XtSetValues are ignored. Periodt.

The value of this resource is used to determine the value of a number of other resources. The descriptions of RowColumn resources explain this when it is the case. The resource XmNnavigationType, inherited from XmManager, is changed to XmNONE if XmNrowColumnType is XmMENU_OPTION.


XmNspacing

Specifies the horizontal and vertical spacing between items contained within the RowColumn widget. The default value is 3 pixels for XmOPTION_MENU and XmWORK_AREA and 0 (zero) for other RowColumn types. 🫢


XmNsubMenuId

Specifies the widget ID for the Pulldown menu pane to be associated with an OptionMenu. This resource is useful only when XmNrowColumnType is set to XmMENU_OPTION. The default value is NULL.


XmNtearOffMenuActivateCallback

Specifies the callback list that notifies the application when the tear-off menu pane is about to be activated. It precedes the tear-off's map callback.

Use this resource when your application has shared menu panes and when the torn-off menu can have two or more parents that can have opposing sensitivity states for the same menu item. This resource enables the application to track whether a menu item is sensitive or insensitive and to set the state to the original parent's menu item state when the torn-off menu is reposted. The application can use XmGetPostedFromWidget to determine from which parent the menu was torn. The callback reason is XmCR_TEAR_OFF_ACTIVATE. The default is NULL.


XmNtearOffMenuDeactivateCallback

Specifies the callback list that notifies the application when the tear-off menu pane is about to be deactivated. It follows the tear-off's unmap callback.

Use this resource when your application has shared menu panes and when the torn-off menu can have two or more parents that can have opposing sensitivity states for the same menu item. This resource enables the application to track whether a menu item is sensitive or insensitive and to set the state to the original parent's menu item state when the torn-off menu is reposted. The application can use XmGetPostedFromWidget to determine from which parent the menu was torn. The callback reason is XmCR_TEAR_OFF_DEACTIVATE. The default is NULL.


XmNtearOffModel

Indicates whether tear-off functionality is enabled or disabled when XmNrowColumnType is set to XmMENU_PULLDOWN or XmMENU_POPUP. The values are XmTEAR_OFF_ENABLED or XmTEAR_OFF_DISABLED (default value). This resource is invalid for type XmMENU_OPTION; however, it does affect any pulldown submenus within an OptionMenu. The function XmRepTypeInstallTearOffModelConverter installs a resource converter for this resource.


XmNtearoffTitle

Used by the TearOff shell to set the title for the window manager to display. πŸŽ€


XmNunmapCallback

Specifies a list of callbacks that is called after the window associated with the RowColumn widget has been unmapped. The callback reason is XmCR_UNMAP. The default value is NULL.


XmNwhichButton

πŸ’€ This resource is obsolete; it has been replaced by XmNmenuPost and is present for compatibility with older releases of Motif. This resource cannot be 2.

✨ XmRowColumn Constraint Resource Set ✨

  • Name: XmNpositionIndex
  • Class: XmCPositionIndex
  • Type: short
  • Default: XmLAST_POSITION
  • Access: CSG

XmNpositionIndex

Specifies the position of the widget in its parent's list of children (the value of the XmNchildren resource). The value is an integer that is no less than 0 (zero) and no greater than the number of children in the list at the time the value is specified. A value of 0 (zero) means that the child is placed at the beginning of the list. The value can also be specified as XmLAST_POSITION (the default), which means that the child is placed at the end of the list. Any other value is ignored. XtGetValues returns the position of the widget in its parent's child list at the time of the call to XtGetValues.

When a widget is inserted into its parent's child list, the positions of any existing children that are greater than or equal to the specified widget's XmNpositionIndex are increased by 1. The effect of a call to XtSetValues for XmNpositionIndex is to remove the specified widget from its parent's child list, decrease by 1 the positions of any existing children that are greater than the specified widget's former position in the list, and then insert the specified widget into its parent's child list as described in the preceding sentence. πŸ”₯

πŸŽ€ Simple Menu Creation Resource Set πŸŽ€

Okay bestie, here's the whole roster laid out β€” every resource with its class, its type, its default, and its access level. Quick legend: the columns are Name, Class, Type, Default, and Access, and that C in the last column means create-time, iykyk. πŸ’…

  • XmNbuttonAccelerators β€” class XmCButtonAccelerators, type StringTable, default NULL, access C
  • XmNbuttonAcceleratorText β€” class XmCButtonAcceleratorText, type XmStringTable, default NULL, access C
  • XmNbuttonCount β€” class XmCButtonCount, type int, default 0, access C
  • XmNbuttonMnemonicCharSets β€” class XmCButtonMnemonicCharSets, type XmStringCharSetTable, default NULL, access C
  • XmNbuttonMnemonics β€” class XmCButtonMnemonics, type XmKeySymTable, default NULL, access C
  • XmNbuttons β€” class XmCButtons, type XmStringTable, default NULL, access C
  • XmNbuttonSet β€” class XmCButtonSet, type int, default -1, access C
  • XmNbuttonType β€” class XmCButtonType, type XmButtonTypeTable, default NULL, access C
  • XmNoptionLabel β€” class XmCOptionLabel, type XmString, default NULL, access C
  • XmNoptionMnemonic β€” class XmCOptionMnemonic, type KeySym, default NULL, access C
  • XmNpostFromButton β€” class XmCPostFromButton, type int, default -1, access C
  • XmNsimpleCallback β€” class XmCCallback, type XtCallbackProc, default NULL, access C

πŸ’– XmNbuttonAccelerators

This one's for the simple menu creation routines. It's the list of accelerators for the buttons you're creating β€” and bestie, the list holds one element for each button, separator, and title created. No skipping, no shortcuts. ✨

πŸ’– XmNbuttonAcceleratorText

Also for the simple menu creation routines. This is the list of compound strings to actually display for the accelerators on the buttons you created. Same deal as above: one element for each button, separator, and title created. 🌸

πŸ’– XmNbuttonCount

Simple menu creation routines again, and this one's the big one β€” it's the total number of menu buttons, separators, and titles to create. Heads up: the value must not be negative. πŸ™ˆ

πŸ’– XmNbuttonMnemonicCharSets

Simple menu creation routines! This specifies a list of character sets that the button mnemonics get displayed with. One element for each button, separator, and title created, bestie. And plot twist β€” the default isn't fixed, it's determined dynamically based on the locale of the widget. She adapts. πŸ’…

πŸ’– XmNbuttonMnemonics

Simple menu creation routines, yep. It's the list of mnemonics for the buttons created, with one element for each button, separator, and title created. 🌈

πŸ’– XmNbuttons

Simple menu creation routines! This is your list of compound strings used as labels for the buttons created β€” one element for each button, separator, and title created. This is the one that makes everything look cute. πŸŽ€

πŸ’– XmNbuttonSet

Simple menu creation routines, and this one picks which button of a RadioBox or OptionMenu Pulldown submenu is initially set. The value is an integer n pointing at the *n*th ToggleButtonGadget specified for a RadioBox, or the *n*th PushButtonGadget specified for an OptionMenu Pulldown submenu. First button specified is number 0. And the value must not be negative. (Yes, the default in the table up there is -1 while the rule says no negatives β€” I'm just the messenger, not the vibe police. πŸ™ˆ)

πŸ’– XmNbuttonType

Simple menu creation routines. It's a list of button types tied to the buttons you're creating, one element for each button, separator, and title created. If you don't specify it, here's what you get by default:

  • every button in a MenuBar is a CascadeButtonGadget
  • every button in a RadioBox or CheckBox is a ToggleButtonGadget
  • every button in any other type of RowColumn widget is a PushButtonGadget

Each button type is of type XmButtonType, an enumeration, and here are the possible values, no cap:

  • XmCASCADEBUTTON β€” Specifies a CascadeButtonGadget for a MenuBar, Popup menu pane, or Pulldown menu pane.
  • XmCHECKBUTTON β€” Specifies a ToggleButtonGadget for a CheckBox, Popup menu pane, or Pulldown menu pane.
  • XmDOUBLE_SEPARATOR β€” Specifies a SeparatorGadget for a Popup menu pane, Pulldown menu pane, or OptionMenu Pulldown submenu. The separator type is XmDOUBLE_LINE.
  • XmPUSHBUTTON β€” Specifies a PushButtonGadget for a Popup menu pane, Pulldown menu pane, or OptionMenu Pulldown submenu.
  • XmRADIOBUTTON β€” Specifies a ToggleButtonGadget for a RadioBox, Popup menu pane, or Pulldown menu pane.
  • XmSEPARATOR β€” Specifies a SeparatorGadget for a Popup menu pane, Pulldown menu pane, or OptionMenu Pulldown submenu.
  • XmTITLE β€” Specifies a LabelGadget used as a title for a Popup menu pane or Pulldown menu pane.

πŸ’– XmNoptionLabel

Simple menu creation routines. It's a compound string for the label string that goes on the left side of an OptionMenu. Main character positioning, honestly. πŸ‘‘

πŸ’– XmNoptionMnemonic

Simple menu creation routines. This specifies a keysym for a key that β€” when the user presses it together with the MAlt modifier β€” posts the associated Pulldown menu pane for an OptionMenu. Keyboard shortcuts, slay. ⌨️✨

πŸ’– XmNpostFromButton

Simple menu creation routines. For a Pulldown menu pane, this tells you which button in the parent the submenu is attached to, and the menu then posts from that button. The value is an integer n pointing at the *n*th CascadeButton or CascadeButtonGadget specified for the parent of the Pulldown menu pane. First button specified is number 0, and the value must not be negative. 🌟

  • XmNsimpleCallback β€” okay so this one is specifically for the simple menu creation routines, she's a specialty girlie πŸ’…. She names a callback procedure that gets called when a button is activated or when its value changes. This callback function gets added to each button after creation. For a CascadeButtonGadget or a PushButtonGadget, the callback is added as the button's XmNactivateCallback, and it fires when the button is activated. For a ToggleButtonGadget, it's added as the button's XmNvalueChangedCallback, and it fires when the button's value changes. The button number gets passed in the client_data field. Not the button itself, bestie β€” the number. iykyk 🫢

🌈 Inherited Resources 🌈

RowColumn is literally built different β€” she inherits behavior and resources from the superclasses listed in the tables below. For the full tea on each resource, go read the reference page for that superclass. ✨

πŸ¦‹ XmManager Resource Set πŸ¦‹

  • XmNbottomShadowColor β€” Class XmCBottomShadowColor, type Pixel, default dynamic, access CSG
  • XmNbottomShadowPixmap β€” Class XmCBottomShadowPixmap, type Pixmap, default XmUNSPECIFIED_PIXMAP, access CSG
  • XmNforeground β€” Class XmCForeground, type Pixel, default dynamic, access CSG
  • XmNhelpCallback β€” Class XmCCallback, type XtCallbackList, default NULL, access C
  • XmNhighlightColor β€” Class XmCHighlightColor, type Pixel, default dynamic, access CSG
  • XmNhighlightPixmap β€” Class XmCHighlightPixmap, type Pixmap, default dynamic, access CSG
  • XmNinitialFocus β€” Class XmCInitialFocus, type Widget, default NULL, access CSG
  • XmNlayoutDirection β€” Class XmCLayoutDirection, type XmDirection, default dynamic, access CG
  • XmNnavigationType β€” Class XmCNavigationType, type XmNavigationType, default dynamic, access CSG
  • XmNpopupHandlerCallback β€” Class XmCCallback, type XtCallbackList, default NULL, access C
  • XmNshadowThickness β€” Class XmCShadowThickness, type Dimension, default dynamic, access CSG
  • XmNstringDirection β€” Class XmCStringDirection, type XmStringDirection, default dynamic, access CG
  • XmNtopShadowColor β€” Class XmCTopShadowColor, type Pixel, default dynamic, access CSG
  • XmNtopShadowPixmap β€” Class XmCTopShadowPixmap, type Pixmap, default dynamic, access CSG
  • XmNtraversalOn β€” Class XmCTraversalOn, type Boolean, default dynamic, access CSG
  • XmNunitType β€” Class XmCUnitType, type unsigned char, default dynamic, access CSG
  • XmNuserData β€” Class XmCUserData, type XtPointer, default NULL, access CSG

πŸŽ€ Composite Resource Set πŸŽ€

  • XmNchildren β€” Class XmCReadOnly, type WidgetList, default NULL, access G
  • XmNinsertPosition β€” Class XmCInsertPosition, type XtOrderProc, default default procedure, access CSG
  • XmNnumChildren β€” Class XmCReadOnly, type Cardinal, default 0, access G
bestie the way these tables are just ✨vibes✨ β€” every single name, class, type, default and access code is right there, no cap. don't skip a row, they're all doing their little job πŸ’–

Core Resource Set πŸ‘‘

okay bestie, here's the whole core resource set, and she is long. The table said name, class, type, default, access β€” we're keeping every single one, no skips, no cap. πŸ’…

  • XmNaccelerators β€” class XmCAccelerators, type XtAccelerators, default dynamic, access CSG. πŸ’–
  • XmNancestorSensitive β€” class XmCSensitive, type Boolean, default dynamic, access G. πŸ’œ
  • XmNbackground β€” class XmCBackground, type Pixel, default dynamic, access CSG. ✨
  • XmNbackgroundPixmap β€” class XmCPixmap, type Pixmap, default XmUNSPECIFIED_PIXMAP, access CSG. πŸŽ€
  • XmNborderColor β€” class XmCBorderColor, type Pixel, default XtDefaultForeground, access CSG. 🌸
  • XmNborderPixmap β€” class XmCPixmap, type Pixmap, default XmUNSPECIFIED_PIXMAP, access CSG. πŸ¦‹
  • XmNborderWidth β€” class XmCBorderWidth, type Dimension, default 0, access CSG. ⭐
  • XmNcolormap β€” class XmCColormap, type Colormap, default dynamic, access CG. πŸ’™
  • XmNdepth β€” class XmCDepth, type int, default dynamic, access CG. πŸ’š
  • XmNdestroyCallback β€” class XmCCallback, type XtCallbackList, default NULL, access C. πŸ‘
  • XmNheight β€” class XmCHeight, type Dimension, default dynamic, access CSG. ❀️
  • XmNinitialResourcesPersistent β€” class XmCInitialResourcesPersistent, type Boolean, default True, access C. πŸ’–
  • XmNmappedWhenManaged β€” class XmCMappedWhenManaged, type Boolean, default True, access CSG. πŸ’œ
  • XmNscreen β€” class XmCScreen, type Screen *, default dynamic, access CG. ✨
  • XmNsensitive β€” class XmCSensitive, type Boolean, default True, access CSG. πŸŽ€
  • XmNtranslations β€” class XmCTranslations, type XtTranslations, default dynamic, access CSG. 🌸
  • XmNwidth β€” class XmCWidth, type Dimension, default dynamic, access CSG. πŸ¦‹
  • XmNx β€” class XmCPosition, type Position, default 0, access CSG. ⭐
  • XmNy β€” class XmCPosition, type Position, default 0, access CSG. πŸ’™

Callback Information πŸŽ€

A pointer to<|place_holder_mm_span_0442|> the following structure is passed to each callback, bestie:

typedef struct
{
        int reason;
        XEvent * event;
        Widget widget;
        char * data;
        char * callbackstruct;
} XmRowColumnCallbackStruct;
  • reason β€” Indicates why the callback was invoked. πŸ’­
  • event β€” Points to the XEvent that triggered the callback. πŸ”₯
The following fields apply only when the callback reason is XmCR_ACTIVATE; for all other callback reasons, these fields are set to NULL. The XmCR_ACTIVATE callback reason is generated only when the application has supplied an entry callback, which overrides any activation callbacks registered with the individual RowColumn items. 😭
  • widget β€” Is set to the widget ID of the RowColumn item that has been activated. πŸ‘‘
  • data β€” Contains the client-data value supplied by the application when the RowColumn item's activation callback was registered. πŸ“
  • callbackstruct β€” Points to the callback structure generated by the RowColumn item's activation callback. 🧚

Translations πŸ¦‹

XmRowColumn translations depend on the value of the XmNrowColumnType resource. iykyk.

If XmNrowColumnType is set to XmWORK_AREA, XmRowColumn inherits translations from XmManager. periodt. πŸ’…

If XmNrowColumnType is set to XmMENU_OPTION, bestie, XmRowColumn straight-up inherits its traversal, <osfActivate>, and <osfCancel> translations from XmManager β€” and then it's got these extra ones stacked on top: πŸ’…

Quick notation heads-up before you read these: those key names are written in the X standard key event translation table syntax. That's literally the format Motif uses to say which widget actions go off when you press a given key. There's a lil overview of the format over in VirtualBindings(3), and if you want the whole entire thing spelled out, go read the X Toolkit Intrinsics Documentation. πŸ“š

<Btn2Down>:
          MenuGadgetDrag()

c<Btn1Down>:
          MenuGadgetTraverseCurrent()

c<Btn1Up>:
          MenuGadgetTraverseCurrentUp()

∼c<BtnDown>:
          MenuBtnDown()

∼c<BtnUp>:
          MenuBtnUp()

:<Key><osfHelp>:
          MenuHelp()

And for XmRowColumn when XmNrowColumnType is XmMENU_BAR, XmMENU_PULLDOWN, or XmMENU_POPUP? Those translations are in the list below. Oh and β€” in a Popup menu system, <Btn3> also does the <Btn1> actions. just so you know. πŸ‘€

:<Key><osfHelp>:
          MenuHelp()

:<Key><osfLeft>:
          MenuGadgetTraverseLeft()

:<Key><osfRight>:
          MenuGadgetTraverseRight()

:<Key><osfUp>:
          MenuGadgetTraverseUp()

:<Key><osfDown>:
          MenuGadgetTraverseDown()

πŸŽ€ Action Routines πŸŽ€

The XmRowColumn action routines are these, and they're lowkey the whole personality of the widget:

Help()

Calls the callbacks for XmNhelpCallback if any exist. And if this widget has no help callbacks at all? Then it goes and calls the help callbacks of the nearest ancestor that does have them. Passing the buck, iconic. πŸ™ˆ

ManagerGadgetSelect()

When a gadget child of the menu has the focus, this invokes that gadget child's behavior associated with <osfSelect>. Generally this means unposting the menu hierarchy and arming + activating the gadget β€” except for a CascadeButtonGadget with a submenu, where it posts the submenu instead. Plot twist. ✨

When a gadget child of the menu has focus, this invokes the gadget child's behavior associated with <Btn1Down>. Generally that means: unposting any menus posted by the parent menu, enabling mouse traversal in the menu, and arming the gadget. And for a CascadeButtonGadget with a submenu, it also posts the associated submenu. multitasking queen. πŸ‘‘

When a gadget child of the menu has focus, this invokes the gadget child's behavior associated with <Btn1Up>. Generally: unposts the menu hierarchy and activates the gadget β€” except for a CascadeButtonGadget with a submenu, where it posts the submenu and enables keyboard traversal in the menu.

Okay this one has ✨situations✨:

  • In a top-level Pulldown MenuPane coming off a MenuBar, it unposts the menu, disarms the MenuBar CascadeButton and the MenuBar, and β€” when the shell's keyboard focus policy is XmEXPLICIT β€” restores keyboard focus to whatever widget had the focus before the MenuBar was entered. In other Pulldown MenuPanes, it just unposts the menu.
  • In a Popup MenuPane, it unposts the menu and, when the shell's keyboard focus policy is XmEXPLICIT, restores keyboard focus to the widget the menu was posted from.
  • In a TearOff MenuPane that has no submenus posted, it dismisses the menu. Otherwise, if one or more submenus are posted, it unposts the last menu pane.

If the current menu item has a submenu and it's in a MenuBar, then this action posts the submenu, disarms the current menu item, and arms the submenu's first traversable menu item.

If the current menu item is in a MenuPane, then this action disarms the current menu item and arms the item below it. This action wraps within the MenuPane, and the direction of that wrapping depends on the XmNlayoutDirection resource.

When the current menu item is in a MenuBar, this action disarms the current item and arms the MenuBar item to the left. This action wraps within the MenuBar.

In MenuPanes: if the current menu item is not at the left edge of a MenuPane, this action disarms the current item and arms the item to its left. If the current menu item is at the left edge of a submenu attached to a MenuBar item, then this action unposts the submenu and traverses to the MenuBar item to the left, wrapping if necessary. If that MenuBar item has a submenu, it posts the submenu and arms the first traversable item in the submenu. And if the current menu item is at the left edge of a submenu that is not directly attached to a MenuBar item, then this action unposts the current submenu only.

In Popup or Torn-off MenuPanes, when the current menu item is at the left edge, this action wraps within the MenuPane. If the current menu item is at the left edge of the MenuPane and not in the top row, this action wraps to the rightmost menu item in the row above. If the current menu item is in the upper, leftmost corner, this action wraps to the tear-off control, if present, or else it wraps to the bottom, rightmost menu item in the MenuPane.

All of the above applies when the XmNlayoutDirection horizontal direction is XmLEFT_TO_RIGHT. If the XmNlayoutDirection horizontal direction is XmRIGHT_TO_LEFT, then the following applies instead. πŸͺž

If the current menu item is in a MenuBar, then this action disarms the current item and arms the MenuBar item to the left. This action wraps within the MenuBar.

In MenuPanes, if the current menu item is a CascadeButton, then this action posts its associated submenu. If the current menu item is not a CascadeButton and is not at the left edge of a MenuPane, this action disarms the current item and arms the item to its left, wrapping if necessary. If the current menu item is not a CascadeButton and is at the left edge of a submenu that is a descendent of a MenuBar, then this action unposts all submenus and traverses to the MenuBar item to the left. If that MenuBar item has a submenu, it posts the submenu and arms the submenu's first traversable item.

In Popup or Torn-off menus, if the current menu item is not a CascadeButton and is at the left edge of a row (except the bottom row), this action wraps to the rightmost menu item in the row below. If the current menu item is not a CascadeButton and is in the bottom, leftmost corner of a Popup or Pulldown MenuPane, this action wraps to the tear-off control, if present, or else it wraps to the top, rightmost menu item of the MenuPane.

If the current menu item is in a MenuBar, then this action disarms the current item and arms the MenuBar item to the right. This action wraps within the MenuBar.

In MenuPanes, if the current menu item is a CascadeButton, then this action posts its associated submenu. If the current menu item is not a CascadeButton and is not at the right edge of a MenuPane, this action disarms the current item and arms the item to its right, wrapping if necessary. If the current menu item is not a CascadeButton and is at the right edge of a submenu that is a descendent of a MenuBar, then this action unposts all submenus and traverses to the MenuBar item to the right. If that MenuBar item has a submenu, it posts the submenu and arms the submenu's first traversable item.

In Popup or Torn-off menus, if the current menu item is not a CascadeButton and is at the right edge of a row (except the bottom row), this action wraps to the leftmost menu item in the row below. If the current menu item is not a CascadeButton and is in the bottom, rightmost corner of a Popup or Pulldown MenuPane, this action wraps to the tear-off control, if present, or else it wraps to the top, leftmost menu item of the MenuPane.

Same deal as before: everything above applies when the XmNlayoutDirection horizontal direction is XmLEFT_TO_RIGHT. If the XmNlayoutDirection horizontal direction is XmRIGHT_TO_LEFT, then the following applies instead. πŸ¦‹

When the current menu item is in a MenuBar, this action disarms the current item and arms the MenuBar item to the left. This action wraps within the MenuBar.

In MenuPanes, if the current menu item is not at the right edge of a MenuPane, this action disarms the current item and arms the item to its right. If the current menu item is at the right edge of a submenu attached to a MenuBar item, then this action unposts the submenu and traverses to the MenuBar item to the right, wrapping if necessary. If that MenuBar item has a submenu, it posts the submenu and arms the first traversable item in the submenu. If the current menu item is at the right edge of a submenu not directly attached to a MenuBar item, then this action unposts the current submenu only.

In Popup or Torn-off MenuPanes, when the current menu item is at the right edge, this action wraps within the MenuPane. If the current menu item is at the right edge of the MenuPane and not in the top row, this action wraps to the leftmost menu item in the row above. If the current menu item is in the upper, rightmost corner, this action wraps to the tear-off control, if present, or else it wraps to the bottom, leftmost menu item in the MenuPane.

When the current menu item is in a MenuPane, then this action disarms the current menu item and arms the item above it. This action wraps within the MenuPane. The direction of the wrapping depends on the XmNlayoutDirection resource. ⬆️


The following menu functions are available:

  • <osfMenuBar> β€” okay so this action is lowkey doing two different jobs depending on where you are, so listen up bestie:
    • In any non-popup descendant of a MenuBar's parent, excluding the MenuBar itself, this action enables keyboard traversal and moves keyboard focus to the first item in the MenuBar. ✨
    • In the MenuBar or any menu cascaded from it, this action unposts the menu hierarchy and, when the shell's keyboard focus policy is XmEXPLICIT, restores focus to the widget that had the focus when the menu system was entered. πŸ’…
  • <osfMenu> β€” the menu-popping one, iconic behaviour incoming:
    • Pops up the menu associated with the control that has the keyboard focus. Enables keyboard traversal in the menu. πŸŽ€
    • In the Popup menu system or any menu cascaded from it, this action unposts the menu hierarchy and, when the shell's keyboard focus policy is XmEXPLICIT, restores focus to the widget that had the focus when the menu system was entered. πŸ’–

✨ Virtual Bindings ✨

Real talk: the bindings for virtual keys are vendor specific β€” meaning it's giving "everyone did their own thing" energy, and that's just how it is. πŸ™ˆ

If you wanna know about bindings for virtual buttons and keys, go read VirtualBindings(3). That's the one, fr fr. πŸ¦‹


The whole ✨friend group✨ of pages that hang out with this one:


and that's a wrap on the whole entire page, bestie!! πŸŽ‰πŸ‘‘ this was part 10 of 10 and you ATE it, no crumbs. the footer down there says it's the XmRowColumn(library call) page β€” that's your source/version breadcrumb and the date stamp all rolled into one, so now you know exactly what you just read and where it came from. go forth and build menus, main character. πŸ’…πŸ«ΆπŸŒΈ