Skip to main content



      Home
Home » Modeling » Graphiti » Algorithm for laying out children of containers on borders
Algorithm for laying out children of containers on borders [message #1266454] Fri, 07 March 2014 08:34 Go to next message
Eclipse UserFriend
Hi

I am looking for examples of how to layout children of containers. For
example I have a Rectangle (Component) that has Ellipses (Ports) on the
border. I am using the Etrice code as an example but the layout is not
quite working for me. Wonder if there is other code smaples or
algorithms for layout.

thanks

-H
Re: Algorithm for laying out children of containers on borders [message #1268484 is a reply to message #1266454] Mon, 10 March 2014 11:03 Go to previous message
Eclipse UserFriend
Hi,

layouting inside a container is simply done by setting the x and y
coordinates of the inner shapes. These coordinates must be relative to the
next active outer shape. Basically this resembles a plain Draw2d XYLayout.

Not sure what ETrice does on top of that...

Did you have a look into the filesystem example? It shows at least some
basic nesting (a list of sub shapes) or the tutorial (there is a anchor port
right at one of the edges).

Michael
Previous Topic:How to expand 'Data items'?
Next Topic:Shape, Connection & Properties View
Goto Forum:
  


Current Time: Sun Sep 14 17:42:39 EDT 2025

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

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

Back to the top