Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » Graphiti » ContainerShape without model representation
ContainerShape without model representation [message #1829397] Thu, 02 July 2020 16:56 Go to next message
Alex Kravets is currently offline Alex KravetsFriend
Messages: 561
Registered: November 2009
Senior Member
I am looking to create a Multi-Text rectangle that can accept other shapes, but addition of these shapes does not update underlying model of the text object - another words the containment is only at UI level, not the model. How can I achieve this behavior? Thank you.
Re: ContainerShape without model representation [message #1829419 is a reply to message #1829397] Fri, 03 July 2020 06:26 Go to previous messageGo to next message
Michael Wenz is currently offline Michael WenzFriend
Messages: 1931
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Alex,

not sure if I understood that correctly. The hierarchy of the graphical representation in Graphiti and the hierarchy of the underlying model can be completely independent. You can have add or custom features that add the additional shape as child of the rectangle, but add the model object somewhere else. The association between model and graphics is then usually done by just linking the 2 objects.

HTH,
Michael
Re: ContainerShape without model representation [message #1834148 is a reply to message #1829419] Tue, 03 November 2020 20:28 Go to previous messageGo to next message
Alex Kravets is currently offline Alex KravetsFriend
Messages: 561
Registered: November 2009
Senior Member
Got sidetracked on other projects so had to halt work on this.

I am looking to create a box conduit of sort that other objects can be dropped onto and when the conduit is moved, objects inside it move as well. Not a hard thing to do as it's a ShapeContainer. This element will have its own palette object that can be dropped onto a diagram, but it will not have a model associated with it, so what interface do I implement for this since ICreate expects model object to be returned?

https://mac-cdn.softpedia.com/screenshots/Yaoqiang-BPMN-Editor_11.jpg

[Updated on: Wed, 04 November 2020 01:12]

Report message to a moderator

Re: ContainerShape without model representation [message #1834213 is a reply to message #1834148] Thu, 05 November 2020 07:25 Go to previous messageGo to next message
Michael Wenz is currently offline Michael WenzFriend
Messages: 1931
Registered: July 2009
Location: Walldorf, Germany
Senior Member
Alex,

it expects an object to be returned, this does not necessarily need to be a model object. You could e.g. return the (root) pictogram element or I think even null should work.

Michael
Re: ContainerShape without model representation [message #1834388 is a reply to message #1834213] Mon, 09 November 2020 14:27 Go to previous message
Alex Kravets is currently offline Alex KravetsFriend
Messages: 561
Registered: November 2009
Senior Member
Thank you Michael.
Previous Topic:Expose IDPattern IDs
Next Topic:Undoing multiple commands during Graphiti undo execution
Goto Forum:
  


Current Time: Fri Apr 19 20:30:01 GMT 2024

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

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

Back to the top