Home | Index classes | Index static functions | Index enumerations | Index structure types |
CLASS {Canvas|_to_draw} , UNTESTED, BITWISE :
{Canvas} to draw on bitmap or {Paintbox} control.
IMPORT : {Bitmap} , {Control} , {AL4_form} , {AL4_drawing} .
{Bitmap} Bitmap_|to_draw_on_ , READ , INIT
Target {Bitmap} object or NONE (alternatively, the Control_ field should be set - for a canvas to draw on a {Paintbox} control).
{Control} Control_|to_paint_ , READ , INIT
Target {Control} object or NONE (alternatively, the Bitmap_ field should be set - for a canvas to draw on a {Bitmap} object).
INT Handle|_canvas_object , READ
The native descriptor to connect the AL-IV {Canvas} object to a native canvas object.
INT Printer_handle , READ
The same as above, but in case of drawing on a printer canvas.
INT Foreground|_color
The ink color used to draw foreground objects. It is sufficient to assigning it to any color before drawing using one of painting methods. Use PUSH statement to assign the Foreground value temporary and then return a previous value.
INT Background|_color
The same as above but for the background (fill) color.
BOOL Alpha|_channel_used_for_32_bpp_bitmaps
Set to TRUE to use alpha-channel on 32 bit bitmaps (of class {Bitmap}). If FALSE, then the high byte is ignored while drawing on a canvas.
'R_G_B|_A|_mainly_in_windows' , 'B_G_R|_A|_usual_for_linux' . | |
|
{Geometry}.{rect} Clip|_rect|angle||Clipping|_rect|angle
Set this rectangle to restrict drawing in its area only. If height or width of the Clip_rect is 0, it is just ignored while drawing.
REAL Pen_width
The pen width. In differ to other measured sizes, the pen width is not specified in points but pixels are used. Also, as it was traditionally so, value 0 means "default" pen width which usually is 1 pixel.
{pen_style} Pen_style
The pen current style. To change at, as for most canvas attributes, just assign new value to it. Or, use PUSH to do so temporary.
'SOLID_PEN' , 'CLEAR_PEN' . |
Available pen styles. |
{brush_style} Brush|_style
The brush current style (used to fill a shape drawing). To change at, as for most canvas attributes, just assign new value to it. Or, use PUSH to do so temporary.
{Font} Font|_tool , READ
Current font (to paint a text).
|
Setup font used to draw a text. Also, it is possible just to change fields of the Font property (filed) of the {Canvas} object: Face, Size, Bold, Italic, Underline. |
|
Measuring size of a text which can be drawing with the current Font on the canvas. In returning rectangle, the Location pount is always Pt(0,0), Width and Height are done in current Units. To get maximum possible height of the current font, it is possible to pass a string "_/|". Or, just use the Font.Size (specified in poiunts) which in most of cases should be of exact such value. The width of leading and trailing spaces is always 0. |
{units} Units|_measure_graphics
Current measure units. By default, points are used, but it is possiblt to set other available units. This is not certain for a Pen_width which is always done in pixels.
| |
| |
| |
| |
| |
|
'HIGH|_QUALITY' , 'MEDIUM|_QUALITY' , 'LOW|_QUALITY' . |
{quality} Quality|_drawing
|
|