| Change SWT List selection color [message #731155] |
Fri, 30 September 2011 03:01  |
Ovidio Mallo Messages: 35 Registered: July 2009 |
Member |
|
|
Hi all,
I wanted to ask whether it's possible to programmatically change the
selection color of an SWT List? Neither the SWT.EraseItem events nor the
JFace IColorProvider interfaces seem to work for Lists. I've seen a very
old post from 2008 stating that changing the selection color of Lists is
indeed not possible but I was hoping that this might have changed in the
meantime :).
Thanks in advance for any help!
Ovidio
|
|
|
| Re: Change SWT List selection color [message #731889 is a reply to message #731155] |
Mon, 03 October 2011 08:07  |
 |
Lakshmi Shanmugam Messages: 271 Registered: July 2009 Location: India |
Senior Member |
|
|
Hi,
This is not possible for List, but can be done for Tree and Table.
SWT.EraseItem event doesn't work for List, works only for Table & Tree.
If you like, you can replace the List with a Table and have a similar UI. The selection color for the Table can be modified using Custom Drawing (see SWT.EraseItem listener in this example snippet 234)
Lakshmi P Shanmugam
|
|
|
Powered by
FUDForum. Page generated in 0.01445 seconds