file Create and bind text field to sterotype

4 years 6 months ago #3561 by pan
Hi,

When you have created your stereotype it should have appeared on LocalModule.LocalProfile.
On the attached example, I have a stereotype toto on the package Pachage with a property myLabel on which you can set a string value.
Actually, on the stereotype LocalModule.LocalProfile. toto, I've added a TagType.

Is it what you want?



If you want a specific view with a textual information matching with the stereotype property you have to create a module.
Attachments:

Please Log in or Create an account to join the conversation.

4 years 6 months ago - 4 years 6 months ago #3562 by deankramer99
Hi, well I am creating a module anyways, so that is okay. I would like this to not be something the user has to do, but each time you add a stereotype supported by my model, it is created, and updated when particular properties are set.

This is the sort of model I want the user to be able to create:


You can see there are four main stereotypes (I have placed them on Modelio as all extending Class metaclass), and some links that join them together (I have used UMLAssociations)

For the writing above the Links, I have set the UMLAssociation Title, but you see the text above some of the sterotypes (for example "ont:- ...")? I want that to be added.

My understanding is this will need to be created when the stereotype is created, perhaps in:
actionPerformed(IDiagramHandle representation, IDiagramGraphic target,
			Rectangle rect)
?

I just do not know what methods/classes I should use to:

1)create the textField, and
2)bind it invisibly, so that 1) it could be accessed by the sterotype, and 2) so it moves with it on the diagram.

And then I should just access the new "diagramnode" and alter it using a
ModelChanged()
method?

Please Log in or Create an account to join the conversation.

4 years 6 months ago #3574 by deankramer99
Any ideas?

Please Log in or Create an account to join the conversation.

4 years 5 months ago #3635 by ebr
Hi,

In fact I would not create a new diagramNode inside the diagram, I would create a new UML elmeent (UMl Comment for example) and unmask it inside the diagram.

Does it help?

EBR

Please Log in or Create an account to join the conversation.

4 years 5 months ago #3636 by deankramer99
Hi,

Well what I ended up doing was creating a Note with the Stereotype, and automatically binding it. It's not as pretty (I would prefer no visible borders as shown in the picture), but does the job.

Do UMIComment have visible borders, like a Note?

Please Log in or Create an account to join the conversation.

4 years 5 months ago #3638 by ebr
Yes, Constraints are less visible...

Please Log in or Create an account to join the conversation.

Moderators: tmachmaab
Time to create page: 0.146 seconds
^ Back to Top