Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » How can I create a texteditor with hyperlink support?
How can I create a texteditor with hyperlink support? [message #696115] Wed, 13 July 2011 09:54 Go to next message
jakob is currently offline jakobFriend
Messages: 5
Registered: July 2011
Junior Member
Hi,

I want to have a control similar to the org.eclipse.swt.widgets.Text, where I can edit a string of text. This text should contain hyperlinks, so when the mouse hovers over specific words, the cursor changes into the "hand"-symbol, and when clicked, some event happens. Also, the hyperlinks should be styled in some way to show that they are hyperlinks, for example by underlining them or changing the color.

Is there an existing control which does something like this, or will I have to build my own?

In case I have to build my own, do you have any good suggestions on how to go about it?
(no subject) [message #696134 is a reply to message #696115] Wed, 13 July 2011 09:59 Go to previous message
Dani Megert is currently offline Dani MegertFriend
Messages: 3801
Registered: July 2009
Senior Member
On 13.07.2011 11:54, forums-noreply@eclipse.org wrote:
> Hi,
>
> I want to have a control similar to the org.eclipse.swt.widgets.Text,
> where I can edit a string of text. This text should contain
> hyperlinks, so when the mouse hovers over specific words, the cursor
> changes into the "hand"-symbol, and when clicked, some event happens.
> Also, the hyperlinks should be styled in some way to show that they
> are hyperlinks, for example by underlining them or changing the color.
>
> Is there an existing control which does something like this, or will I
> have to build my own?
Take a look at org.eclipse.swt.custom.StyledText and
org.eclipse.swt.SWT.UNDERLINE_LINK.

Dani
>
> In case I have to build my own, do you have any good suggestions on
> how to go about it?
Previous Topic: internationalize an existing preference page
Next Topic:View persistency in workbench
Goto Forum:
  


Current Time: Sun Nov 23 16:18:41 GMT 2014

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

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