GQSGUS(3NCARG)

πŸ“¦ version 6.6.2, in epel 9, fedora 43, fedora 44

πŸ’– GQSGUS β€” the "who's on the guest list rn?" of NCAR Graphics πŸ’–

(that's a 3NCARG manual page, bestie β€” Inquire set of segment names in use)

okay so real talk, this one is genuinely one of the most useful little routines in the whole GKS friend group. GQSGUS literally retrieves what segment names are currently in use. that's it. that's the whole job. and it ate. πŸ’…


✨ SYNOPSIS ✨

CALL GQSGUS(N,ERRIND,OL,SGNA)

πŸ¦‹ C-BINDING SYNOPSIS πŸ¦‹

#include <ncarg/gks.h>

void ginq_set_seg_names(Gint num_elems_appl_list, Gint start_pos, Gint
*err_ind, Gint_list *seg_names, Gint *length_list);

🌸 DESCRIPTION 🌸

bestie, let's go through the whole squad one by one, no skipping:

  • N (Integer, Input) β€” the set member you're asking for. like, which one in the list, girl. πŸ‘‘
  • ERRIND (Integer, Output) β€” the vibe check result. if the GKS state is WSOP (workstation open), WSAC (workstation active), or SGOP (segment open), then ERRIND comes back as "0" β€” slay, we're good. otherwise ERRIND comes back as "7" and, um, not slay. 😭
  • OL (Integer, Output) β€” literally just how many segment names are currently in use. the headcount. the number of girlies at the function. πŸ’€
  • SGNA (Integer, Output) β€” the actual name, the main character herself. if the GKS state is WSOP (workstation open), WSAC (workstation active), or SGOP (segment open), and if OL is larger than zero, then SGNA is returned as the name in the *N*th element of the list of segment names that are currently in use. otherwise? SGNA is undefined β€” like, it's not ghosting you on purpose, it just genuinely does not exist. πŸ™ˆ

πŸŽ€ USAGE πŸŽ€

for NCAR GKS, segment names are integers between 0 and 99 inclusive β€” go peek at the man page for GCRSG if you need the receipts. iykyk.

so, you want the whole list of every segment name currently in use? here's the routine, step by step, no cap:

  1. first, figure out how many segment names are in use β€” make an initial call to GQSGUS with a first argument of "1". 🫢
  2. if ERRIND comes back as "0", then OL will tell you how many segments are currently in use. periodt.
  3. then, to get the actual list of all segment names currently in use, call GQSGUS in a loop on N from 1 to OL, and retrieve the N values of SGNA returned from such calls. boom. the whole guest list. πŸ”₯
not me telling you to loop β€” yes bestie, you literally loop, that's the move, that's the whole vibe.

🌈 ACCESS 🌈

to use GKS routines, load the NCAR GKS-0A library ncarg_gks. load her. let her in. πŸ’œ


⭐ SEE ALSO ⭐

Online: gevtm, gactm, gclsg, gcrsg, gcsgwk, gqopsg, gdsg, gssgt., ginq_set_seg_names

Hardcopy: "User's Guide for NCAR GKS-0A Graphics"

(go read those too, they're all part of the same friend group, it's giving ✨lore✨)


Copyright (C) 1987-2009 University Corporation for Atmospheric Research

The use of this Software is governed by a License Agreement.

okay so legally i have to be the responsible one here: that license agreement is not a vibe suggestion, it's real. respect her. πŸ’–

and that's the page!! πŸ¦‹ from the UNIX girlies, March 1993, on the GQSGUS(3NCARG) tip β€” mwah, go get those segment names, bestie, you're gonna eat πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from