Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Is there command which can move the figure in GMF?
Is there command which can move the figure in GMF? [message #224600] Tue, 07 April 2009 09:47 Go to next message
changqing is currently offline changqingFriend
Messages: 16
Registered: July 2009
Junior Member
thanks
Re: Is there command which can move the figure in GMF? [message #224632 is a reply to message #224600] Tue, 07 April 2009 10:48 Go to previous messageGo to next message
Matthias M. is currently offline Matthias M.Friend
Messages: 27
Registered: July 2009
Junior Member

You can access the position of your node by
((BoundsImpl)((NodeImpl)EditPart.getModel).getLayoutConstrai nt).setX()
respectively setY().


Re: Is there command which can move the figure in GMF? [message #224709 is a reply to message #224632] Tue, 07 April 2009 13:37 Go to previous messageGo to next message
BG is currently offline BGFriend
Messages: 45
Registered: July 2009
Member
Hi,
I think we can also do these way

ChangeBoundsRequest move_req = new
ChangeBoundsRequest(RequestConstants.REQ_MOVE);
move_req.setMoveDelta(deltaPoint);
move_req.setEditParts(editPartToBeMoved);

//where the delta is distance u want move relatively

Command cmd = editPartToBeMoved.getCommand(move_req);

Regards
Byre
Re: Is there command which can move the figure in GMF? [message #224812 is a reply to message #224709] Wed, 08 April 2009 03:11 Go to previous message
changqing is currently offline changqingFriend
Messages: 16
Registered: July 2009
Junior Member
Thanks a lot! Do me a big favor!
Previous Topic:How to generate executable file to my editor
Next Topic:Is there a listener for open diagram
Goto Forum:
  


Current Time: Thu Apr 25 11:26:40 GMT 2024

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

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

Back to the top