Composition of EditParts? [message #183637] |
Mon, 06 June 2005 00:53  |
Eclipse User |
|
|
|
Hello.
I want to make an entity for my model that looks like this:
http://img.photobucket.com/albums/v495/_sl0t_/image.gif
This entity is composed by two sections. The top section is very similar
to an UML Class and the bottom section is an edition area where other
elements can be placed inside this entity.
Those two sections should have their own edit policies, so I made one
editpart for each one:
The top area's editpart is based from ClassEditPart, from eDiagram
example. Structural and behavioral features can be placed on this section.
The bottom area's editpart is based from LogicEditPart, from Logic
example. Others entities can be placed anywhere inside this section, like
the Circuit from Logic example.
But I need to treat both sections as the one entity they are. That means
they both have to be moved around together when I drag and drop one of
them, and I also wanna be able to resize one of them without affecting the
size of both sections (that means I may resize any of the two sections at
any time, but this operation must be restricted to the section I am
resizing, not both at same time).
The top section -must- be always attached to the top of the bottom
section, but it would be nice if I was able to "slide" it through the top
of the bottom section (maybe by drag and drop with mouse right button). I
don't know if this is possible and right now I would be glad if it was
just attached at the top left, so this can wait. :)
Is there any way to make this work? Maybe make a new edipart composed of
those two I already have or a new edipart that has different policies for
each section.
Thanks in advance.
Fábio Sobral.
|
|
|
|
|
Re: Composition of EditParts? [message #183704 is a reply to message #183677] |
Mon, 06 June 2005 21:25  |
Eclipse User |
|
|
|
I tought about that but I'm not sure how I'm supposed to do this, since
both sections would refer to the same element and I would always have one
of each. In the eDiagram example the ClassEditPart has lists of attributes
and operations and each one refers to a separate element.
Thanks for the help. :)
|
|
|
Powered by
FUDForum. Page generated in 0.03061 seconds