Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Dynamic Languages Toolkit (DLTK) » Misleading error when creating Editor Part
Misleading error when creating Editor Part [message #17182] Thu, 01 November 2007 17:49 Go to next message
Eclipse UserFriend
Originally posted by: no.ddress.now

Exploring the port of an existing Editor to Dltk 0.91 (Eclispe 3.3.1.1/JDK 1.5)
to pickup additional funcitonality.

Now to the point of just trying to get the Editor to open, but runinng into the
following -- very confused -- error.

The exception occurs when the editor part control is being created by

EditorReference#createPartHelper at the line "part.createPartControl(content);"

The createPartControl method is actually failing in ScriptEditor#installSemanticHighlighting
on the line:

fSemanticManager.install(this, (ScriptSourceViewer) getSourceViewer(),
getTextTools().getColorManager(), getPreferenceStore());

Except, in debugging, all of the class types are correct. Any idea how to figure
out where the real problem is?

Thanks,
Gerald


java.lang.ClassCastException: org.eclipse.jface.text.presentation.PresentationReconciler
at org.eclipse.dltk.internal.ui.editor.SemanticHighlightingMana ger.install(SemanticHighlightingManager.java:288)
at org.eclipse.dltk.internal.ui.editor.ScriptEditor.installSema nticHighlighting(ScriptEditor.java:2925)
at org.eclipse.dltk.internal.ui.editor.ScriptEditor.createPartC ontrol(ScriptEditor.java:1845)
at org.eclipse.ui.internal.EditorReference.createPartHelper(Edi torReference.java:661)
at org.eclipse.ui.internal.EditorReference.createPart(EditorRef erence.java:426)
at org.eclipse.ui.internal.WorkbenchPartReference.getPart(Workb enchPartReference.java:592)
at org.eclipse.ui.internal.EditorAreaHelper.setVisibleEditor(Ed itorAreaHelper.java:263)
at org.eclipse.ui.internal.EditorManager.setVisibleEditor(Edito rManager.java:1405)
at org.eclipse.ui.internal.EditorManager$5.runWithException(Edi torManager.java:939)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run (StartupThreading.java:31)
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:3659)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(Work benchAdvisor.java:801)
at org.eclipse.ui.internal.Workbench$25.runWithException(Workbe nch.java:1342)
at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run (StartupThreading.java:31)
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:3659)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2309)
at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:22 19)
at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
at org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:289)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:461)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
at org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:106)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:169)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:106)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:76)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:363)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:176)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 508)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
at org.eclipse.equinox.launcher.Main.run(Main.java:1173)
at org.eclipse.equinox.launcher.Main.main(Main.java:1148)

--
Gerald Rosenberg
Certiv
Re: Misleading error when creating Editor Part [message #17343 is a reply to message #17182] Mon, 12 November 2007 13:03 Go to previous message
Andrei Sobolev is currently offline Andrei SobolevFriend
Messages: 72
Registered: July 2009
Member
Hi Gerald,


Please check what your
SourceViewerConfiguration.getPresentationReconciler() method returns
ScriptPresentationReconciler class.

Best regards,
Andrei.

> Exploring the port of an existing Editor to Dltk 0.91 (Eclispe 3.3.1.1/JDK 1.5)
> to pickup additional funcitonality.
>
> Now to the point of just trying to get the Editor to open, but runinng into the
> following -- very confused -- error.
>
> The exception occurs when the editor part control is being created by
>
> EditorReference#createPartHelper at the line "part.createPartControl(content);"
>
> The createPartControl method is actually failing in ScriptEditor#installSemanticHighlighting
> on the line:
>
> fSemanticManager.install(this, (ScriptSourceViewer) getSourceViewer(),
> getTextTools().getColorManager(), getPreferenceStore());
>
> Except, in debugging, all of the class types are correct. Any idea how to figure
> out where the real problem is?
>
> Thanks,
> Gerald
>
>
> java.lang.ClassCastException: org.eclipse.jface.text.presentation.PresentationReconciler
> at org.eclipse.dltk.internal.ui.editor.SemanticHighlightingMana ger.install(SemanticHighlightingManager.java:288)
> at org.eclipse.dltk.internal.ui.editor.ScriptEditor.installSema nticHighlighting(ScriptEditor.java:2925)
> at org.eclipse.dltk.internal.ui.editor.ScriptEditor.createPartC ontrol(ScriptEditor.java:1845)
> at org.eclipse.ui.internal.EditorReference.createPartHelper(Edi torReference.java:661)
> at org.eclipse.ui.internal.EditorReference.createPart(EditorRef erence.java:426)
> at org.eclipse.ui.internal.WorkbenchPartReference.getPart(Workb enchPartReference.java:592)
> at org.eclipse.ui.internal.EditorAreaHelper.setVisibleEditor(Ed itorAreaHelper.java:263)
> at org.eclipse.ui.internal.EditorManager.setVisibleEditor(Edito rManager.java:1405)
> at org.eclipse.ui.internal.EditorManager$5.runWithException(Edi torManager.java:939)
> at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run (StartupThreading.java:31)
> 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:3659)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
> at org.eclipse.ui.application.WorkbenchAdvisor.openWindows(Work benchAdvisor.java:801)
> at org.eclipse.ui.internal.Workbench$25.runWithException(Workbe nch.java:1342)
> at org.eclipse.ui.internal.StartupThreading$StartupRunnable.run (StartupThreading.java:31)
> 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:3659)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :3296)
> at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:2309)
> at org.eclipse.ui.internal.Workbench.access$4(Workbench.java:22 19)
> at org.eclipse.ui.internal.Workbench$4.run(Workbench.java:466)
> at org.eclipse.core.databinding.observable.Realm.runWithDefault (Realm.java:289)
> at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:461)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:149)
> at org.eclipse.ui.internal.ide.application.IDEApplication.start (IDEApplication.java:106)
> at org.eclipse.equinox.internal.app.EclipseAppHandle.run(Eclips eAppHandle.java:169)
> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .runApplication(EclipseAppLauncher.java:106)
> at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher .start(EclipseAppLauncher.java:76)
> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:363)
> at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:176)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
> at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
> at java.lang.reflect.Method.invoke(Unknown Source)
> at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java: 508)
> at org.eclipse.equinox.launcher.Main.basicRun(Main.java:447)
> at org.eclipse.equinox.launcher.Main.run(Main.java:1173)
> at org.eclipse.equinox.launcher.Main.main(Main.java:1148)
>
Previous Topic:code refactoring question, renaming a lot of procs names shared over many files
Next Topic:Heap error
Goto Forum:
  


Current Time: Tue Apr 23 11:39:06 GMT 2024

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

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

Back to the top