Standalone shapes demo [message #15244] |
Tue, 23 July 2002 13:32  |
Eclipse User |
|
|
|
In an attempt to understand GEF better, I'm trying to create a standalone
shapes app. My first attempt has been to just wrap the ShapeEditor with
some really simple:
Display display = new Display();
Shell shell = new Shell(display);
shell.setLayout(new FillLayout());
ShapeEditor editor = new ShapeEditor();
editor.createPartControl(shell) ;
This seems pretty promising, but I'm getting the following exception:
java.lang.NullPointerException
at
com.ibm.etools.gef.ui.parts.GraphicalEditor.hookGraphicalVie wer(GraphicalEdi
tor.java:113)
at
com.ibm.etools.gef.ui.parts.GraphicalEditor.createGraphicalV iewer(GraphicalE
ditor.java:43)
at
com.ibm.etools.gef.ui.parts.GraphicalEditorWithPalette.creat ePartControl(Gra
phicalEditorWithPalette.java:42)
at com.indigoegg.studio.gui.swt.TestDisplay.foo(TestDisplay.jav a:29)
at com.indigoegg.studio.gui.swt.TestDisplay.main(TestDisplay.ja va:21)
Exception in thread "main"
Can anyone steer me in the right direction?
Thanks!
M
|
|
|
|
|
|
|
|
Re: Standalone shapes demo [message #16772 is a reply to message #16314] |
Tue, 13 August 2002 05:13  |
Eclipse User |
|
|
|
Originally posted by: Bram.Stieperaere.REMOVEskynet.be
I posted a standalone version of the Logic demo a few weeks ago. see the
wiki for more info.
at http://eclipsewiki.swiki.net/50#logicexamplestandalone
the main() is in the LogicSAMain class
for the list of jars to add, check the wiki.
The logic example "as is" cannot run as a standalone application, because
the lookup of the resourcebundle
goes via the API for plugins. So I "patched" the LogicResources class to go
to the resourcebundle directly. For the rest the application runs perfeclty
in standalone.
Bram
"Marco van Meegen" <marco@mvmsoft.de> wrote in message
news:3D5236CE.5070108@mvmsoft.de...
> if you want GEF without workbench, I guess you should start with Draw2d
> and add all editing-functionality by yourself.
>
> David J. Orme wrote:
> > Ingo Seipp wrote:
> >
> >> Is it possible to have a "stripped-down" gef which includes only the
> >> minimal part of eclipse (maybe workbench +
> >> draw2d),
> >> ideally in pure Java?
> >>
> >> What would be needed for that?
> >
> >
> > There have been a number of discussions about this on eclipse.tools. I'd
> > start by searching for those. My recollection is that there is a
> > minimal number of plugins that you need, plus you will have to change
> > one of them so that it doesn't register some IDE-specific menus with the
> > platform. After that, you're good-to-go.
> >
> >
> > Dave
> >
>
|
|
|
Powered by
FUDForum. Page generated in 0.04327 seconds