Skip to main content



      Home
Home » Eclipse Projects » Sirius » How to control size of drawing canvas(How to control size of drawing canvas)
How to control size of drawing canvas [message #1817017] Thu, 14 November 2019 00:55 Go to next message
Eclipse UserFriend
Hi,
I am trying to control size of sirius drawing canvas, it seems the size of the Sirius diagram depends on the position of the element on the bottom-right corner of the diagram, but once diagram is full and user tries to resize, first user needs to put a node at bottom right corner and then drag again to resize diagram which does not look good during the demos.
Can someone please let me know how can we add a listener and change size of drawing canvas so that it automatically resize based on some event.

Thanks in Advance
Mohit Advani
Re: How to control size of drawing canvas [message #1817028 is a reply to message #1817017] Thu, 14 November 2019 04:45 Go to previous messageGo to next message
Eclipse UserFriend
Hi Mohit,

You might try to a some kind of anchor node :
- node mapping with the same domain class than the diagram and aql:self as semantic candidates expression
- with a specific style and a small size.

Then you might add a ModelChangeTrigger or a pre-commit listener to react to changes on diagrams at the GMF level. I would try to detect the add/move/resize of GMF views (LayoutConstraint/Bounds/Size) elements and if needed retrieve and update the location of the anchor node to automatically move it in order to resize the diagram.

Regards
Re: How to control size of drawing canvas [message #1817076 is a reply to message #1817028] Fri, 15 November 2019 02:25 Go to previous message
Eclipse UserFriend
Hi Maxime,

Thanks for your quick reply, how can i get GMF object from my diagram object , is there any direct methods to change at GMF level or any configuration changes i need for GMF related changes?

Thanks and Regards
Mohit Advani


Previous Topic:Get selected item value in capella diagram
Next Topic:Unable to create working Element based edge
Goto Forum:
  


Current Time: Sun Jul 27 06:52:17 EDT 2025

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

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

Back to the top