Download Chora User Manual

Transcript
TARA Systems
Operators
arg uint8 aGreen,
arg uint8 aBlue,
arg uint8 aAlpha
)
var
var
var
var
var
color
uint8
uint8
uint8
uint8
bgColor;
r = 0x12;
g = 0x34;
b = 0x56;
a = 0x78;
// bgColor = #12345678
bgColor = color( r, g, b, a );
color color
(
)
This constructor does not expect an argument. It
returns merely a transparent color.
var color bgColor;
// bgColor = #00000000
bgColor = color();
rect rect
(
arg int32
arg int32
arg int32
arg int32
)
aX1,
aY1,
aX2,
aY2
This constructor initializes a new rectangle with
the given aX1, aY1, aX2, aY2 coordinates and
returns the initialized rect.
var
var
var
var
var
rect
int32
int32
int32
int32
r;
x1
y1
x2
y2
=
=
=
=
10;
20;
30;
40;
// r = <10,20,30,40>
r = rect( x1, y1, x2, y2 );
rect rect
(
arg point aPoint1,
arg point aPoint2
)
This constructor initializes a new rectangle with
the given points aPoint1 and aPoint2 and
returns the initialized rect.
var rect r;
var point p1 = <10,20>;
var point p2 = <30,40>;
// r = <10,20,30,40>
r = rect( p1, p2 );
rect rect
(
)
This constructor does not expect an argument. It
returns merely an empty rectangle.
var rect r;
// r = <0,0,0,0>
r = rect();
point point
(
arg int32 aX,
arg int32 aY
)
Embedded Wizard
Chora User Manual
This constructor initializes a new point with the
given aX and aY values and returns the initialized
point.
var point p;
var int32 x = 10;
Copyright TARA Systems GmbH
www.embedded-wizard.de
Page 143