Book a Demo

Author Topic: Icons and UML Profiles  (Read 5740 times)

cvg

  • EA Novice
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
Icons and UML Profiles
« on: June 17, 2008, 06:09:52 pm »
I find that if I replace the default graphic that a Profile uses with a shape using a shape script or a wmf picture file I am unable to display the tagged values, stereotype information etc on the diagram as well as my fancy graphic.  

Is this a limitation of EA or am I missing a step somewhere?

Cheers,

cvg  :-?

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: Icons and UML Profiles
« Reply #1 on: June 17, 2008, 10:01:15 pm »
It is a limitation.

AFAIK there's been no movement towards supporting compartments (for tagged values, attributes, operations, etc.) in shape scripts. I've asked and not received any encouragement.

Perhaps you could also make a formal feature request for this. In time if enough of us actually take the time to ask Sparx directly this might make the 'cut' when new features are scheduled.

You'll find the correct form by clicking the Feature Request link near the bottom of any forum page. Please post back to tell us if you hear from Sparx directly in response.

David
No, you can't have it!

KP

  • EA Administrator
  • EA Expert
  • *****
  • Posts: 2919
  • Karma: +55/-3
    • View Profile
Re: Icons and UML Profiles
« Reply #2 on: June 18, 2008, 09:20:34 am »
Quote
I find that if I replace the default graphic that a Profile uses with a shape using a shape script or a wmf picture file I am unable to display the tagged values, stereotype information etc on the diagram as well as my fancy graphic.
Displaying a stereotype in a shape script is easy:

Code: [Select]
println("«#stereotype#»");
To display tagged values, you'd need to look at linked notes.
The Sparx Team
[email protected]

Thomas Mercer-Hursh

  • EA User
  • **
  • Posts: 386
  • Karma: +0/-0
  • Computing Integrity
    • View Profile
Re: Icons and UML Profiles
« Reply #3 on: June 19, 2008, 04:33:16 am »
Point being that, with enough work you can modify the shape script to display most things, but if, for example, you modify it to display tagged values, that is a fixed property of that stereotype which pays no attention to the properties set for the diagram.  If you show them, they always show.

Dave_Bullet

  • EA User
  • **
  • Posts: 295
  • Karma: +0/-0
    • View Profile
Re: Icons and UML Profiles
« Reply #4 on: June 19, 2008, 07:44:48 am »
you can test diagram.type in your shapescript, which will allow you to render the same element in multiple different ways depending on the type of diagram it is on.  A practical use is showing Nodes as UML boxes on a logical diagram or a fancy server graphic on a deployment diagram.
"I know I'm close to a good design, but it's like the balloon animals, squeeze in one spot and the problem moves down the line"

cvg

  • EA Novice
  • *
  • Posts: 12
  • Karma: +0/-0
    • View Profile
Re: Icons and UML Profiles
« Reply #5 on: June 20, 2008, 01:16:59 am »
Thanks for the replies guys.

Dave, Can you give me some sample code for selecting an icon dependent on diagram name?

Charlotte