Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » gmfgraph -> Node -> Content Pane
gmfgraph -> Node -> Content Pane [message #645125] Wed, 15 December 2010 16:21 Go to previous message
Eclipse UserFriend
Originally posted by: marius.groeger.googlemail.com

Hello,

in a figure (rectangle) I have a simple GridLayout and two children, the
label and another rectangle. Now I want children of this element to live
inside that nested rectangle (I think this is what Alex Shatalin meant
in [1])

+---------------+
| Label |
| +-----------+ |
| | | |
| | Container | |
| | for | |
| | Children | |
| | | |
| +-----------+ |
+---------------+

I thought I could tell the generator this via the Node -> Content Pane
attribute. This accepts a child accessor, which I created for my nested
rectangle. However the diagram still wants to place children in the main
rectangle. If I add this to createNodeFigure() in my EditPart:

contentPane = setupContentPane(shape);
contentPane = ((MyFigure)contentPane).getFigureContainerArea();

then it actually works! (The nested rectangle uses an XY layout, and
when I move a child I get this strange 'phantom' feedback rectangles
that don't go away, but this is probably a different problem).

So what is the matter with Content Pane - is it supposed to work, and if
so, how?

I do not want to use Compartments, as I had different layout and design
problems with those in the past.

Thanks
Marius

[1] http://dev.eclipse.org/newslists/news.eclipse.modeling.gmf/m sg12818.html
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic:Multiple EditParts for one semantic element
Next Topic:problem with generated rcp diagram plugin not activated
Goto Forum:
  


Current Time: Thu Apr 25 04:54:16 GMT 2024

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

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

Back to the top