Win32Prn() > Print output methods xHarbour Developers Network  

oWin32Prn:setColor()

Defines text color and alignment.

Syntax

:setColor( <nClrText>, [<nClrPane>], [<nAlign>} ) --> NIL

Arguments

<nClrText>
This is a numeric RGB color value defining the text color (foreground).
<nClrPane>
This is an optional numeric RGB color value defining the pane color (background).
<nAlign>
This is an optional numeric value specifying the text alignment at the current print position. The following values can be used:

Values for text alignment
ValueDescription
0 *)Text is printed left aligned to the current print position
 1Text is printed right aligned to the current print position
 2Text is printed centered on the current print position

Two constants for horizontal and vertical alignment can be added to define horizontal and vertical text alignment with one parameter.

Description

Method :setColor() defines foreground and background color plus alignment for printing text strings. The color values must be defined as numeric RGB colors. The defined colors and text alignment are used for text printing methods like :textOut() or :textOutAt().

The return value of :setColor() is always NIL.


Copyright © 2006-2007 xHarbour.com Inc. All rights reserved.
http://www.xHarbour.com
Created by docmaker.exe