Sparx Systems Forum
Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: hwgxx on November 19, 2010, 07:11:33 pm
-
i would like to add a star on the icon of element "Component", at the same time, i will add a new stereotype and tagged values into EA. Whether can i get the emf file for original "Component" element ?
-
There is no emf file. You can add decorations to elements though: search the help file for "shape scripts".
-
i read the chapter about "Shape Scripts", i only can redraw the whole icon, but i want to draw on the basis of the current figure.
how should i do?
thx
-
Your shape script will need to look something like this:
decoration star
{
// insert drawing code here...
}
-
To draw original shape use with a decorator on top you probably want to do something like this
decoration star
{
// insert drawing code here...
}
shape main
{
drawnativeshape();
}
Look at orientation in the help under shape attributes to position the decoration in NW, N, NE, E, S, SW ow W within in the containing element glyph.
If you want to see examples load the archimate mdg file located in the folder C:\Program Files\Sparx Systems\EA\MDGTechnologies into a model so you can see the shape scripts associated with the stereotypes.
Hope that helps.