Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Create Figures within figures like logic Example
Create Figures within figures like logic Example [message #222483] Wed, 06 September 2006 15:43 Go to next message
Eclipse UserFriend
Originally posted by: tobias.brueggendick.prostep.com

Hello Experts,

i'm extending the shapeexample. At the moment i try to create a Figure which
contains other Figures. In this first case a diamond and a rectangle. At the
moment i don't find out how to create it. I'd a look at the logic-example
but i don't really understand how there it works. My Model contains the two
shapes but somehow the editpart don't really creates them.

Greetings Tobias
Re: Create Figures within figures like logic Example [message #222490 is a reply to message #222483] Wed, 06 September 2006 15:56 Go to previous messageGo to next message
Nhu Le is currently offline Nhu LeFriend
Messages: 47
Registered: July 2009
Member
In the editpart, you must have getModelChidren()
In the part factory, you must handle everything that is returned from
getModelChidren()

If the figure doesn't show up, make sure the parent has appropriate
layout manager installed.

All this is detailed in the programmer's guide for GEF.

Nhu Le.

Tobias Brüggendick wrote:
> Hello Experts,
>
> i'm extending the shapeexample. At the moment i try to create a Figure which
> contains other Figures. In this first case a diamond and a rectangle. At the
> moment i don't find out how to create it. I'd a look at the logic-example
> but i don't really understand how there it works. My Model contains the two
> shapes but somehow the editpart don't really creates them.
>
> Greetings Tobias
>
>
Re: Create Figures within figures like logic Example [message #222684 is a reply to message #222490] Thu, 07 September 2006 11:20 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: tobias.brueggendick.prostep.com

So i'v got it. Thanks for your tips Nhu Le. I had read the programmers guide
but somehow it wasn't at least in my mind. I forgot something else which was
the reason why GEF don't displayed the figures inside. My EditPart for the
Container didn't had the Method getContentPane() so GEF was unable to create
the Child-figures.

Tobias

"Nhu Le" <nle.misc@gmail.com> schrieb im Newsbeitrag
news:edmr2m$ur0$3@utils.eclipse.org...
> In the editpart, you must have getModelChidren()
> In the part factory, you must handle everything that is returned from
> getModelChidren()
>
> If the figure doesn't show up, make sure the parent has appropriate layout
> manager installed.
>
> All this is detailed in the programmer's guide for GEF.
>
> Nhu Le.
>
> Tobias Br
Re: Create Figures within figures like logic Example [message #222687 is a reply to message #222684] Thu, 07 September 2006 11:39 Go to previous message
Nhu Le is currently offline Nhu LeFriend
Messages: 47
Registered: July 2009
Member
getContentPane() by default returns the figure itself. You only
override this method if you want the children to be added somewhere else
(in one of the child of this figure)

Nhu Le

Tobias Brüggendick wrote:
> So i'v got it. Thanks for your tips Nhu Le. I had read the programmers guide
> but somehow it wasn't at least in my mind. I forgot something else which was
> the reason why GEF don't displayed the figures inside. My EditPart for the
> Container didn't had the Method getContentPane() so GEF was unable to create
> the Child-figures.
>
> Tobias
>
> "Nhu Le" <nle.misc@gmail.com> schrieb im Newsbeitrag
> news:edmr2m$ur0$3@utils.eclipse.org...
>> In the editpart, you must have getModelChidren()
>> In the part factory, you must handle everything that is returned from
>> getModelChidren()
>>
>> If the figure doesn't show up, make sure the parent has appropriate layout
>> manager installed.
>>
>> All this is detailed in the programmer's guide for GEF.
>>
>> Nhu Le.
>>
>> Tobias Brüggendick wrote:
>>> Hello Experts,
>>>
>>> i'm extending the shapeexample. At the moment i try to create a Figure
>>> which contains other Figures. In this first case a diamond and a
>>> rectangle. At the moment i don't find out how to create it. I'd a look at
>>> the logic-example but i don't really understand how there it works. My
>>> Model contains the two shapes but somehow the editpart don't really
>>> creates them.
>>>
>>> Greetings Tobias
>
>
Previous Topic:Filter items in the outline view
Next Topic:How to create connections in a Container
Goto Forum:
  


Current Time: Tue Dec 23 00:07:29 GMT 2014

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

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