Book a Demo

Author Topic: image of stereotypes; profile  (Read 3562 times)

gusta

  • EA Novice
  • *
  • Posts: 2
  • Karma: +0/-0
    • View Profile
image of stereotypes; profile
« on: June 19, 2008, 06:41:38 am »
Hello,

I'm starting to develop a profile using the Enterprise Architect tool. I have created a stereotype and used successfully. However, when I associate an image to the stereotype, the whole picture of the class to which the stereotype is applied changes to the figure associated with the stereotype, hiding the attributes and operations of the class.

I wonder what I do for the figure of the stereotype only appear next to the name of class, as is done, for example, the stereotype "Client Page" of "Web Modeling" profile.

Thank you for contributions. Sorry for my English

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: image of stereotypes; profile
« Reply #1 on: June 19, 2008, 07:00:34 am »
If you mean the little icon at the top right of a class glyph, then you can do this.

Read up on the shape script documentation. Use a shape script to define a decoration shape type - you will see this in the documentation, but you'll need to read it carefully - and you're all set.

The decoration will be placed at the location (corner) of the class glyph that you specify.

This is a useful feature of shape scripts. It would be nice if it were taken further - we've asked - but at least it works now.

HTH, David

PS: Your English is fine.
No, you can't have it!

helmerhausen

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: image of stereotypes; profile
« Reply #2 on: July 04, 2008, 12:11:23 am »
I have the same problem.

If anybody has an example, then please post here.

«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: image of stereotypes; profile
« Reply #3 on: July 04, 2008, 04:17:59 am »
Search the forum; there are some examples. I'll leave you to find them.

You could also load up the BPMN 1.3 add-in as described on the BPMN 1.4 page of EA Help. Pay attention to the note on that page. After doing so you'll see shape scripts for BPMN elements listed on the Stereotypes tab of the Settings | UML dialog. There are some "decorations" among these scripts, but I don't remember if they are done the same way. Still, they do work...

David
No, you can't have it!

helmerhausen

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: image of stereotypes; profile
« Reply #4 on: July 04, 2008, 04:32:52 pm »
Quote

You could also load up the BPMN 1.3 add-in as described on the BPMN 1.4 page of EA Help. Pay attention to the note on that page. After doing so you'll see shape scripts for BPMN elements listed on the Stereotypes tab of the Settings | UML dialog.

Thank you for this information.

helmerhausen

  • EA Novice
  • *
  • Posts: 9
  • Karma: +0/-0
    • View Profile
Re: image of stereotypes; profile
« Reply #5 on: July 04, 2008, 06:22:28 pm »
Sorry, but my problem is not solved yet. In the BPMN example i did not found the right thing.

Let me try to explain what my problem is:

I want to customize my stereotype the way that the shape looks like the shape of an stereotype class with the icon in position north/east.

Instead of the stereotype icon my icon should be placed there.

I tried to do something like this:

shape main{
drawnativeshape();
}

decoration deco{
      orientation = "NE";
      image("image1.bmp",0,0,100,100);
}

But in that case the image is over the text if the text is to long.



«Midnight»

  • EA Guru
  • *****
  • Posts: 5651
  • Karma: +0/-0
  • That nice Mister Grey
    • View Profile
Re: image of stereotypes; profile
« Reply #6 on: July 04, 2008, 10:27:57 pm »
First, this sometimes happens in EA if text is too long.

Second, I don't know how well shape scripts handle both Main and Decoration in the same script. To make matters worse, DrawNativeShape seems to take over the script, leaving little or no room for customization.

Here's a couple of possibilities, but I have no idea if they will work:
See if you can set the preferred size of the native shape. If you can, perhaps you can 'push' it below your icon.

See if you can position your icon with a slightly negative Y coordinate, to move it out of the way of the text.

Sorry I don't have more ideas off hand.

Has anyone out there solved this one yet?

David
No, you can't have it!