XMSTRINGDRAWUNDERLINE(3)
π XmStringDrawUnderline π
okay bestie, so this one is XmStringDrawUnderline(library call) and it's literally the glow-up button for your compound strings, no cap β¨
β¨ NAME β¨
XmStringDrawUnderline β a compound string function that underlines a string drawn in an X Window. it's giving "put a lil line under the important part" energy π
πΈ SYNOPSIS πΈ
#include <Xm/Xm.h>
void XmStringDrawUnderline(
Display * d,
Window w,
XmRenderTable rendertable,
XmString string,
GC gc,
Position x,
Position y,
Dimension width,
unsigned char alignment,
unsigned char layout_direction,
XRectangle * clip,
XmString underline);
like yes, that's a lot of arguments, but she's worth it π«Ά
π¦ DESCRIPTION π¦
XmStringDrawUnderline draws a compound string in an X Window. and here's the cute part: if the substring identified by underline can be matched inside string, that substring gets underlined. π once a match has happened, no further matches or underlining will be done β one and done, she said periodt. also, only the first text component of underline is used for matching. just the first one. iykyk.
β οΈ okay real talk, this next bit matters so pay attention bestie. if a compound string segment uses a rendition that contains a font set, the graphic context you pass to this routine will have the GC font member left in an undefined state. the underlying XmbStringDraw function called by this routine modifies the font ID field of the GC passed into it and does not attempt to restore the font ID to the incoming value. π no restoration, no apology.
if the compound string segment is not drawn using a font set, the graphic context must contain a valid font member. and graphic contexts created by XtGetGC are not accepted by this routine β instead, use XtAllocateGC to create a graphic context. do not come in here with an XtGetGC GC, she will not open the door π
the arguments, one by one, slay by slay π
dβ Specifies the display.wβ Specifies the window.rendertableβ Specifies the render table.stringβ Specifies the string.gcβ Specifies the graphics context to use.xβ Specifies a coordinate of the rectangle that will contain the displayed compound string.yβ Specifies a coordinate of the rectangle that will contain the displayed compound string.widthβ Specifies the width of the rectangle that will contain the displayed compound string.alignmentβ Specifies how the string will be aligned within the specified rectangle. It is one ofXmALIGNMENT_BEGINNING,XmALIGNMENT_CENTER, orXmALIGNMENT_END. pick your fighter πlayout_directionβ Controls the direction in which the segments of the compound string will be laid out. It also determines the meaning of thealignmentparameter. so yeah, these two are besties, they communicate πclipβ Allows the application to restrict the area into which the compound string will be drawn. If it isNULL, clipping will be determined by the GC.underlineβ Specifies the substring to be underlined. the main character of this whole function, fr fr β
π§ RELATED π§
and that's the whole vibe, babe π this page was XmStringDrawUnderline(library call) β straight from the library call section of the manual, no date stamp drama, just pure Motif realness. go underline something iconic and stay hydrated πβ¨
π¦ 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