Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages


home | help
XmtMsgLineSetInput(3)	   Library Functions Manual	 XmtMsgLineSetInput(3)

       XmtMsgLineSetInput(),  XmtMsgLineGetInput() - set or query the editable
       text in an XmtMsgLine widget.

       #include	<Xmt/MsgLine.h>

       void XmtMsgLineSetInput(Widget w, String	s)

       String XmtMsgLineGetInput(Widget	w)


	    w	   An XmtMsgLine widget.

	    s	   For XmtMsgLineSetInput(), the input string to be displayed.


	    XmtMsgLineGetInput() returns the current editable  text  displayed
	    in the message line. This text must	be freed with XtFree() when no
	    longer needed.

       XmtMsgLineSetInput() appends to the text	displayed  in  the  XmtMsgLine
       widget  w.  This	 function differs from XmtMsgLineAppend(), however, in
       that the	appended text may be edited by the user	in a  subsequent  call
       to one of the synchronous input functions XmtMsgLineGetString(),	XmtMs-
       gLineGetInt(), XmtMsgLineGetUnsigned(), or XmtMsgLineGetDouble().

       Text inserted into the message line with	XmtMsgLineSet(), XmtMsgLineAp-
       pend(),	or  XmtMsgLinePrintf()	is  never  editable  by	the user. Text
       inserted	with XmtMsgLineSetInput() is editable, and becomes the default
       value  for a subsequent call to a synchronous input function. Note that
       multiple	calls to XmtMsgLineSetInput() do not append more editable text
       to  previously  editable	text; each call	sets the entire	editable text,
       replacing any editable text previously displayed	in the widget.

       XmtMsgLineGetInput() returns any	currently editable text	in an  XmtMsg-
       Line widget. It returns a copy of the editable text in allocated	memory
       which must be freed by the application, by calling XtFree() when	it  is
       no longer needed. The only time there is	editable text in an XmtMsgLine
       widget is while one of the synchronous input functions is in  progress.
       At this point, the application is in an internal	event loop, and	so you
       must always call	XmtMsgLineGetInput() from an action procedure or call-
       back invoked by the XmtMsgLine widget.

       Note  that XmtMsgLineGetInput() does not	return complete	user input, as
       XmtMsgLineGetString() does, but only a snapshot of the current state of
       the message line. An application	might use this partial input to	imple-
       ment ``filename completion'' with the Tab key, for example, but	should
       not  treat input	as valid until the user	has entered it by striking the
       Return key.

       Chapter 22, The Message Line,
       XmtMsgLine, XmtMsgLineAppend(), XmtMsgLineClear(), XmtMsgLineGetChar(),
       XmtMsgLineGetDouble(), XmtMsgLineGetInt(), XmtMsgLineGetString(),
       XmtMsgLineGetUnsigned(),	XmtMsgLinePop(), XmtMsgLinePrintf(),
       XmtMsgLinePush(), XmtMsgLineSet().

Xmt				  Motif	Tools		 XmtMsgLineSetInput(3)


Want to link to this manual page? Use this URL:

home | help