Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Update programmatically figure with EditPart
Update programmatically figure with EditPart [message #990822] Fri, 14 December 2012 11:00 Go to next message
excellion fdfds is currently offline excellion fdfdsFriend
Messages: 14
Registered: July 2012
Junior Member
I have an rcp application, with gmf model.
So i have somes edit part who contains a model and a figure.

I want update bounds or routing points of a figure, programmatically with using directly the edit part (or the figure).
Directly make a figure.setPoints(pointList); not works (because not persisted in file).

To update a model, i create command with a transactionnal editing domain.

But for update figures, what is the procedure?

Re: Update programmatically figure with EditPart [message #990837 is a reply to message #990822] Fri, 14 December 2012 11:45 Go to previous message
Ralph Gerbig is currently offline Ralph GerbigFriend
Messages: 702
Registered: November 2009
Senior Member

to make figures react on changes in your ecore model instanze you can do two things. You can use pins in graphical and gmfmap model which will have an OCL expression that is executed to determine whether the pin is executed. The second way is to override handleNotification in your editpart. If you want to persist your changes you should to these in the notation model. You can get the notation model element of a edit part by calling getNotationView on it.

Previous Topic:Default value of node attribute
Next Topic:Adding bendpoints as part of Arrange All
Goto Forum:

Current Time: Thu Jan 19 19:38:48 GMT 2017

Powered by FUDForum. Page generated in 0.07093 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software