Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought

XCreateIC − create an input context. 

Synopsis

XIC XCreateIC(im, ...)

   XIM im;

Arguments

imSpecifies the input method. 

...Specifies the variable length argument list to set XIC values. 

Availability

Release 5 and later. 

Description

XCreateIC() creates an input context associated with the specified input method.  The first argument to this function is the "parent" input method, and it is followed by a NULL-terminated variable-length argument list of input context attribute name/value pairs.  The tables below list the standard attribute names and their types.  Note that the XNInputStyle attribute and XNFontSet sub-attribute for the Preedit and Status areas must be specified when the IC is created.  XNSpotLocation must be specified for the Preedit area if the pre-edit interaction style is XIMPreeditPosition.  All the Preedit and Status callbacks must be specified in the call to XCreateIC() if the interaction style is XIMPreeditCallbacks or XIMStatusCallbacks.  Any other attributes may be set with XCreateIC(), but are not required.  Input Context Attributes

Name Type Notes

Required at IC creation; may not be changed. T} XNClientWindow@Window@T{ Must be set before IC use; may not be changed. T} XNFocusWindow@Window@T{ Changes may cause geometry negotiation. T} XNResourceClass@char * XNGeometryCallback@XIMCallback * XNFilterEvents@unsigned long@T{ Read-only attribute; may not be set. T} XNPreeditAttributes@XVaNestedList@T{ See sub-attributes below. T} XNStatusAttributes@XVaNestedList@T{ See sub-attributes below. T} _

Preedit and Status Area Sub-attributes

Name Type Notes

XNAreaNeeded@XRectangle * XNSpotLocation@XPoint *@T{ Required at IC creation for XIMPreeditPosition style. T} XNColormap@Colormap XNStdColormap@Atom XNForeground@unsigned long XNBackground@unsigned long XNBackgroundPixmap@Pixmap XNFontSet@XFontSet@T{ Required at IC creation; changes may cause geometry negotiation. T} XNLineSpacing@int@T{ Changes may cause geometry negotiation. T} XNCursor@Cursor XNPreeditStartCallback@XIMCallback *@T{ Required at IC creation for XIMPreeditCallbacks style. T} XNPreeditDoneCallback@XIMCallback *@T{ Required at IC creation for XIMPreeditCallbacks style. T} XNPreeditDrawCallback@XIMCallback *@T{ Required at IC creation for XIMPreeditCallbacks style. T} XNPreeditCaretCallback@XIMCallback *@T{ Required at IC creation for XIMPreeditCallbacks style. T} XNStatusStartCallback@XIMCallback *@T{ Required at IC creation for XIMStatusCallbacks style. T} XNStatusDoneCallback@XIMCallback *@T{ Required at IC creation for XIMStatusCallbacks style. T} XNStatusDrawCallback@XIMCallback *@T{ Required at IC creation for XIMStatusCallbacks style. T} _

In addition to the attribute names above, the special name XNVaNestedList indicates that the following argument is a XVaNestedList of attribute name/value pairs.  When a nested list is encountered in an argument list, the contents of the nested list are processed as if they appeared in the original argument list at that point.  XCreateIC() returns a NULL value if no input context could be created.  A NULL value could be returned for any of the following reasons:

•A required argument was not set. 

•A read-only argument was set (for example, XNFilterEvents). 

•The argument name is not recognized. 

•The input method encountered an implementation-dependent error. 

Errors

BadAtomA value for an Atom argument does not name a defined Atom. 

BadColorA value for a Colormap argument does not name a defined Colormap. 

BadPixmapA value for a Pixmap argument does not name a defined Pixmap. 

BadWindowA value for a Window argument does not name a defined Window. 

See Also

XOpenIM(), XSetICFocus(), XSetICValues(), XDestroyIC(), XIMOfIC(),
XmbResetIC(), XwcResetIC. 

Copyright O’Reilly & Assoc.  —  

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026