This returns a sequence of three values: The height, in pixels, of the text drawn,
the number of characters used that could fit into the rectangle specified, and the
rectangle actually used, given as a {left,top,right,bottom} sequence. The rectangle is given in client coordinates for the control id.
The meaning and valid values for the other parameters are to be found in the Win32 API documentation.
Example:
sequence result
sequence rect
result = drawText(myWind, "Fourscore and twenty years ago, our fathers, ...",
{5,5,140, 75}, DT_WORDBREAK, 4, 0, 0)
textheight = result[1]
textcnt= result[2]
rect = result[3]
See Also: getFindText, getFRText, getReplaceText, setFRMsgStrings, textOut, textRect
id should be the id of the control in which the Find Dialog will
search. The Find dialog is a modeless dialog, which means that it
will remain open and on top, until the user closes it.
This call is equivalent to getFRText(id,w32False,-1).
See Also: drawText, getFRText, getReplaceText, setFRMsgStrings, textOut, textRect
id should be the id of the control in which the Find or Replace Dialog will
search. The dialog is a modeless dialog, which means that it
will remain open and on top, until the user closes it.
The dialog is a Find dialog if replace_if_set is w32False, and a Replace dialof if it is not zero.
If callback is not -1, it is a routine id called on completion of a find or replace operation.
The callback procedure should take two integer parameter. The first one is the id of the control, and the second is:
See Also: drawText, getFindText, getReplaceText, setFRMsgStrings, textOut, textRect
id should be the id of the control in which the Replace Dialog will
search. The Replace dialog is a modeless dialog, which means that it
will remain open and on top, until the user closes it.
This call is equivalent to getFRText(id,w32True,-1).
See Also: drawText, getFindText, getFRText, setFRMsgStrings, textOut, textRect
find/replace operation completes. The arguments are, respectively:
See Also: drawText, getFindText, getFRText, getReplaceText, textOut, textRect
This is a special version of wPuts that can be faster under certain
circumstances.
HDC is the Device Context of a control and not its Id. This can
be obtained by getDC() or assignFont(). And must be released after
use.
TextDef is a sequence of up to 7 elements. Elements 4 thru 7 are
optional and can be 'omitted' by using an empty sequence for them.
The elements are ...
Example:
atom hdc
hdc = assignFont(Mypixmap)
H = getTextHeight(Mypixmap, "|")
W = 4
textOut(hdc,{" Name:", W, 0 * H, Black, White, OPAQUE})
textOut(hdc,{"Address:", W, 1 * H})
textOut(hdc,{" Age:", W, 2 * H})
textOut(hdc,{" Weight:", W, 3 * H})
W = getTextWidth(Mypixmap, "_") * 9
textOut(hdc,{NameFld, W, 0 * H, Blue, BrightWhite})
textOut(hdc,{AddressFld, W, 1 * H})
textOut(hdc,{sprintf("%d",AgeFld), W, 2 * H})
textOut(hdc,{sprintf("%5.2f", WeightFld), W, 3 * H})
releaseDC(Mypixmap)
See Also: drawText, getFindText, getFRText, getReplaceText, setFRMsgStrings, textRect
l rect defines the left, top and maximum right pixel (for multiple line text).
The parameters are the same as for drawText(), as the same API function is called by both routines.
On return, the rectangle actually used is given as {left, top, right, bottom}.
Example:
sequence result
result = textRect(myWind, "Fourscore and twenty years ago, our fathers, ...",
{5,5,140, 75}, DT_WORDBREAK, 4, 0, 0)
See Also: drawText, getFindText, getFRText, getReplaceText, setFRMsgStrings, textOut