Win32Prn() > Print output methods |
Prints text at the current print position.
:textOut( <cString>] , ; [<lNewLine>] , ; [<lUpdatePosX>], ; [<nTexAlign>] ) --> lSuccess
Values for text alignment
Value | Description |
---|---|
0 *) | Text is printed left aligned to the current print position |
1 | Text is printed right aligned to the current print position |
2 | Text is printed centered on the current print position |
*) default |
Method :textOut() is the most commonly used one for printing text strings. It uses the current :setFont() and :setColor() settings, and updates the X coordinate of the print position by default. The method does not wrap text to a new line when the output exceeds :rightMargin. Use method :getTextWidth() to determine if <cString> still fits into the current line. For example:
IF ::posX + ::getTextWidth( <cString> ) > ::rightMargin ::newLine() ENDIF
The method returns a logical value indicating success of the operation.
http://www.xHarbour.com