Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Please help!
Please help! [message #58501] Tue, 28 January 2003 01:15 Go to next message
Eclipse UserFriend
Originally posted by: jim.azeltine.indus.com

I am trying very hard to get a grip on GEF, but this is getting very
frustrating. I am unable to get some of the examples to work. The first is
the Shapes example. In the following:
import com.ibm.etools.gef.examples.shapes.model.Ellipse;
import com.ibm.etools.gef.examples.shapes.model.Rectangle;
import com.ibm.etools.gef.examples.shapes.model.RoundedRectangle;
import com.ibm.etools.gef.palette.*;
import com.ibm.etools.gef.requests.CreateRequest;
import com.ibm.etools.gef.tools.CreationTool;
I do not have the same packages in my Eclipse install of GEF. Instead of
com.ibm.etools.gef, I have org.eclipse.gef.
So once I change all the package names, I still have an error:
The method shown is undefined for type DefaultPaletteCategory:
category.setChildren(groups);
I think there is probably more. Is there any possibility of getting a
version of this that works without modification?
Re: Please help! [message #59046 is a reply to message #58501] Tue, 28 January 2003 22:42 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

Please load the Logic example, the Hello example is not provided by the GEF
team.

"Jim Azeltine" <jim.azeltine@indus.com> wrote in message
news:b14lk3$vm8$1@rogue.oti.com...
> I am trying very hard to get a grip on GEF, but this is getting very
> frustrating. I am unable to get some of the examples to work. The first is
> the Shapes example. In the following:
> import com.ibm.etools.gef.examples.shapes.model.Ellipse;
> import com.ibm.etools.gef.examples.shapes.model.Rectangle;
> import com.ibm.etools.gef.examples.shapes.model.RoundedRectangle;
> import com.ibm.etools.gef.palette.*;
> import com.ibm.etools.gef.requests.CreateRequest;
> import com.ibm.etools.gef.tools.CreationTool;
> I do not have the same packages in my Eclipse install of GEF. Instead of
> com.ibm.etools.gef, I have org.eclipse.gef.
> So once I change all the package names, I still have an error:
> The method shown is undefined for type DefaultPaletteCategory:
> category.setChildren(groups);
> I think there is probably more. Is there any possibility of getting a
> version of this that works without modification?
>
>
>
>
>
>
Re: Please help! [message #59071 is a reply to message #59046] Tue, 28 January 2003 22:50 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: jim.azeltine.indus.com

I was not referring to any Hello examples, they work fine. I was referring
to the Shapes example.
Randy Hudson wrote:

> Please load the Logic example, the Hello example is not provided by the GEF
> team.

> "Jim Azeltine" <jim.azeltine@indus.com> wrote in message
> news:b14lk3$vm8$1@rogue.oti.com...
> > I am trying very hard to get a grip on GEF, but this is getting very
> > frustrating. I am unable to get some of the examples to work. The first is
> > the Shapes example. In the following:
> > import com.ibm.etools.gef.examples.shapes.model.Ellipse;
> > import com.ibm.etools.gef.examples.shapes.model.Rectangle;
> > import com.ibm.etools.gef.examples.shapes.model.RoundedRectangle;
> > import com.ibm.etools.gef.palette.*;
> > import com.ibm.etools.gef.requests.CreateRequest;
> > import com.ibm.etools.gef.tools.CreationTool;
> > I do not have the same packages in my Eclipse install of GEF. Instead of
> > com.ibm.etools.gef, I have org.eclipse.gef.
> > So once I change all the package names, I still have an error:
> > The method shown is undefined for type DefaultPaletteCategory:
> > category.setChildren(groups);
> > I think there is probably more. Is there any possibility of getting a
> > version of this that works without modification?
> >
> >
> >
> >
> >
> >
Re: Please help! [message #59275 is a reply to message #58501] Wed, 29 January 2003 11:51 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: marazik.holosofx.com

Hi,

In ShapePlugin class
in createComponentsCategory() method
change both
category.setChildren(groups);
to be
category.addAll(groups);
&
group.setChildren(entries);
to be
group.addAll(entries);

The reason for this is
category is an instance of DefaultPaletteCategory &
group is an instance of DefaultPaletteGroup
both of these classes inherit from DefaultPaletteContainer where addAll
seems to replace the setChildren

Also u will need to make another change at ShapeEditPolicy
DeleteRequest seems to be deprected also.
So u will need to change the parameter passed to the createDeleteCommand
method
to be GroupRequest (and of course import
org.eclipse.gef.requests.GroupRequest)
Notice that this parameter is never used inside the method.

I wish the previous will help u.

"Jim Azeltine" <jim.azeltine@indus.com> wrote in message
news:b14lk3$vm8$1@rogue.oti.com...
> I am trying very hard to get a grip on GEF, but this is getting very
> frustrating. I am unable to get some of the examples to work. The first is
> the Shapes example. In the following:
> import com.ibm.etools.gef.examples.shapes.model.Ellipse;
> import com.ibm.etools.gef.examples.shapes.model.Rectangle;
> import com.ibm.etools.gef.examples.shapes.model.RoundedRectangle;
> import com.ibm.etools.gef.palette.*;
> import com.ibm.etools.gef.requests.CreateRequest;
> import com.ibm.etools.gef.tools.CreationTool;
> I do not have the same packages in my Eclipse install of GEF. Instead of
> com.ibm.etools.gef, I have org.eclipse.gef.
> So once I change all the package names, I still have an error:
> The method shown is undefined for type DefaultPaletteCategory:
> category.setChildren(groups);
> I think there is probably more. Is there any possibility of getting a
> version of this that works without modification?
>
>
>
>
>
>
Re: Please help! [message #59929 is a reply to message #59275] Wed, 29 January 2003 21:39 Go to previous message
Eclipse UserFriend
Originally posted by: jim.azeltine.indus.com

You are exactly right. I had started to do what you said, but decided I
didn't have the time to mess with it. I contacted Eric Bordeau, and he
pointed me to an old version of gef and draw2d that would work, so I
installed this in an isolated version of eclipse, and got it working.

Jim

AbdElRazik wrote:

> Hi,

> In ShapePlugin class
> in createComponentsCategory() method
> change both
> category.setChildren(groups);
> to be
> category.addAll(groups);
> &
> group.setChildren(entries);
> to be
> group.addAll(entries);

> The reason for this is
> category is an instance of DefaultPaletteCategory &
> group is an instance of DefaultPaletteGroup
> both of these classes inherit from DefaultPaletteContainer where addAll
> seems to replace the setChildren

> Also u will need to make another change at ShapeEditPolicy
> DeleteRequest seems to be deprected also.
> So u will need to change the parameter passed to the createDeleteCommand
> method
> to be GroupRequest (and of course import
> org.eclipse.gef.requests.GroupRequest)
> Notice that this parameter is never used inside the method.

> I wish the previous will help u.

> "Jim Azeltine" <jim.azeltine@indus.com> wrote in message
> news:b14lk3$vm8$1@rogue.oti.com...
> > I am trying very hard to get a grip on GEF, but this is getting very
> > frustrating. I am unable to get some of the examples to work. The first is
> > the Shapes example. In the following:
> > import com.ibm.etools.gef.examples.shapes.model.Ellipse;
> > import com.ibm.etools.gef.examples.shapes.model.Rectangle;
> > import com.ibm.etools.gef.examples.shapes.model.RoundedRectangle;
> > import com.ibm.etools.gef.palette.*;
> > import com.ibm.etools.gef.requests.CreateRequest;
> > import com.ibm.etools.gef.tools.CreationTool;
> > I do not have the same packages in my Eclipse install of GEF. Instead of
> > com.ibm.etools.gef, I have org.eclipse.gef.
> > So once I change all the package names, I still have an error:
> > The method shown is undefined for type DefaultPaletteCategory:
> > category.setChildren(groups);
> > I think there is probably more. Is there any possibility of getting a
> > version of this that works without modification?
> >
> >
> >
> >
> >
> >
Previous Topic:Header Control
Next Topic:A word about examples and GEF
Goto Forum:
  


Current Time: Fri Jul 19 07:26:29 GMT 2024

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

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

Back to the top