Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Table column content as hyperlink
Table column content as hyperlink [message #759584] Tue, 29 November 2011 09:39 Go to next message
Setya Nugdjaja is currently offline Setya NugdjajaFriend
Messages: 567
Registered: July 2009
Senior Member
Hi all,

I need to fill table column content with hyperlink so that when user clicks it a dialog will pop up. How to do this ?

Any help would be greatly appreciated.

Thanks & Regards,

Setya
Re: Table column content as hyperlink [message #759638 is a reply to message #759584] Tue, 29 November 2011 12:35 Go to previous messageGo to next message
Ralf Sternberg is currently offline Ralf SternbergFriend
Messages: 1313
Registered: July 2009
Senior Member

Hi,

markup support for Table [1] is a planned feature for RAP 1.5. This will
include HTML hyperlinks, but not those that you could add a listener to.

As a workaround, you could add a mouse listener to the table and
determine the cell that has been clicked. If that does not help, feel
free to open an enhancement request for this feature.

Best Regards, Ralf


[1] 346768: [Table] Support markup for rich text in table items
https://bugs.eclipse.org/bugs/show_bug.cgi?id=346768

--
Ralf Sternberg

Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/

Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
Re: Table column content as hyperlink [message #759907 is a reply to message #759638] Wed, 30 November 2011 14:32 Go to previous messageGo to next message
Francis Delsinnes is currently offline Francis DelsinnesFriend
Messages: 49
Registered: November 2011
Member
I'm using an editing support (MyClass extends EditingSupport) for it.
Into the "getCellEditor" method, I call an external browser with: ExternalBrowser.open(...,...,...);
Re: Table column content as hyperlink [message #759908 is a reply to message #759638] Wed, 30 November 2011 14:32 Go to previous messageGo to next message
Francis Delsinnes is currently offline Francis DelsinnesFriend
Messages: 49
Registered: November 2011
Member
I'm using an editing support (MyClass extends EditingSupport) for it.
Into the "getCellEditor" method, I call an external browser with: ExternalBrowser.open(...,...,...);
Re: Table column content as hyperlink [message #916211 is a reply to message #759638] Tue, 18 September 2012 18:25 Go to previous messageGo to next message
Ronald So is currently offline Ronald SoFriend
Messages: 198
Registered: April 2011
Senior Member
Ralf,

I have a table cell that I need a link that will drill down to the details of the object. I have no problem replacing the text with a link with table markup, but I cannot use a href because the details page is not a dialog window but stays inside the application. I tried to use the onClick="return false;" to suppress the href link but RAP does not like it (onClick is not allowed).

Also, with RWT_ENABLED to true, the padding of the TableCell goes away. It's the same behavior as in the tree cell as well.

With all the improvement done in 1.5, what is the easiest way to accomplish what I need to do? I mean, putting an HREF link in a table is not uncommon at all. On the other hand, we have put a listener in a cell so we can get the behavior we want. But there is no way I can make the text looks like a link so I have no visual cue for the user that something is clickable.

Thanks,
Ronald
Re: Table column content as hyperlink [message #916271 is a reply to message #916211] Tue, 18 September 2012 20:42 Go to previous messageGo to next message
Ronald So is currently offline Ronald SoFriend
Messages: 198
Registered: April 2011
Senior Member
I got around the issue by setting the link to:

<a href="#">Text</a>


This seems to work for me with one side effect. All the links in the table turns purple once I click on them once.

Still looking for alternatives ...
Re: Table column content as hyperlink [message #916274 is a reply to message #916271] Tue, 18 September 2012 20:46 Go to previous messageGo to next message
Chris Fairhall is currently offline Chris FairhallFriend
Messages: 221
Registered: February 2011
Senior Member
You can stop the links turning purple with CSS. From memory it is a:visited that will solve your problem.
Re: Table column content as hyperlink [message #916411 is a reply to message #916274] Wed, 19 September 2012 01:42 Go to previous messageGo to next message
Ronald So is currently offline Ronald SoFriend
Messages: 198
Registered: April 2011
Senior Member
Yes I did try that in my CSS file but it does not work. I put that in the same CSS file that I register with the branding extension.
Re: Table column content as hyperlink [message #916445 is a reply to message #916411] Wed, 19 September 2012 02:50 Go to previous messageGo to next message
Chris Fairhall is currently offline Chris FairhallFriend
Messages: 221
Registered: February 2011
Senior Member
It will need to go in a separate CSS file referenced by the rap start up page. The RAP theme CSS files are parsed by the RAP runtime, not the browser.
Re: Table column content as hyperlink [message #918408 is a reply to message #916445] Fri, 21 September 2012 01:57 Go to previous message
Ronald So is currently offline Ronald SoFriend
Messages: 198
Registered: April 2011
Senior Member
Thanks Chris. Found yet another hack to put "#" follow by 10 characters generated by "UUID.randomUUID.toString()". Now everyone of the links are unique and it is acceptable now.
Previous Topic:connection problem
Next Topic:Table column content as hyperlink
Goto Forum:
  


Current Time: Fri Apr 19 23:09:05 GMT 2024

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

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

Back to the top