views:

133

answers:

1

Hi,

I am writing a custom editor in a plugin, and I developed it in Galileo. Now I'm trying to run it in Ganymede, but content assist doesn't work. There is no error, just nothing happens when I type "ctrl+space".

The way I'm doing it is by providing a custom Configuration class that extends SourceViewerConfiguration, overriding public IContentAssistant getContentAssistant(ISourceViewer sourceViewer). The method gets called when the editor is created but there is no content assist.

Was there any change from Ganymede to Galileo that I should be aware of?

A: 

I found the answer here: http://wiki.eclipse.org/FAQ_How_do_I_add_Content_Assist_to_my_editor%3F

In Ganymede it's necessary to override createActions to register the content assist one:

Action action = new ContentAssistAction(resourceBundle, "ContentAssistProposal.", this); String id = ITextEditorActionDefinitionIds.CONTENT_ASSIST_PROPOSALS action.setActionDefinitionId(id); setAction("ContentAssistProposal", action); markAsStateDependentAction("ContentAssistProposal", true);

That was not needed in Galileo.

erwan