rect()
Produces an SVG "rect"
element.
Syntax
rect(
x STRING,
y STRING,
width STRING,
height STRING,
rx STRING,
ry STRING )
RETURNS om.DomNode
- x defines the X coordinate of the top/left corner.
- y defines the Y coordinate of the top/left corner.
- width defines the width of the rectangle.
- height defines the height of the rectangle.
- rx defines the X radius for rounded corners.
- ry defines the Y radius for rounded corners.
Usage
This function creates a "rect"
SVG DOM element from the parameters.
Rounded borders are got by setting the rx, ry parameters.
Example
DEFINE n om.DomNode
LET n = fglsvgcanvas.rect(10,10,50,30,1,1)