XMCREATEMENUBAR(3)
β¨ NAME β¨
XmCreateMenuBar β bestie, it's a RowColumn widget convenience creation function π (yes that's a mouthful, we'll get through it together)
πΈ SYNOPSIS πΈ
#include <Xm/RowColumn.h>
Widget XmCreateMenuBar(
Widget parent,
String name,
ArgList arglist,
Cardinal argcount);
π DESCRIPTION π
okay so XmCreateMenuBar makes you an instance of a RowColumn widget, specifically of type XmMENU_BAR, and hands you back the widget ID like it's your lil drink order π₯€. It's literally just a convenience function for spinning up RowColumn widgets that are configured to act as a MenuBar β and no cap, it is not implemented as its own separate widget class. It's giving "same girl, different outfit."
The MenuBar widget is generally what you use for building a Pulldown menu system. The vibe is: you create a MenuBar, plop it along the top of your application window, and then insert several CascadeButtons as its children. Each one of those CascadeButtons has a Pulldown menu pane associated with it π. Important tho β those Pulldown menu panes must have been created as children of the MenuBar. That's the rule, periodt. Your user interacts with the MenuBar using either the mouse or the keyboard, their choice, main character energy either way.
The MenuBar shows a 3-D shadow along its border β¨. The application is the one controlling the shadow attributes, using the visual-related resources that XmManager supports.
Now here's the tea π: the MenuBar widget is homogeneous, meaning it only accepts children that are a subclass of XmCascadeButton or XmCascadeButtonGadget. Try to insert a child of a different class and you get a warning message. It said no strangers allowed π.
And if the MenuBar doesn't have enough room to fit all of its subwidgets on a single line, it will attempt to wrap the remaining entries onto additional lines β but only if the geometry manager of the parent widget allows it. Fingers crossed, iykyk π.
parentβ specifies the parent widget IDnameβ specifies the name of the created widgetarglistβ specifies the argument listargcountβ specifies the number of attribute/value pairs in the argument list (arglist)
For the full definition of RowColumn and all its associated resources, go peek at XmRowColumn(3). It's the source material fr fr π.
π¦ RETURN π¦
Returns the RowColumn widget ID. That's it, that's the gift π.
π RELATED π
XmCascadeButton(3)XmCascadeButtonGadget(3)XmCreatePulldownMenu(3)XmCreateSimpleMenuBar(3)XmManager(3)XmRowColumn(3)XmVaCreateSimpleMenuBar(3)
okay bestie that's the whole page π This lil masterpiece lives in the library call manual section, and it's signed off as XmCreateMenuBar(library call) β so if you ever need to cite it, that's your source and your version tag, mwah π go build something iconic π
π¦ where this page comes from
- alpine 3.24: motif-doc 2.5.2-r0 Β· LGPL-2.1-or-later
- arch rolling: openmotif 2.3.8-4 Β· LGPL-2.1-or-later
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- centos-stream 9: motif-devel 2.3.4-32.el9 Β· LGPLv2+
- epel 10: motif-devel 2.3.8-2.el10_2 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-1.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 43: motif-devel 2.3.8-2.fc43 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- fedora 44: motif-devel 2.3.8-3.fc44 Β· LicenseRef-Callaway-LGPLv2+
- nixos 26.05: motif 2.3.8
- nixpkgs unstable: motif 2.3.8
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- opensuse-leap 16.0: motif-devel 2.3.8-bp160.1.1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms