XMTABLISTGETTAB(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 πŸ’–

XmTabListGetTab β€” a convenience function that returns a copy of a tab. yes bestie, a copy, not the og tab itself, this matters so much, keep reading 🫢

This one lives in the library call section of the manual, iykyk.


✨ SYNOPSIS ✨

#include <Xm/Xm.h>
XmTab XmTabListGetTab(
XmTabList tablist,
Cardinal position);

πŸ¦‹ DESCRIPTION πŸ¦‹

Okay so XmTabListGetTab returns a copy of the tab that is located at the specified position in the tab list. That's the whole vibe. πŸ’…

  • tablist β€” specifies the tab list. it's giving "here's the list we're digging through" ✨
  • position β€” specifies the position of the tab to be returned. a value of 0 (zero) returns the first tab in the tab list, a value of 1 returns the second tab, and so on. so like… zero-indexed, bestie, the counting starts at zero, not one, do not come for me 😭

πŸŽ€ RETURN πŸŽ€

Returns a copy of the tab that is located at the specified position in the tab list.

But wait β€” plot twist: if position is greater than or equal to the number of tabs in the tab list, this function returns NULL. πŸ’€ no tab for you, that index does not exist.

🚨 Important, fr fr: the application is responsible for managing the space allocated by the returned tab copy. yes YOU, the app, you're the main character here and you own that memory. 🫢

The application can recover this allocated space by calling XmTabFree. clean up after yourself, it's the least you can do 🌸



okay that's the whole page, slay, go manage your memory responsibly πŸ‘‘

This has been XmTabListGetTab, a library call, brought to you by the good people who wrote the manual page β€” mwah, no cap, it ate. πŸ’–βœ¨πŸŽ€πŸ¦‹