A widget holding this trait can display textual data
Format
#include <Xm/AccTextT.h> typedef struct { int version; XmAccessTextualGetValuesProc getValue; XmAccessTextualSetValuesProc setValue; XmAccessTextualPreferredProc preferredFormat; } XmAccessTextualTraitRec, *XmAccessTextualTrait; XtPointer (*XmAccessTextualGetValuesProc)Widgetint void (*XmAccessTextualSetValuesProc)WidgetXtPointerint int (*XmAccessTextualPreferredProc)Widget
DESCRIPTION
A widget holding the XmQTaccessTextual trait is capable of rendering one primary parcel of textual data. The primary parcel may consist of many lines (like in XmText) or only one line (like in XmTextField). However, if the widget renders more than one parcel of textual data (as does XmList), then the widget should not hold this trait.
The following standard Motif primitive widgets hold this trait:
The following standard Motif manager widgets examine their child widgets for this trait:
(See the source code for the ExmString demonstration widget for an example use of this trait.)
XtPointer getValueWidget widgetint format
The getValue trait method returns a copy of the textual data associated with widget widget in the format specified by format.
This method returns a copy of the textual data in the format specified by format. The caller is responsible for managing the space allocated by the copy. If the format is XmFORMAT_XmSTRING, then the method returns an XmString cast to an XtPointer. If the format is XmFORMAT_MBYTE or XmFORMAT_WCS, then the method returns a char* cast to an XtPointer.
void setValueWidget widgetXtPointer strint format
A parent widget calls the setValue method to set the string data associated with child widget widget. The parent specifies both the string data ( str) and the format of that string data.
int preferredFormatWidget widget
A parent widget calls the preferredFormat method to find the format in which the child widget prefers to receive its string data.
This method returns the preferred string format of the child widget. The returned format must be one of the following: XmFORMAT_XmSTRING, XmFORMAT_MBYTE, or XmFORMAT_WCS.
RELATED