XMTEXTFINDSTRING(3)
β¨ NAME β¨
okay so bestie, this is XmTextFindString β a Text function that finds the beginning position of a text string π it's giving "where in this whole buffer does my lil string start", and honestly? iconic.
π SYNOPSIS π
#include <Xm/Xm.h>
Boolean XmTextFindString(
Widget widget,
XmTextPosition start,
char *string,
XmTextDirection direction,
XmTextPosition *position);
π DESCRIPTION π
XmTextFindString locates the beginning position of a specified text string. no cap, that's the whole job π«Ά
This routine searches forward or backward for the first occurrence of the string, starting from the given start position. If it finds a match, the function returns the position of the first character of the string in position. and here's a lil detail that lowkey matters: if the match string begins at the current position, this routine returns the current position. like, yes, right where you're standing counts π
widgetβ Specifies the Text widget ID. that's your main character, the Text widget in question πstartβ Specifies the character position from which the search proceeds. This is an integer number of characters from the beginning of the text buffer. The first character position is0(zero). zero-indexed, as the ancients intended β¨stringβ Specifies the search string. the thing you're hunting for πdirectionβ Indicates the search direction. It is relative to the primary direction of the text. The possible values are:XmTEXT_FORWARDβ The search proceeds toward the end of the text buffer. going forward bestie, onwards and upwards πXmTEXT_BACKWARDβ The search proceeds toward the beginning of the text buffer. rewinding, scrolling back, nostalgic vibe π¦
positionβ Specifies the pointer in which the first character position of the string match is returned. This is an integer number of characters from the beginning of the buffer. The first character position is0(zero). If the function returnsFalse, this value is undefined.
π¨ bestie listen β if the function returnsFalse,positionis undefined. don't be out here reading it anyway. that's not a vibe, that's undefined behavior territory π
For a complete definition of Text and its associated resources, see XmText(3).
πΈ RETURN πΈ
Returns True if a string match is found; otherwise, returns False. found it = True, no luck = False, periodt π
π§ RELATED π§
okay that's the whole page, we ate and left no crumbs π this was XmTextFindString(library call) β yes the manpage footer literally just says the same thing again, the library call title, cute of it, love that for us π go forth and find your strings, bestie π
π¦ 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