Top Document: Motif FAQ (Part 6 of 9) Previous Document: 213) What string functions differ in Motif 1.1 and 1.2? Is Next Document: 215) When can XmStrings used as resources be freed? See reader questions & answers on this topic! - Help others by sharing your knowledge [Last modified: Feb 02] Answer: In Motif 1.x, use XmStringGetLtoR: char *str; XmString xmstr; XmStringGetLtoR(xmstr, XmSTRING_DEFAULT_CHARSET, &str); In Motif 2.x, use XmStringUnparse: str = XmStringUnparse(xmstr, NULL, 0, XmCHARSET_TEXT, NULL, 0, NULL); In both cases, you should free the string to avoid a memory leak: XtFree(str); User Contributions:Top Document: Motif FAQ (Part 6 of 9) Previous Document: 213) What string functions differ in Motif 1.1 and 1.2? Is Next Document: 215) When can XmStrings used as resources be freed? Part1 - Part2 - Part3 - Part4 - Part5 - Part6 - Part7 - Part8 - Part9 - Single Page [ Usenet FAQs | Web FAQs | Documents | RFC Index ] Send corrections/additions to the FAQ Maintainer: kenton@rahul.net (Ken Lee)
Last Update March 27 2014 @ 02:11 PM
|
Comment about this article, ask questions, or add new information about this topic: