12.07.2015 Views

Xlib − C Language X Interface

Xlib − C Language X Interface

Xlib − C Language X Interface

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Xlib</strong> − C LibraryX11, Release 6.7 DRAFTelements representing the concatenation of the specified list of null-terminated text strings. Theinput text strings must be given inthe current locale encoding (for XmbTextListToTextPropertyand XwcTextListToTextProperty), or in UTF-8 encoding (for Xutf8TextListToTextProperty).The functions set the encoding field of text_prop_return to an Atom for the specified displaynaming the encoding determined by the specified style and convert the specified text list to thisencoding for storage in the text_prop_return value field. If the style XStringStyle or XCompoundTextStyleis specified, this encoding is ‘‘STRING’’ or‘‘COMPOUND_TEXT’’, respectively.Ifthe style XUTF8StringStyle is specified, this encoding is ‘‘UTF8_STRING’’. (This isan XFree86 extension introduced in XFree86 4.0.2. Its presence is indicated by the macroX_HAVE_UTF8_STRING.) If the style XTextStyle is specified, this encoding is the encodingof the current locale. If the style XStdICCTextStyle is specified, this encoding is ‘‘STRING’’ ifthe text is fully convertible to STRING, else ‘‘COMPOUND_TEXT’’. A final terminating nullbyte is stored at the end of the value field of text_prop_return but is not included in the nitemsmember.If insufficient memory is available for the new value string, the functions return XNoMemory. Ifthe current locale is not supported, the functions return XLocaleNotSupported. Inboth of theseerror cases, the functions do not set text_prop_return.To determine if the functions are guaranteed not to return XLocaleNotSupported, use XSupportsLocale.If the supplied text is not fully convertible to the specified encoding, the functions return the numberof unconvertible characters. Each unconvertible character is converted to an implementationdefinedand encoding-specific default string. Otherwise, the functions return Success. Note thatfull convertibility to all styles except XStringStyle is guaranteed.To free the storage for the value field, use XFree.The function Xutf8TextListToTextProperty is an XFree86 extension introduced in XFree864.0.2. Its presence is indicated by the macro X_HAVE_UTF8_STRING.To obtain a list of text strings from an XTextProperty structure, use XmbTextPropertyTo-TextList, XwcTextPropertyToTextList or Xutf8TextPropertyToTextList.350

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!