Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » Java Development Tools (JDT) » Use of TextEditor on a non file input
Use of TextEditor on a non file input [message #249505] Mon, 12 November 2007 10:03 Go to next message
François is currently offline FrançoisFriend
Messages: 21
Registered: July 2009
Junior Member
Hello !

I have an xmi file that I load and the root object contains a large String
as a dDescription. I want to create a text editor which contents is this
description.

I tried to subclass the TextFileDocumentProvider class overriding the
getDocument(Object element) method as following :
public IDocument getDocument(Object element) {
//return super.getDocument(element);
if ( event == null )
return null;
return new Document( event.getSummary() );
}

But this does not work... What should I do ?

François
Re: Use of TextEditor on a non file input [message #249509 is a reply to message #249505] Mon, 12 November 2007 10:49 Go to previous message
François is currently offline FrançoisFriend
Messages: 21
Registered: July 2009
Junior Member
Okay I got it work just by disabling the annotation model for my purpose.

@Override
public IAnnotationModel getAnnotationModel(Object element) {
return null;
}
Previous Topic:Mouse Event in Eclipse plugin
Next Topic:Adding action to the refactoring main menu
Goto Forum:
  


Current Time: Fri Nov 08 23:21:33 GMT 2024

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

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

Back to the top