Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Adding Content Assist to a WrappingLabel?
Adding Content Assist to a WrappingLabel? [message #556095] Mon, 30 August 2010 14:43 Go to next message
Eclipse UserFriend
Hi,

I need to add Content Assist to a WrappingLabel (org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel).

I had hoped to do this with an ContentProposalAdapter (org.eclipse.jface.fieldassist.ContentProposalAdapter), but the ContentProposalAdapter expects a Control (org.eclipse.swt.widgets.Control) like org.eclipse.swt.widgets.Text .

Any ideas on how to do this? I searched around but can't find any examples where Content Assist was used for anything other than org.eclipse.swt.widgets.Text or texteditors (like this).

I guess I am in way over my head.
Re: Adding Content Assist to a WrappingLabel? [message #630686 is a reply to message #556095] Mon, 04 October 2010 10:37 Go to previous messageGo to next message
Eclipse UserFriend
Bump! :D
Same Problem here.

On 30.08.2010 20:43, tno wrote:
> Hi,
>
> I need to add Content Assist to a WrappingLabel
> (org.eclipse.gmf.runtime.draw2d.ui.figures.WrappingLabel).
> I had hoped to do this with an ContentProposalAdapter
> (org.eclipse.jface.fieldassist.ContentProposalAdapter), but the
> ContentProposalAdapter expects a Control
> (org.eclipse.swt.widgets.Control) like org.eclipse.swt.widgets.Text .
>
> Any ideas on how to do this? I searched around but can't find any
> examples where Content Assist was used for anything other than
> org.eclipse.swt.widgets.Text or texteditors (like
> http://help.eclipse.org/help33/topic/org.eclipse.platform.do c.isv/guide/editors_contentassist.htm).
>
>
> I guess I am in way over my head.
Re: Adding Content Assist to a WrappingLabel? [message #896099 is a reply to message #630686] Tue, 17 July 2012 05:23 Go to previous messageGo to next message
Eclipse UserFriend
This post is very old, but I had the same problem and gmf is still used.

I solved the problem by implementing the getCompletionProcessor in my TextAwareLabelEditPart and returning a class implementing IContentAssistProcessor and ISubjectControlContentAssistProcessor. The later is deprecated, but the other ways for getting a content proposal lead otehr difficulties, like no NullPointer because missing ITextViewer.
Re: Adding Content Assist to a WrappingLabel? [message #896127 is a reply to message #896099] Tue, 17 July 2012 07:05 Go to previous message
Eclipse UserFriend
Hi,

you should take a look to this bug: https://bugs.eclipse.org/bugs/show_bug.cgi?id=371888
See also XText integration from Yakindu (related to the mentioned bug): http://muelder.blogspot.fr/2011/04/xtext-celleditor-integration.html
it will allow you to use whatever kind of DirectEditor and so on provide contentassist that you want.

Regards,

Regards,
Previous Topic:After drag&drop, the node was deleted when i reopen the editor
Next Topic:GMF template aspects
Goto Forum:
  


Current Time: Wed Jul 23 06:10:09 EDT 2025

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

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

Back to the top