Sparx Systems Forum
Enterprise Architect => General Board => Topic started by: tmtm on January 28, 2008, 02:00:27 pm
-
How can you assign a custom graphic to a stereotype in a UML Profile project? I don't want to use the Shape scripts as I already have a robust set of icons.
I also want these icons to be serialized and distributed in or with the profile xmi file when I export the profile from my project.
Thank you.
-
Read up about Metafiles. I haven't used them personally, but "Enables an image file to be used for the appearance of the stereotype." sure sounds like what you are asking for.
-
To distribute your images with your profile, you will need to bundle them all into an MDG Technology - more info in the help file...
-
But I don't know if this helps you. AFAIK you cannot assign the image to your stereotyped class. At least not in the profile development stage.
Any clarification anyone?
-
Couldn't you include the icons in the MDG technology and then assign them to stereotypes via shape scripts using nothing but the "image" command?
-
You just might have the solution Frank. I've not tried it, but that sounds quite plausible. You can give each image a name when you add it to the profile, so it should all connect.
-
I believe you can add shapescripts to your stereotypes in a UML Profile, but you can't add images. As stated above for images you have to bundle the UML profiles and images into an MDG technology - not that difficult with the MDG technology wizard. The help is OK on this I think.
-
Thanks Graham,
I misspoke myself there. I meant MDG Technologies. Perhaps in that case all the necessary conditions are there.
You'd still have to use a shape script to load the image, but at least you could try to do so by name.
David
-
No problem, but having just exported a UML profile all this has started me asking myself what the "alternate image" checkbox is for on the UML profile export dialogue box !!