Xbasic

SET_PEN Function

Syntax

SET_PEN( color as C [, pen_style as C [, width as N ] )

SET_PEN( Color_Code as C [, Pen_Style as C [, Width as N ] )

Arguments

color

Character

Aqua

Light Green

Aqua White

Light Orange

Black

Light Tan

Blue

Light Turquoise

Blue Gray

Light Yellow

Blue White

Lime

Bright Green

Off White

Brown

Olive Green

Buttontext

Orange

Canvas

Pale Blue

Dark Blue

Pale Yellow

Dark Green

Pink

Dark Green

Pink White

Dark Red

Plum

Dark Rose

Red

Dark Tan

Rose

Dark Teal

Sea Green

Dark Yellow

Sky Blue

Dirty White

Tan

Forrest green

Teal

Gold

Turquoise

Gray-25

Violet

Gray-40

White

Gray-50

Win3D

Gray-80

Winback

Green White

Wintext

Indigo

Yellow

Lavendar

Yellow White

Light Blue

color_code

The RGB code for the color in the format "#R,G,B", where R, G and B are integers between 0 and 255. Character

pen_style

Optional. Default = "Solid". Values may be: "Dash" or "Dot"

width

Optional. Default = 1. The thickness of the line in pixels. Character

Description

The SET_PEN() function sets the line and border color, style, and thickness.

Example

ui_bitmap_create("test", 4, 2) ui_bitmap_draw("test", inner_Rect(0, 0, 4, 2) set_brush("green") set_pen("black", "Dot", 1) start_poly(2, .5) lineto(3, 1) lineto(1, 1.5) fill_poly(2, .5) %code%) ui_dlg_box("","{image=test}")

Limitations

Used only in the Code sections of UI_BITMAP_DRAW(), UI_SCREEN_DRAW(), and UI_PRINTER_DRAW().

See Also