Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » How to open Java Editor
How to open Java Editor [message #511020] Fri, 29 January 2010 10:01 Go to next message
Eclipse UserFriend
Hi,

I need to add a Java Editor to my RCP because I'm generating Java code through model to text transformation using MOFScript.

Currently I use this method to open MOFScript Editor:

IWorkbenchPage.openEditor(EditorInput input, String editorID)


But I don't know what's JavaEditor ID.

Any help?
Re: How to open Java Editor [message #511087 is a reply to message #511020] Fri, 29 January 2010 13:26 Go to previous messageGo to next message
Eclipse UserFriend
Fabricio Pellegrini wrote:
> But I don't know what's JavaEditor ID.

In an open Java editor, you can use ALT+SHIFT+F1 (Plug-in Spy) to find
that out.

PW


--
Paul Webster
http://wiki.eclipse.org/Platform_Command_Framework
http://wiki.eclipse.org/Command_Core_Expressions
http://wiki.eclipse.org/Menu_Contributions
http://wiki.eclipse.org/Menus_Extension_Mapping
http://help.eclipse.org/galileo/index.jsp?topic=/org.eclipse .platform.doc.isv/guide/workbench.htm
Re: How to open Java Editor [message #511496 is a reply to message #511087] Mon, 01 February 2010 13:20 Go to previous messageGo to next message
Eclipse UserFriend
I found this ID org.eclipse.jdt.ui.CompilationUnitEditor

But it didn't work

org.eclipse.ui.PartInitException: Unable to open editor, unknown editor ID: org.eclipse.jdt.ui.CompilationUnitEditor


I also tried to use org.eclipse.jdt.ui.JavaUI.ID_CU_EDITOR but i got the same exception.
Re: How to open Java Editor [message #511587 is a reply to message #511496] Tue, 02 February 2010 03:12 Go to previous messageGo to next message
Eclipse UserFriend
Fabricio Pellegrini wrote:
> I found this ID org.eclipse.jdt.ui.CompilationUnitEditor
>
> But it didn't work
>
> org.eclipse.ui.PartInitException: Unable to open editor, unknown
> editor ID: org.eclipse.jdt.ui.CompilationUnitEditor
You probably forgot to add 'org.eclipse.jdt.ui' as required bundle.

Dani
>
> I also tried to use org.eclipse.jdt.ui.JavaUI.ID_CU_EDITOR but i got
> the same exception.
Re: How to open Java Editor [message #511672 is a reply to message #511587] Tue, 02 February 2010 08:58 Go to previous messageGo to next message
Eclipse UserFriend
I already did it Crying or Very Sad

Can be it beacuse I'm using Eclipse Europa?
Re: How to open Java Editor [message #511698 is a reply to message #511672] Tue, 02 February 2010 10:02 Go to previous message
Eclipse UserFriend
Fabricio Pellegrini wrote:
> I already did it :cry:
> Can be it beacuse I'm using Eclipse Europa?
No, but maybe some required bundles are missing. I suggest you start
with "-debug -consolelog" and take a look at the console.

Dani
Previous Topic:Java Build Path: Diff between Add Jars, Add External Jars, Add Library ?
Next Topic:How to create Marker on elements which are not IResource?
Goto Forum:
  


Current Time: Sun Mar 16 06:36:40 EDT 2025

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

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

Back to the top