Sparx Systems Forum

Enterprise Architect => Automation Interface, Add-Ins and Tools => Topic started by: Paul W on October 22, 2008, 10:37:14 pm

Title: UML Profile / MDG and shapes
Post by: Paul W on October 22, 2008, 10:37:14 pm
I am creating a profile/MDG for the way we use EA for strategy projects.
Most of the elements can be stereotyped requirements and I can show the difference by changing the border and fill colours.

However we have on element where I need to use anoher 'base' element other than requirement so that I can make it composite and create composite diagrams. I would like to create a sterotype on this element but set its shape back to requirement.

Is this possible and how do I do it?
Title: Re: UML Profile / MDG and shapes
Post by: KP on October 23, 2008, 02:54:29 pm
The bad news is that what you are trying to do isn't possible. There is a DrawNativeShape() command in shape scripts, but you can't say "I am a Component but I want to draw a Requirement's native shape".

The good news is that Requirement elements can be composite. Search the help for _defaultDiagramType and _makeComposite to see how to change the diagram type of the composite requirement.