| Line Break in Marker Tooltip [message #307603] |
Sat, 26 August 2006 07:45  |
|
Originally posted by: zelzer.mathi.uni-heidelberg.de
Hi,
I am trying to do some simple formatting with line breaks "\n" and
spaces for some text I want to display in my markers tooltip. I tried to
add a "\n" in the message for the marker but when the message is
displayed in the tooltip, the "\n" just disappeared, not leading to a
line break.
Is this kind of formating possible? Or even better, is it possible to
supply simple HTML for the markers tooltip?
Thanks in advance,
Sascha
|
|
|
|
|
| Re: Line Break in Marker Tooltip [message #1005458 is a reply to message #554639] |
Fri, 25 January 2013 09:21  |
David Whiteman Messages: 5 Registered: July 2009 Location: Research Triangle Park, N... |
Junior Member |
|
|
Here's an approach that worked for me:
blog.pdark.de/2009/12/26/swt-tree-and-tooltips/
I was able to use the wrap() method described in that post to format a string that when passed to setToolTipText() on a Control would do an intelligent word wrap. It also can handle \n characters. You have to include the commons-lang jar in your classpath in order to use this.
---
David Whiteman
Cisco Systems
|
|
|
Powered by
FUDForum. Page generated in 0.02662 seconds