|
|
|
|
Re: Node position and size based on semantic model [message #1721027 is a reply to message #1720862] |
Fri, 22 January 2016 16:53 |
|
Hi Stefano,
I think that you should add a ModelChangeTrigger
(session.getEventBrocker().addLocalTrigger(new YourModelChangeTrigger))
with a NotificationFilter that is limited to diagram element coordinates
update. The modification itself should be on a GMF element "Location" or
"LayoutConstraint".
In your ModelChangeTrigger, you will be able to add the code that update
your annotations in the method localChangesAboutToCommit.
The information about the displaying the grid and its size is a GMF
information that should be stored in the preferences of the
workspace/project. I will look for it as soon as I can.
Regards,
Steve
Le 21/01/2016 15:03, Stefano Cottafavi a écrit :
> Hi Steve,
> I've implemented my layout provider in which I drill down into the
> annotations of my model to get the location of the diagram nodes and
> create the commands to move them.
> I've two questions:
> - how can I persist the the annotations back from the diagram to the
> model once a view has been moved manually by an user?
> - I have graphical annotation for example for the grid size that I want
> to get from my model and assign it to the diagram.Can I do it from the
> same layout provider? on which diagram element these information have to
> be set?
>
> thanks for your help.
>
> cheers,
> stef
--
Steve Monnier - Obeo
Need professional services for Sirius?
http://www.obeodesigner.com/sirius
Steve Monnier - Obeo Canada
Need training or professional services for Sirius?
http://www.obeodesigner.com/sirius
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.05891 seconds