<!-- $XConsortium: TxtFindB.sgm /main/9 1996/09/25 14:51:45 cdedoc $ -->
<!-- (c) Copyright 1995 Digital Equipment Corporation. -->
<!-- (c) Copyright 1995 Hewlett-Packard Company. -->
<!-- (c) Copyright 1995 International Business Machines Corp. -->
<!-- (c) Copyright 1995 Sun Microsystems, Inc. -->
<!-- (c) Copyright 1995 Novell, Inc. -->
<!-- (c) Copyright 1995 FUJITSU LIMITED. -->
<!-- (c) Copyright 1995 Hitachi. -->

<RefEntry Id="CDEMMA.MAN510.rsml.1">
<RefMeta>
<RefEntryTitle>XmTextFindStringWcs</RefEntryTitle>
<ManVolNum>library call</ManVolNum>
</RefMeta>
<RefNameDiv>
<RefName><Function>XmTextFindStringWcs</Function></RefName>
<RefPurpose>A Text function that finds the beginning
position of a wide character text string
<IndexTerm>
<Primary>XmTextFindStringWcs</Primary>
</IndexTerm><IndexTerm>
<Primary>Text functions</Primary>
<Secondary>XmTextFindStringWcs</Secondary>
</IndexTerm></RefPurpose>
</RefNameDiv>
<!-- -->
<!-- @OSF_COPYRIGHT@-->
<!-- COPYRIGHT NOTICE-->
<!-- Copyright (c) 1990, 1991, 1992, 1993 Open Software Foundation, Inc.-->
<!-- ALL RIGHTS RESERVED (MOTIF). See the file named COPY.MOTIF.DOC for-->
<!-- the full copyright text.-->
<!-- -->
<!-- HISTORY-->
<!-- -->
<!-- **-->
<!-- **-->
<!-- **  (c) Copyright 1989, 1990, 1992 by Open Software Foundation, Inc.-->
<!-- **      All Rights Reserved.-->
<!-- **-->
<!-- **  (c) Copyright 1987, 1988, 1989, by Hewlett-Packard Company-->
<!-- **-->
<!-- **  (c) Copyright 1987, 1988 by Digital Equipment Corporation,-->
<!-- **      Maynard, MA.  All Rights Reserved.-->
<!-- **-->
<!-- **-->
<RefSynopsisDiv>
<FuncSynopsis>
<FuncSynopsisInfo>#include &lt;Xm/Text.h>
</FuncSynopsisInfo>
<FuncDef>Boolean <Function>XmTextFindStringWcs</Function></FuncDef>
<!--<ParamDef><Replaceable>widget, start, wcstring, direction, position</Replaceable></ParamDef>-->
<ParamDef>Widget <Parameter>widget</Parameter></ParamDef>
<ParamDef>XmTextPosition <Parameter>start</Parameter></ParamDef>
<ParamDef>wchar_t *<Parameter>wcstring</Parameter></ParamDef>
<ParamDef>XmTextDirection <Parameter>direction</Parameter></ParamDef>
<ParamDef>XmTextPosition *<Parameter>position</Parameter></ParamDef>
</FuncSynopsis>
</RefSynopsisDiv>
<RefSect1>
<Title>DESCRIPTION</Title>
<Para><Function>XmTextFindStringWcs</Function> locates the beginning position of a specified
wide character text string. This routine searches forward or backward
for the first occurrence of the string, starting from the given start
position.
<!--&bsol;" apparently the code doesn't do this
If a match is not found, the search wraps to the beginning
of the buffer (or to the end when &bsol;*Vdirection&bsol;*O is &bsol;*LXmTEXT_BACKWARD&bsol;*O)
and continues to the initial start position.
-->If a match is found, the
function returns the position of the first character of the string
in <Symbol Role="Variable">position</Symbol>.
If the match string begins at the current position, this routine returns the current position.</Para>
<VariableList>
<VarListEntry>
<Term><Symbol Role="Variable">widget</Symbol></Term>
<ListItem>
<Para>Specifies the Text widget ID.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Symbol Role="Variable">start</Symbol></Term>
<ListItem>
<Para>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 is 0 (zero).
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Symbol Role="Variable">wcstring</Symbol></Term>
<ListItem>
<Para>Specifies the wide character search string.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Emphasis>direction</Emphasis></Term>
<ListItem>
<Para>Indicates the search direction. It is relative to the primary direction
of the text. The possible values are
</Para>
<VariableList>
<VarListEntry>
<Term><SystemItem Class="Constant">XmTEXT_FORWARD</SystemItem></Term>
<ListItem>
<Para>The search proceeds toward the end of the buffer.
</Para>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><SystemItem Class="Constant">XmTEXT_BACKWARD</SystemItem></Term>
<ListItem>
<Para>The search proceeds toward the beginning of the buffer.
</Para>
</ListItem>
</VarListEntry>
</VariableList>
</ListItem>
</VarListEntry>
<VarListEntry>
<Term><Symbol Role="Variable">position</Symbol></Term>
<ListItem>
<Para>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 is 0 (zero). If the function
returns False, this value is undefined.
</Para>
</ListItem>
</VarListEntry>
</VariableList>
<Para>For a complete definition of Text and its associated resources,
see &cdeman.XmText;.
</Para>
</RefSect1>
<RefSect1>
<Title>RETURN</Title>
<Para>Returns True if a string match is found; otherwise, returns False.
</Para>
</RefSect1>
<RefSect1>
<Title>RELATED</Title>
<Para>&cdeman.XmText; and &cdeman.XmTextFindString;.
</Para>
</RefSect1>
</RefEntry>
<!--fickle 1.09 7/2/95-->
