fillSvgElement()
Modifies the SVG image used for filling a shape.
Synopsis
shape.fillSvgElement(string element, string fill, string color);
Parameters
| Parameter | Description |
|---|---|
| element | ID of the SVG element to adjust. |
| fill | Fill type string, for example solid. |
| color | Color to use. Relevant only for fill types that use a color
(solid and hatch). For other
types, use an empty string. |
Details
The fillable primitive shape object needs to have an SVG already loaded. You can either set it as fill attribute or define it in the panel in GEDI.
The element inside this SVG is then adjusted to use the given fill string (for example "[solid]") and the given color for this fill type. The color is only relevant for fill types which use the color (solid and hatch). For others it can be given as an empty string.
fill and color, for example:
RECT.fillSvgElement("elem", "", "");The given fill-string and color adhere to the current colorScheme and the active IconTheme and will also switch when these change in runtime. Blinking colors are supported as well.
Assignment
Button, Polygon, Arc, Ellipse, Rectangle
