|
Packit |
5bd3a9 |
'\" t
|
|
Packit |
5bd3a9 |
.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991, 1994, 1996 X Consortium
|
|
Packit |
5bd3a9 |
.\" Copyright \(co 2000 The XFree86 Project, Inc.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" Permission is hereby granted, free of charge, to any person obtaining
|
|
Packit |
5bd3a9 |
.\" a copy of this software and associated documentation files (the
|
|
Packit |
5bd3a9 |
.\" "Software"), to deal in the Software without restriction, including
|
|
Packit |
5bd3a9 |
.\" without limitation the rights to use, copy, modify, merge, publish,
|
|
Packit |
5bd3a9 |
.\" distribute, sublicense, and/or sell copies of the Software, and to
|
|
Packit |
5bd3a9 |
.\" permit persons to whom the Software is furnished to do so, subject to
|
|
Packit |
5bd3a9 |
.\" the following conditions:
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" The above copyright notice and this permission notice shall be included
|
|
Packit |
5bd3a9 |
.\" in all copies or substantial portions of the Software.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
|
Packit |
5bd3a9 |
.\" OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
|
Packit |
5bd3a9 |
.\" MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
|
|
Packit |
5bd3a9 |
.\" IN NO EVENT SHALL THE X CONSORTIUM BE LIABLE FOR ANY CLAIM, DAMAGES OR
|
|
Packit |
5bd3a9 |
.\" OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
|
|
Packit |
5bd3a9 |
.\" ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
|
|
Packit |
5bd3a9 |
.\" OTHER DEALINGS IN THE SOFTWARE.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" Except as contained in this notice, the name of the X Consortium shall
|
|
Packit |
5bd3a9 |
.\" not be used in advertising or otherwise to promote the sale, use or
|
|
Packit |
5bd3a9 |
.\" other dealings in this Software without prior written authorization
|
|
Packit |
5bd3a9 |
.\" from the X Consortium.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" Copyright \(co 1985, 1986, 1987, 1988, 1989, 1990, 1991 by
|
|
Packit |
5bd3a9 |
.\" Digital Equipment Corporation
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" Portions Copyright \(co 1990, 1991 by
|
|
Packit |
5bd3a9 |
.\" Tektronix, Inc.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\" Permission to use, copy, modify and distribute this documentation for
|
|
Packit |
5bd3a9 |
.\" any purpose and without fee is hereby granted, provided that the above
|
|
Packit |
5bd3a9 |
.\" copyright notice appears in all copies and that both that copyright notice
|
|
Packit |
5bd3a9 |
.\" and this permission notice appear in all copies, and that the names of
|
|
Packit |
5bd3a9 |
.\" Digital and Tektronix not be used in in advertising or publicity pertaining
|
|
Packit |
5bd3a9 |
.\" to this documentation without specific, written prior permission.
|
|
Packit |
5bd3a9 |
.\" Digital and Tektronix makes no representations about the suitability
|
|
Packit |
5bd3a9 |
.\" of this documentation for any purpose.
|
|
Packit |
5bd3a9 |
.\" It is provided ``as is'' without express or implied warranty.
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.\"
|
|
Packit |
5bd3a9 |
.ds xT X Toolkit Intrinsics \- C Language Interface
|
|
Packit |
5bd3a9 |
.ds xW Athena X Widgets \- C Language X Toolkit Interface
|
|
Packit |
5bd3a9 |
.ds xL Xlib \- C Language X Interface
|
|
Packit |
5bd3a9 |
.ds xC Inter-Client Communication Conventions Manual
|
|
Packit |
5bd3a9 |
.na
|
|
Packit |
5bd3a9 |
.de Ds
|
|
Packit |
5bd3a9 |
.nf
|
|
Packit |
5bd3a9 |
.\\$1D \\$2 \\$1
|
|
Packit |
5bd3a9 |
.ft CW
|
|
Packit |
5bd3a9 |
.\".ps \\n(PS
|
|
Packit |
5bd3a9 |
.\".if \\n(VS>=40 .vs \\n(VSu
|
|
Packit |
5bd3a9 |
.\".if \\n(VS<=39 .vs \\n(VSp
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.de De
|
|
Packit |
5bd3a9 |
.ce 0
|
|
Packit |
5bd3a9 |
.if \\n(BD .DF
|
|
Packit |
5bd3a9 |
.nr BD 0
|
|
Packit |
5bd3a9 |
.in \\n(OIu
|
|
Packit |
5bd3a9 |
.if \\n(TM .ls 2
|
|
Packit |
5bd3a9 |
.sp \\n(DDu
|
|
Packit |
5bd3a9 |
.fi
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.de IN \" send an index entry to the stderr
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.de Pn
|
|
Packit |
5bd3a9 |
.ie t \\$1\fB\^\\$2\^\fR\\$3
|
|
Packit |
5bd3a9 |
.el \\$1\fI\^\\$2\^\fP\\$3
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.de ZN
|
|
Packit |
5bd3a9 |
.ie t \fB\^\\$1\^\fR\\$2
|
|
Packit |
5bd3a9 |
.el \fI\^\\$1\^\fP\\$2
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.de hN
|
|
Packit |
5bd3a9 |
.ie t <\fB\\$1\fR>\\$2
|
|
Packit |
5bd3a9 |
.el <\fI\\$1\fP>\\$2
|
|
Packit |
5bd3a9 |
..
|
|
Packit |
5bd3a9 |
.ny0
|
|
Packit |
5bd3a9 |
'\" t
|
|
Packit |
5bd3a9 |
.TH XmbLookupString __libmansuffix__ __xorgversion__ "XLIB FUNCTIONS"
|
|
Packit |
5bd3a9 |
.SH NAME
|
|
Packit |
5bd3a9 |
XmbLookupString, XwcLookupString, Xutf8LookupString \- obtain composed input from an input method
|
|
Packit |
5bd3a9 |
.SH SYNTAX
|
|
Packit |
5bd3a9 |
.HP
|
|
Packit |
5bd3a9 |
int XmbLookupString\^(\^XIC \fIic\fP\^, XKeyPressedEvent *\fIevent\fP, char
|
|
Packit |
5bd3a9 |
*\fIbuffer_return\fP\^, int \fIbytes_buffer\fP\^, KeySym
|
|
Packit |
5bd3a9 |
*\fIkeysym_return\fP\^, Status *\fIstatus_return\fP\^);
|
|
Packit |
5bd3a9 |
.HP
|
|
Packit |
5bd3a9 |
int XwcLookupString\^(\^XIC \fIic\fP\^, XKeyPressedEvent *\fIevent\fP\^,
|
|
Packit |
5bd3a9 |
wchar_t *\fIbuffer_return\fP\^, int \fIwchars_buffer\fP\^, KeySym
|
|
Packit |
5bd3a9 |
*\fIkeysym_return\fP\^, Status *\fIstatus_return\fP\^);
|
|
Packit |
5bd3a9 |
.HP
|
|
Packit |
5bd3a9 |
int Xutf8LookupString\^(\^XIC \fIic\fP\^, XKeyPressedEvent *\fIevent\fP, char
|
|
Packit |
5bd3a9 |
*\fIbuffer_return\fP\^, int \fIbytes_buffer\fP\^, KeySym
|
|
Packit |
5bd3a9 |
*\fIkeysym_return\fP\^, Status *\fIstatus_return\fP\^);
|
|
Packit |
5bd3a9 |
.SH ARGUMENTS
|
|
Packit |
5bd3a9 |
.IP \fIbuffer_return\fP 1i
|
|
Packit |
5bd3a9 |
Returns a multibyte string or wide character string (if any)
|
|
Packit |
5bd3a9 |
from the input method.
|
|
Packit |
5bd3a9 |
.IP \fIbytes_buffer\fP 1i
|
|
Packit |
5bd3a9 |
.br
|
|
Packit |
5bd3a9 |
.ns
|
|
Packit |
5bd3a9 |
.IP \fIwchars_buffer\fP 1i
|
|
Packit |
5bd3a9 |
Specifies space available in the return buffer.
|
|
Packit |
5bd3a9 |
.ds Ev key event to be used
|
|
Packit |
5bd3a9 |
.IP \fIevent\fP 1i
|
|
Packit |
5bd3a9 |
Specifies the \*(Ev.
|
|
Packit |
5bd3a9 |
.IP \fIic\fP 1i
|
|
Packit |
5bd3a9 |
Specifies the input context.
|
|
Packit |
5bd3a9 |
.IP \fIkeysym_return\fP 1i
|
|
Packit |
5bd3a9 |
Returns the KeySym computed from the event if this argument is not NULL.
|
|
Packit |
5bd3a9 |
.IP \fIstatus_return\fP 1i
|
|
Packit |
5bd3a9 |
Returns a value indicating what kind of data is returned.
|
|
Packit |
5bd3a9 |
.SH DESCRIPTION
|
|
Packit |
5bd3a9 |
The
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString ,
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
functions return the string from the input method specified
|
|
Packit |
5bd3a9 |
in the buffer_return argument.
|
|
Packit |
5bd3a9 |
If no string is returned,
|
|
Packit |
5bd3a9 |
the buffer_return argument is unchanged.
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
The KeySym into which the KeyCode from the event was mapped is returned
|
|
Packit |
5bd3a9 |
in the keysym_return argument if it is non-NULL and the status_return
|
|
Packit |
5bd3a9 |
argument indicates that a KeySym was returned.
|
|
Packit |
5bd3a9 |
If both a string and a KeySym are returned,
|
|
Packit |
5bd3a9 |
the KeySym value does not necessarily correspond to the string returned.
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
return the length of the string in bytes, and
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
returns the length of the string in characters.
|
|
Packit |
5bd3a9 |
Both
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
return text in the encoding of the locale bound to the input method
|
|
Packit |
5bd3a9 |
of the specified input context, and
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
returns text in UTF-8 encoding.
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
Each string returned by
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
begins in the initial state of the encoding of the locale
|
|
Packit |
5bd3a9 |
(if the encoding of the locale is state-dependent).
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
Note: To ensure proper input processing,
|
|
Packit |
5bd3a9 |
it is essential that the client pass only
|
|
Packit |
5bd3a9 |
.ZN KeyPress
|
|
Packit |
5bd3a9 |
events to
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString ,
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString .
|
|
Packit |
5bd3a9 |
Their behavior when a client passes a
|
|
Packit |
5bd3a9 |
.ZN KeyRelease
|
|
Packit |
5bd3a9 |
event is undefined.
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
Clients should check the status_return argument before
|
|
Packit |
5bd3a9 |
using the other returned values.
|
|
Packit |
5bd3a9 |
These three functions each return a value to status_return
|
|
Packit |
5bd3a9 |
that indicates what has been returned in the other arguments.
|
|
Packit |
5bd3a9 |
The possible values returned are:
|
|
Packit |
5bd3a9 |
.TS
|
|
Packit |
5bd3a9 |
lw(1.5i) lw(4.3i).
|
|
Packit |
5bd3a9 |
T{
|
|
Packit |
5bd3a9 |
.ZN XBufferOverflow
|
|
Packit |
5bd3a9 |
T} T{
|
|
Packit |
5bd3a9 |
The input string to be returned is too large for the supplied buffer_return.
|
|
Packit |
5bd3a9 |
The required size (for
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString ,
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
in bytes; for
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
in characters) is returned as the value of the function,
|
|
Packit |
5bd3a9 |
and the contents of buffer_return and keysym_return are not modified.
|
|
Packit |
5bd3a9 |
The client should recall the function with the same event
|
|
Packit |
5bd3a9 |
and a buffer of adequate size to obtain the string.
|
|
Packit |
5bd3a9 |
T}
|
|
Packit |
5bd3a9 |
T{
|
|
Packit |
5bd3a9 |
.ZN XLookupNone
|
|
Packit |
5bd3a9 |
T} T{
|
|
Packit |
5bd3a9 |
No consistent input has been composed so far.
|
|
Packit |
5bd3a9 |
The contents of buffer_return and keysym_return are not modified,
|
|
Packit |
5bd3a9 |
and the function returns zero.
|
|
Packit |
5bd3a9 |
T}
|
|
Packit |
5bd3a9 |
T{
|
|
Packit |
5bd3a9 |
.ZN XLookupChars
|
|
Packit |
5bd3a9 |
T} T{
|
|
Packit |
5bd3a9 |
Some input characters have been composed.
|
|
Packit |
5bd3a9 |
They are placed in the buffer_return argument, using the encoding
|
|
Packit |
5bd3a9 |
described above,
|
|
Packit |
5bd3a9 |
and the string length is returned as the value of the function.
|
|
Packit |
5bd3a9 |
The content of the keysym_return argument is not modified.
|
|
Packit |
5bd3a9 |
T}
|
|
Packit |
5bd3a9 |
T{
|
|
Packit |
5bd3a9 |
.ZN XLookupKeySym
|
|
Packit |
5bd3a9 |
T} T{
|
|
Packit |
5bd3a9 |
A KeySym has been returned instead of a string
|
|
Packit |
5bd3a9 |
and is returned in keysym_return.
|
|
Packit |
5bd3a9 |
The content of the buffer_return argument is not modified,
|
|
Packit |
5bd3a9 |
and the function returns zero.
|
|
Packit |
5bd3a9 |
T}
|
|
Packit |
5bd3a9 |
T{
|
|
Packit |
5bd3a9 |
.ZN XLookupBoth
|
|
Packit |
5bd3a9 |
T} T{
|
|
Packit |
5bd3a9 |
Both a KeySym and a string are returned;
|
|
Packit |
5bd3a9 |
.ZN XLookupChars
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN XLookupKeySym
|
|
Packit |
5bd3a9 |
occur simultaneously.
|
|
Packit |
5bd3a9 |
T}
|
|
Packit |
5bd3a9 |
.TE
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
It does not make any difference if the input context passed as an argument to
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString ,
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
and
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
is the one currently in possession of the focus or not.
|
|
Packit |
5bd3a9 |
Input may have been composed within an input context before it lost the focus,
|
|
Packit |
5bd3a9 |
and that input may be returned on subsequent calls to
|
|
Packit |
5bd3a9 |
.ZN XmbLookupString ,
|
|
Packit |
5bd3a9 |
.ZN XwcLookupString
|
|
Packit |
5bd3a9 |
or
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
even though it does not have any more keyboard focus.
|
|
Packit |
5bd3a9 |
.LP
|
|
Packit |
5bd3a9 |
The function
|
|
Packit |
5bd3a9 |
.ZN Xutf8LookupString
|
|
Packit |
5bd3a9 |
is an extension introduced by The XFree86 Project, Inc. in their 4.0.2
|
|
Packit |
5bd3a9 |
release. Its presence is
|
|
Packit |
5bd3a9 |
indicated by the macro
|
|
Packit |
5bd3a9 |
.ZN X_HAVE_UTF8_STRING .
|
|
Packit |
5bd3a9 |
.SH "SEE ALSO"
|
|
Packit |
5bd3a9 |
XLookupKeysym(__libmansuffix__),
|
|
Packit |
5bd3a9 |
Compose(__filemansuffix__)
|
|
Packit |
5bd3a9 |
.br
|
|
Packit |
5bd3a9 |
\fI\*(xL\fP
|