XtAppError(3)

πŸ’– XtAppError(3) πŸ’–

ok so bestie, welcome to the XT FUNCTIONS corner of the manual β€” this one's all about low-level error handlers and honestly it's giving "the vibes are bad and someone needs to hear about it" ✨


✨ NAME ✨

XtAppError, XtAppSetErrorHandler, XtAppSetWarningHandler, XtAppWarning β€” low-level error handlers 🚨


🌸 SYNTAX 🌸

#include <X11/Intrinsic.h>

_X_NORETURN void XtAppError(XtAppContext app_context, const char
       *message);

XtErrorHandler XtAppSetErrorHandler(XtAppContext app_context,
       _X_NORETURN XtErrorHandler handler);

XtErrorHandler XtAppSetWarningHandler(XtAppContext app_context,
       XtErrorHandler handler);

void XtAppWarning(XtAppContext app_context, const char *message);

πŸŽ€ ARGUMENTS πŸŽ€

  • app_context β€” specifies the application context. it's the whole vibe of your app, basically πŸ’…
  • message β€” specifies the nonfatal error message that is to be reported. like, the thing you wanna say out loud πŸ“’
  • handler β€” specifies the new fatal error procedure, which should not return, or the nonfatal error procedure, which usually does return. so like... one of them leaves the party and never comes back, and the other one is just passing through πŸšͺ
  • message β€” specifies the message that is to be reported. (yes bestie, it's listed twice in the original and I'm keeping it twice, no notes 🫢)

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea on each of these πŸ’–

  • XtAppError calls the installed error procedure and passes the specified message. that's it. that's the function. dramatic, iconic, brief. πŸ‘‘
  • XtAppSetErrorHandler registers the specified procedure, which gets called when a fatal error condition occurs. like, this is the "we are NOT okay" hotline 🚨
  • XtAppSetWarningHandler registers the specified procedure, which gets called when a nonfatal error condition occurs. the "we're a little bit not okay but it's fine" hotline πŸ’›
  • XtAppWarning calls the installed nonfatal error procedure and passes the specified message. lowercase drama, same energy 🌈
fr fr β€” remember that a fatal handler is documented as not returning, so don't be out here writing one that tries to come back like it forgot its keys πŸ™ˆ

πŸ’œ SEE ALSO πŸ’œ


okay bestie that's the whole page, you ate it, no crumbs πŸ“βœ¨

X Version 11 Β· libXt 1.3.1 Β· mwah, love u, go read the other manpages πŸ’…πŸ¦‹πŸ’–

πŸ“¦ where this page comes from