AddRoundRect
AddRoundRect ( left ; top ; width ; height ; cornerRadius ; yRadius ; fillColor ; fillColorVariant ; borderStroke ; borderColor ; borderColorVariant ; shadowEffect ; shadowColor )
Argument | Type | Range | Default | Note |
---|---|---|---|---|
left | num | -inf..+inf | (required) | |
top | num | -inf..+inf | (required) | |
width | num | 0..inf | (required) | |
height | num | 0..inf | (required) | |
cornerRadius | num[] | 0..1000 | 12 | Dimension:[pt] |
yRadius | num[] | 0..1000 | 12 | Ignored |
fillColor | rgba | 0..255 | black | |
fillColorVariant | int | -1..128 | solid | |
borderStroke | num[] | 0..1000 | 0 | Dimension:[pt] |
borderColor | rgba | 0..255 | black | |
borderColorVariant | int | -1..128 | solid | |
shadowEffect | num[] | -1000..1000 | 0 | |
shadowColor | rgba | 0..255 | #888a |
Examples
AddRoundRect(50;50;250;150;;;2;red)
AddRoundRect(50;50;250;150;16;;lightGray)
AddRoundRect(50;50;250;150;16 0 16;;steelBlue)
Description
The AddRoundRect() function makes it possible to draw rectangles with rounded corners whose fill, border and shadow can be varied. Starting with xmCHART 5.0.4 the argument cornerRadius can have up to four corner radii (topLeft, topRight, bottomRight and bottomLeft). The argument yRadius is obsolete and is ignored.
| ADD_ROUND_RECT_01 |
1 | OpenDrawing(100;100) |
2 | AddRoundRect(10;10;80;80;10;;steelBlue) |
3 |
| ADD_ROUND_RECT_02 |
1 | OpenDrawing(100;100) |
2 | AddRoundRect(10;10;80;80;10;;215 101 90;shaded;;;;0 0 5) |
3 |
| ADD_ROUND_RECT_03 |
1 | OpenDrawing(100;100) |
2 | AddRoundRect(10;10;80;80;10;;darkYellow;solid;6;gray;shaded) |
3 |
| ADD_ROUND_RECT_04 |
1 | OpenDrawing(100;100) |
2 | AddRoundRect(10;10;80;80;0 12 0 12;;steelBlue;shaded;0;;;2 2 5;lightGray) |
3 |
| ADD_ROUND_RECT_05 |
1 | OpenDrawing(100;100) |
2 | AddRoundRect(10;10;80;80;0 0 12 0;;darkYellow;solid;6;gray;shaded;2 2 5;lightGray) |
3 |