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

πŸ’– XmStringTableProposeTablist πŸ’–

okay bestie, welcome to the XmStringTableProposeTablist glow-up, a lil library call from the Motif-adjacent Xm universe πŸŽ€


✨ NAME ✨

XmStringTableProposeTablist β€” a convenience function that returns a tab list. that's it, that's the job πŸ’…


🌸 SYNOPSIS 🌸

#include <Xm/Xm.h>
XmTabList XmStringTableProposeTablist(
XmStringTable strings,
Cardinal num_strings,
Widget widget,
float pad_value,
XmOffsetModel offset_model);

πŸ¦‹ DESCRIPTION πŸ¦‹

so here's the tea, fr fr: XmStringTableProposeTablist takes an XmStringTable structure stuffed with tabbed compound strings, plus some info about the padding between columns, plus some rendering info β€” and it hands you back a tab list. 🌈

and like, if you actually used that tab list to render the strings in the table? the strings would line up in columns. no overlap. none. πŸ’€ and with exactly the amount of padding you specified between the widest item in each column and the start of the next column. chef's kiss πŸ‘‘

each tab in the tablist would have:

  • the same unit type as units
  • an offset model of offset_model
  • an alignment type of XmALIGNMENT_BEGINNING

periodt. ✨

now the parameters, because we keep every single one, no skips, no cap:

  • strings β€” Specifies an array of compound strings.
  • num_strings β€” Specifies the number of compound strings in strings. like, the count. the vibe check of how many we're dealing with πŸ“
  • widget β€” Specifies the widget used for deriving any necessary information for creating the rendition. In particular, the XmNunitType of widget will be used to specify the unit type to be used in determining the amount of padding separating columns and for the tabs in the proposed tab list. Also, widget's render table will be used in interpreting rendition tags within the strings. she's the main character here, honestly πŸ’œ
  • pad_value β€” Specifies the value of the amount of padding to be used to separate columns. The units for this parameter are specified as the XmNunitType set for the widget parameter. Refer to the XmNunitType resource of the XmGadget, XmManager, or XmPrimitive reference page. (iykyk 🫢)
  • offset_model β€” Specifies the offset model to be used in creating the tabs. Can be XmABSOLUTE or XmRELATIVE. pick one, bestie, those are the options πŸ”₯

πŸ’« RETURN πŸ’«

Returns a new XmTabList. πŸ’–

okay important bit, don't skip: the function allocates space to hold the returned tab list. the application is responsible for managing the allocated space. and the application can recover the allocated space by calling XmTabListFree.

so like… that memory is YOURS now. take care of her. 😭

not you leaking memory because you forgot XmTabListFree… couldn't be you, right? πŸ™ˆ


and that's the whole page, bestie!! 🧚 the header up top said XmStringTa...poseTablist(library call) and the footer said the exact same thing β€” XmStringTa...poseTablist(library call) β€” so if you were looking for version/date deets, the page is keeping that mysterious. iconic behavior honestly ⭐ go forth and align your columns, you absolute legend πŸ‘‘βœ¨