Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Visual Editor (VE) » Create Visual SWT class not directly from Composite but from derived class
Create Visual SWT class not directly from Composite but from derived class [message #114531] Thu, 05 January 2006 11:41 Go to next message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Hello,

I want to create a SWT visual class not directly from Comoposite but from
a dreived class. Example:

public class Screen extends Composite

public class PreferenceScreen extends Screen

If I try to create now PreferenceScreen as a visual SWT class, I cannot
work with the VE because the typical Composite surface does not appear.

How can I solve this problem ? I am using VE 1.1 on Eclipse 3.1, does a
upgrade to 1.2 help?

Many thanks in advance and a happy new year!
René
Re: Create Visual SWT class not directly from Composite but from derived class [message #115222 is a reply to message #114531] Tue, 10 January 2006 16:54 Go to previous messageGo to next message
Joe Winchester is currently offline Joe WinchesterFriend
Messages: 496
Registered: July 2009
Senior Member
Hi Rene,

> public class Screen extends Composite public class PreferenceScreen
> extends Screen


> If I try to create now PreferenceScreen as a visual SWT class, I cannot
> work with the VE because the typical Composite surface does not appear.

It should. This is no different from Canvas extends Composite and the
custom widgets that extend Canvas. Is there anything in the Error Log ?
What happens when you open the VE - what do you see instead of the visual
surface ?

Best regards,

Joe Winchester
Re: Create Visual SWT class not directly from Composite but from derived class [message #119810 is a reply to message #115222] Sat, 04 March 2006 15:15 Go to previous messageGo to next message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Hello Joe,

first thanks for your answer and sorry for my late reply. I just don't see
anything on the visual surface, the whole composite disappears.

The Exception that occurs:

IWAV0073I *** RemoteVM Exception - Trace from Remote VM:
org.eclipse.jem.internal.proxy.initParser.tree.NoExpressionV alueException:
Proxy id: 0
at
org.eclipse.jem.internal.proxy.initParser.tree.ExpressionPro cesser.pushExpressionProxy(ExpressionProcesser.java:829)
at
org.eclipse.jem.internal.proxy.vm.remote.ExpressionProcesser Controller.process(ExpressionProcesserController.java:320)
at
org.eclipse.jem.internal.proxy.vm.remote.ConnectionHandler.p rocessExpressionCommand(ConnectionHandler.java:602)
at
org.eclipse.jem.internal.proxy.vm.remote.ConnectionHandler.r un(ConnectionHandler.java:493)
at
org.eclipse.jem.internal.proxy.vm.remote.CallbackHandler.cal lbackWithParms(CallbackHandler.java:150)
at
org.eclipse.ve.internal.swt.targetvm.DisplayExec$1.run(Displ ayExec.java:111)
at
org.eclipse.jem.internal.proxy.vm.remote.RemoteVMServerThrea d.doCallback(RemoteVMServerThread.java:541)
at
org.eclipse.ve.internal.swt.targetvm.DisplayExec$ExecRunnabl e.run(DisplayExec.java:109)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:3264)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2910)
at
org.eclipse.ve.internal.swt.targetvm.Environment$3.run(Envir onment.java:121)
IWAV0074I *** Local StackTrace:
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanProxyP roxy:
org.eclipse.jem.internal.proxy.initParser.tree.NoExpressionV alueException:
Proxy id: 0
at
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanTypePr oxy.createThrowableBeanProxy(REMThrowableBeanTypeProxy.java: 34)
at
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanTypePr oxy.newBeanProxy(REMThrowableBeanTypeProxy.java:65)
at
org.eclipse.jem.internal.proxy.remote.REMStandardBeanProxyFa ctory.getBeanProxy(REMStandardBeanProxyFactory.java:459)
at
org.eclipse.jem.internal.proxy.remote.REMExpression.pushInvo ke(REMExpression.java:983)
at
org.eclipse.jem.internal.proxy.core.Expression.invokeExpress ion(Expression.java:685)
at
org.eclipse.ve.internal.java.core.BeanProxyAdapter.notifyCha nged(BeanProxyAdapter.java:2003)
at
org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify (BasicNotifierImpl.java:230)
at
org.eclipse.emf.common.notify.impl.NotificationChainImpl.dis patch(NotificationChainImpl.java:113)
at
org.eclipse.emf.common.notify.impl.NotificationChainImpl.dis patch(NotificationChainImpl.java:101)
at
org.eclipse.emf.ecore.impl.EStructuralFeatureImpl$InternalSe ttingDelegateSingleEObject.dynamicSet(EStructuralFeatureImpl .java:2384)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eDynamicSet(Basi cEObjectImpl.java:649)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjec tImpl.java:623)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjec tImpl.java:605)
at
org.eclipse.jem.internal.instantiation.base.JavaInstance.set Allocation(JavaInstance.java:104)
at
org.eclipse.ve.internal.java.codegen.java.ConstructorDecoder Helper.decode(ConstructorDecoderHelper.java:610)
at
org.eclipse.ve.internal.swt.codegen.SWTConstructorDecoderHel per.decode(SWTConstructorDecoderHelper.java:283)
at
org.eclipse.ve.internal.java.codegen.java.AbstractExpression Decoder.decode(AbstractExpressionDecoder.java:154)
at
org.eclipse.ve.internal.java.codegen.model.CodeExpressionRef .refreshFromJOM(CodeExpressionRef.java:540)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.processE quivalentExpressions(BDMMerger.java:585)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.processI nitExpressions(BDMMerger.java:1108)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.updateRe gularBeanPartExpressions(BDMMerger.java:1066)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.mergeAll Beans(BDMMerger.java:929)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.merge(BD MMerger.java:105)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.merge(JavaSourceTranslator.java:388)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.handleParseable(JavaSourceTranslator .java:434)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.run(JavaSourceTranslator.java:502)
at
org.eclipse.ve.internal.java.codegen.java.SnippetParseJob.do Run(SnippetParseJob.java:92)
at
org.eclipse.ve.internal.java.codegen.util.ReverseParserJob.r un(ReverseParserJob.java:56)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:58)
Addendum [message #119821 is a reply to message #119810] Sat, 04 March 2006 15:19 Go to previous messageGo to next message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Forgot to mention that now I use VE 1.2 M2. The problem occured also in
the VE 1.1 Version.

Greets,
René
Re: Addendum [message #119861 is a reply to message #119821] Sun, 05 March 2006 22:36 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Please attach the entire .log file. the error displayed is typically one
that results because there was another error before that.

Make sure that you are using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF 2.2M5
with VE 1.2M2.

René Ott wrote:
> Forgot to mention that now I use VE 1.2 M2. The problem occured also in
> the VE 1.1 Version.
>
> Greets,
> René
>

--
Thanks,
Rich Kulp
Re: Addendum [message #120221 is a reply to message #119861] Tue, 07 March 2006 18:37 Go to previous messageGo to next message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Thanks for your help. Im am using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF 2.2M5
with VE 1.2M2. The logfile is quite large thats why I put it online:

http://www.ososoft.de/logfile/logfile.log

If I Change

public class WelcomeScreenPL extends Composite

to

public class WelcomeScreenPL extends ScreenPL
(ScreenPL is derived from Composite)

Then the visual area disappears and the errors occur. What can I do, does
a workaround for this Problem exist? Would be great if I can use the VE
with derived classes cause we are working here on a large framework and
this would save quite a lot time.

Greets,
René
Re: Addendum [message #120234 is a reply to message #120221] Tue, 07 March 2006 19:29 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Ah, I wasn't clear to me at first what you were trying to do.
Unfortunately the VE doesn't support subclass of a subclass of a visual
class. We only really support direct subclasses of a visual. :-(

René Ott wrote:
> Thanks for your help. Im am using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF
> 2.2M5 with VE 1.2M2. The logfile is quite large thats why I put it online:
>
> http://www.ososoft.de/logfile/logfile.log
>
> If I Change
> public class WelcomeScreenPL extends Composite
>
> to
>
> public class WelcomeScreenPL extends ScreenPL
> (ScreenPL is derived from Composite)
>
> Then the visual area disappears and the errors occur. What can I do,
> does a workaround for this Problem exist? Would be great if I can use
> the VE with derived classes cause we are working here on a large
> framework and this would save quite a lot time.
>
> Greets,
> René
>
>
>

--
Thanks,
Rich Kulp
Re: Create Visual SWT class not directly from Composite but from derived class [message #611778 is a reply to message #114531] Tue, 10 January 2006 16:54 Go to previous message
Joe Winchester is currently offline Joe WinchesterFriend
Messages: 496
Registered: July 2009
Senior Member
Hi Rene,

> public class Screen extends Composite public class PreferenceScreen
> extends Screen


> If I try to create now PreferenceScreen as a visual SWT class, I cannot
> work with the VE because the typical Composite surface does not appear.

It should. This is no different from Canvas extends Composite and the
custom widgets that extend Canvas. Is there anything in the Error Log ?
What happens when you open the VE - what do you see instead of the visual
surface ?

Best regards,

Joe Winchester
Re: Create Visual SWT class not directly from Composite but from derived class [message #612251 is a reply to message #115222] Sat, 04 March 2006 15:15 Go to previous message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Hello Joe,

first thanks for your answer and sorry for my late reply. I just don't see
anything on the visual surface, the whole composite disappears.

The Exception that occurs:

IWAV0073I *** RemoteVM Exception - Trace from Remote VM:
org.eclipse.jem.internal.proxy.initParser.tree.NoExpressionV alueException:
Proxy id: 0
at
org.eclipse.jem.internal.proxy.initParser.tree.ExpressionPro cesser.pushExpressionProxy(ExpressionProcesser.java:829)
at
org.eclipse.jem.internal.proxy.vm.remote.ExpressionProcesser Controller.process(ExpressionProcesserController.java:320)
at
org.eclipse.jem.internal.proxy.vm.remote.ConnectionHandler.p rocessExpressionCommand(ConnectionHandler.java:602)
at
org.eclipse.jem.internal.proxy.vm.remote.ConnectionHandler.r un(ConnectionHandler.java:493)
at
org.eclipse.jem.internal.proxy.vm.remote.CallbackHandler.cal lbackWithParms(CallbackHandler.java:150)
at
org.eclipse.ve.internal.swt.targetvm.DisplayExec$1.run(Displ ayExec.java:111)
at
org.eclipse.jem.internal.proxy.vm.remote.RemoteVMServerThrea d.doCallback(RemoteVMServerThread.java:541)
at
org.eclipse.ve.internal.swt.targetvm.DisplayExec$ExecRunnabl e.run(DisplayExec.java:109)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:3 5)
at
org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchr onizer.java:123)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.jav a:3264)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2910)
at
org.eclipse.ve.internal.swt.targetvm.Environment$3.run(Envir onment.java:121)
IWAV0074I *** Local StackTrace:
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanProxyP roxy:
org.eclipse.jem.internal.proxy.initParser.tree.NoExpressionV alueException:
Proxy id: 0
at
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanTypePr oxy.createThrowableBeanProxy(REMThrowableBeanTypeProxy.java: 34)
at
org.eclipse.jem.internal.proxy.remote.REMThrowableBeanTypePr oxy.newBeanProxy(REMThrowableBeanTypeProxy.java:65)
at
org.eclipse.jem.internal.proxy.remote.REMStandardBeanProxyFa ctory.getBeanProxy(REMStandardBeanProxyFactory.java:459)
at
org.eclipse.jem.internal.proxy.remote.REMExpression.pushInvo ke(REMExpression.java:983)
at
org.eclipse.jem.internal.proxy.core.Expression.invokeExpress ion(Expression.java:685)
at
org.eclipse.ve.internal.java.core.BeanProxyAdapter.notifyCha nged(BeanProxyAdapter.java:2003)
at
org.eclipse.emf.common.notify.impl.BasicNotifierImpl.eNotify (BasicNotifierImpl.java:230)
at
org.eclipse.emf.common.notify.impl.NotificationChainImpl.dis patch(NotificationChainImpl.java:113)
at
org.eclipse.emf.common.notify.impl.NotificationChainImpl.dis patch(NotificationChainImpl.java:101)
at
org.eclipse.emf.ecore.impl.EStructuralFeatureImpl$InternalSe ttingDelegateSingleEObject.dynamicSet(EStructuralFeatureImpl .java:2384)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eDynamicSet(Basi cEObjectImpl.java:649)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjec tImpl.java:623)
at
org.eclipse.emf.ecore.impl.BasicEObjectImpl.eSet(BasicEObjec tImpl.java:605)
at
org.eclipse.jem.internal.instantiation.base.JavaInstance.set Allocation(JavaInstance.java:104)
at
org.eclipse.ve.internal.java.codegen.java.ConstructorDecoder Helper.decode(ConstructorDecoderHelper.java:610)
at
org.eclipse.ve.internal.swt.codegen.SWTConstructorDecoderHel per.decode(SWTConstructorDecoderHelper.java:283)
at
org.eclipse.ve.internal.java.codegen.java.AbstractExpression Decoder.decode(AbstractExpressionDecoder.java:154)
at
org.eclipse.ve.internal.java.codegen.model.CodeExpressionRef .refreshFromJOM(CodeExpressionRef.java:540)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.processE quivalentExpressions(BDMMerger.java:585)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.processI nitExpressions(BDMMerger.java:1108)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.updateRe gularBeanPartExpressions(BDMMerger.java:1066)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.mergeAll Beans(BDMMerger.java:929)
at
org.eclipse.ve.internal.java.codegen.java.BDMMerger.merge(BD MMerger.java:105)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.merge(JavaSourceTranslator.java:388)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.handleParseable(JavaSourceTranslator .java:434)
at
org.eclipse.ve.internal.java.codegen.core.JavaSourceTranslat or$SharedToLocalUpdater.run(JavaSourceTranslator.java:502)
at
org.eclipse.ve.internal.java.codegen.java.SnippetParseJob.do Run(SnippetParseJob.java:92)
at
org.eclipse.ve.internal.java.codegen.util.ReverseParserJob.r un(ReverseParserJob.java:56)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:58)
Addendum [message #612252 is a reply to message #119810] Sat, 04 March 2006 15:19 Go to previous message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Forgot to mention that now I use VE 1.2 M2. The problem occured also in
the VE 1.1 Version.

Greets,
René
Re: Addendum [message #612255 is a reply to message #119821] Sun, 05 March 2006 22:36 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Please attach the entire .log file. the error displayed is typically one
that results because there was another error before that.

Make sure that you are using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF 2.2M5
with VE 1.2M2.

René Ott wrote:
> Forgot to mention that now I use VE 1.2 M2. The problem occured also in
> the VE 1.1 Version.
>
> Greets,
> René
>

--
Thanks,
Rich Kulp
Re: Addendum [message #612284 is a reply to message #119861] Tue, 07 March 2006 18:37 Go to previous message
René Ott is currently offline René OttFriend
Messages: 8
Registered: July 2009
Junior Member
Thanks for your help. Im am using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF 2.2M5
with VE 1.2M2. The logfile is quite large thats why I put it online:

http://www.ososoft.de/logfile/logfile.log

If I Change

public class WelcomeScreenPL extends Composite

to

public class WelcomeScreenPL extends ScreenPL
(ScreenPL is derived from Composite)

Then the visual area disappears and the errors occur. What can I do, does
a workaround for this Problem exist? Would be great if I can use the VE
with derived classes cause we are working here on a large framework and
this would save quite a lot time.

Greets,
René
Re: Addendum [message #612285 is a reply to message #120221] Tue, 07 March 2006 19:29 Go to previous message
Eclipse UserFriend
Originally posted by: richkulp.us.NO_SPAM.ibm.com

Ah, I wasn't clear to me at first what you were trying to do.
Unfortunately the VE doesn't support subclass of a subclass of a visual
class. We only really support direct subclasses of a visual. :-(

René Ott wrote:
> Thanks for your help. Im am using Eclipse SDK 3.2M5a, GEF 3.2M5, EMF
> 2.2M5 with VE 1.2M2. The logfile is quite large thats why I put it online:
>
> http://www.ososoft.de/logfile/logfile.log
>
> If I Change
> public class WelcomeScreenPL extends Composite
>
> to
>
> public class WelcomeScreenPL extends ScreenPL
> (ScreenPL is derived from Composite)
>
> Then the visual area disappears and the errors occur. What can I do,
> does a workaround for this Problem exist? Would be great if I can use
> the VE with derived classes cause we are working here on a large
> framework and this would save quite a lot time.
>
> Greets,
> René
>
>
>

--
Thanks,
Rich Kulp
Previous Topic:swingX for VE
Next Topic:Extract the editpart for a specific component
Goto Forum:
  


Current Time: Fri Apr 19 02:06:34 GMT 2024

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

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

Back to the top