Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » How to change selection color
How to change selection color [message #448987] Mon, 17 January 2005 11:49 Go to next message
Evgeni is currently offline EvgeniFriend
Messages: 1
Registered: July 2009
Junior Member
Hi all.

When the table is not focused, the selected row is displayed with a light
grey background. I need to change this color. Is there any simple way how
to do it?

I use Win2K, but I need a tip for something, what will work on any other
eclipse - compatible platform too.

Thanks.

Evgeni.
Re: How to change selection color [message #449018 is a reply to message #448987] Mon, 17 January 2005 19:58 Go to previous messageGo to next message
Kelly Muñiz is currently offline Kelly MuñizFriend
Messages: 7
Registered: July 2009
Junior Member
Hi,

I also would like to change the selection color on tables and trees but
have not figured out a way. I hope someone can help you with your
question.

I tried adding a selection listener and changing the background color on
the selected item but this doesn't work too well (at least for the tree
widget).

Kelly

Evgeni wrote:

> Hi all.

> When the table is not focused, the selected row is displayed with a light
> grey background. I need to change this color. Is there any simple way how
> to do it?

> I use Win2K, but I need a tip for something, what will work on any other
> eclipse - compatible platform too.

> Thanks.

> Evgeni.
Re: How to change selection color [message #449023 is a reply to message #449018] Mon, 17 January 2005 22:32 Go to previous messageGo to next message
Veronika Irvine is currently offline Veronika IrvineFriend
Messages: 1272
Registered: July 2009
Senior Member
You can not change the selection colour of the Tree or Table. It is
controlled by the theme used by the operating system. In general, it is not
a good idea to change the colours that users associate with a specific
meaning. For example, selection has the same colour in trees, tables, text
widgets, lists. The selection colour is an indicator of a state. If you
change this colour for your one application it will be confusing to the
user.


"Kelly "Mu
Re: How to change selection color [message #449081 is a reply to message #449023] Tue, 18 January 2005 02:20 Go to previous messageGo to next message
Kelly Muñiz is currently offline Kelly MuñizFriend
Messages: 7
Registered: July 2009
Junior Member
Thank you Veronika, I was afraid of that. This presents a problem for
companies that desire to brand their apps by using their own theme (which
may not match at all the OS theme).

However, I understand the point you make. Thanks for responding so
quickly.

Veronika Irvine wrote:

> You can not change the selection colour of the Tree or Table. It is
> controlled by the theme used by the operating system. In general, it is not
> a good idea to change the colours that users associate with a specific
> meaning. For example, selection has the same colour in trees, tables, text
> widgets, lists. The selection colour is an indicator of a state. If you
> change this colour for your one application it will be confusing to the
> user.


> "Kelly "Muñiz"" <kmuniz@cisco.com> wrote in message
> news:csh5cq$5qh$1@www.eclipse.org...
>> Hi,
>>
>> I also would like to change the selection color on tables and trees but
>> have not figured out a way. I hope someone can help you with your
>> question.
>>
>> I tried adding a selection listener and changing the background color on
>> the selected item but this doesn't work too well (at least for the tree
>> widget).
>>
>> Kelly
>>
>> Evgeni wrote:
>>
>>> Hi all.
>>
>>> When the table is not focused, the selected row is displayed with a light
>>> grey background. I need to change this color. Is there any simple way how
>>> to do it?
>>
>>> I use Win2K, but I need a tip for something, what will work on any other
>>> eclipse - compatible platform too.
>>
>>> Thanks.
>>
>>> Evgeni.
>>
Re: How to change selection color [message #449156 is a reply to message #449081] Tue, 18 January 2005 22:06 Go to previous messageGo to next message
Bill Ewing is currently offline Bill EwingFriend
Messages: 49
Registered: July 2009
Member
Kelly Muñiz wrote:


> Thank you Veronika, I was afraid of that. This presents a problem for
> companies that desire to brand their apps by using their own theme (which
> may not match at all the OS theme).

> However, I understand the point you make. Thanks for responding so
> quickly.

> Veronika Irvine wrote:

>> You can not change the selection colour of the Tree or Table. It is
>> controlled by the theme used by the operating system. In general, it is
not
>> a good idea to change the colours that users associate with a specific
>> meaning. For example, selection has the same colour in trees, tables, text
>> widgets, lists. The selection colour is an indicator of a state. If you
>> change this colour for your one application it will be confusing to the
>> user.


>> "Kelly "Muñiz"" <kmuniz@cisco.com> wrote in message
>> news:csh5cq$5qh$1@www.eclipse.org...
>>> Hi,
>>>
>>> I also would like to change the selection color on tables and trees but
>>> have not figured out a way. I hope someone can help you with your
>>> question.
>>>
>>> I tried adding a selection listener and changing the background color on
>>> the selected item but this doesn't work too well (at least for the tree
>>> widget).
>>>
>>> Kelly
>>>
>>> Evgeni wrote:
>>>
>>>> Hi all.
>>>
>>>> When the table is not focused, the selected row is displayed with a light
>>>> grey background. I need to change this color. Is there any simple way how
>>>> to do it?
>>>
>>>> I use Win2K, but I need a tip for something, what will work on any other
>>>> eclipse - compatible platform too.
>>>
>>>> Thanks.
>>>
>>>> Evgeni.
>>>
Re: How to change selection color [message #449157 is a reply to message #449081] Tue, 18 January 2005 22:10 Go to previous messageGo to next message
Bill Ewing is currently offline Bill EwingFriend
Messages: 49
Registered: July 2009
Member
We have a similar problem. We found that you can change the background
color on any row programmatically- see this website:

http://wiki.schubart.net/wiki/wiki.phtml?title=How_to_Color_ Rows_in_a_TableViewer&printable=yes



Kelly Muñiz wrote:


> Thank you Veronika, I was afraid of that. This presents a problem for
> companies that desire to brand their apps by using their own theme (which
> may not match at all the OS theme).

> However, I understand the point you make. Thanks for responding so
> quickly.

> Veronika Irvine wrote:

>> You can not change the selection colour of the Tree or Table. It is
>> controlled by the theme used by the operating system. In general, it is
not
>> a good idea to change the colours that users associate with a specific
>> meaning. For example, selection has the same colour in trees, tables, text
>> widgets, lists. The selection colour is an indicator of a state. If you
>> change this colour for your one application it will be confusing to the
>> user.


>> "Kelly "Muñiz"" <kmuniz@cisco.com> wrote in message
>> news:csh5cq$5qh$1@www.eclipse.org...
>>> Hi,
>>>
>>> I also would like to change the selection color on tables and trees but
>>> have not figured out a way. I hope someone can help you with your
>>> question.
>>>
>>> I tried adding a selection listener and changing the background color on
>>> the selected item but this doesn't work too well (at least for the tree
>>> widget).
>>>
>>> Kelly
>>>
>>> Evgeni wrote:
>>>
>>>> Hi all.
>>>
>>>> When the table is not focused, the selected row is displayed with a light
>>>> grey background. I need to change this color. Is there any simple way how
>>>> to do it?
>>>
>>>> I use Win2K, but I need a tip for something, what will work on any other
>>>> eclipse - compatible platform too.
>>>
>>>> Thanks.
>>>
>>>> Evgeni.
>>>
Re: How to change selection color [message #449158 is a reply to message #449081] Tue, 18 January 2005 22:10 Go to previous message
Bill Ewing is currently offline Bill EwingFriend
Messages: 49
Registered: July 2009
Member
We have a similar problem. We found that you can change the background
color on any row programmatically- see this website:

http://wiki.schubart.net/wiki/wiki.phtml?title=How_to_Color_ Rows_in_a_TableViewer&printable=yes



Kelly Muñiz wrote:


> Thank you Veronika, I was afraid of that. This presents a problem for
> companies that desire to brand their apps by using their own theme (which
> may not match at all the OS theme).

> However, I understand the point you make. Thanks for responding so
> quickly.

> Veronika Irvine wrote:

>> You can not change the selection colour of the Tree or Table. It is
>> controlled by the theme used by the operating system. In general, it is
not
>> a good idea to change the colours that users associate with a specific
>> meaning. For example, selection has the same colour in trees, tables, text
>> widgets, lists. The selection colour is an indicator of a state. If you
>> change this colour for your one application it will be confusing to the
>> user.


>> "Kelly "Muñiz"" <kmuniz@cisco.com> wrote in message
>> news:csh5cq$5qh$1@www.eclipse.org...
>>> Hi,
>>>
>>> I also would like to change the selection color on tables and trees but
>>> have not figured out a way. I hope someone can help you with your
>>> question.
>>>
>>> I tried adding a selection listener and changing the background color on
>>> the selected item but this doesn't work too well (at least for the tree
>>> widget).
>>>
>>> Kelly
>>>
>>> Evgeni wrote:
>>>
>>>> Hi all.
>>>
>>>> When the table is not focused, the selected row is displayed with a light
>>>> grey background. I need to change this color. Is there any simple way how
>>>> to do it?
>>>
>>>> I use Win2K, but I need a tip for something, what will work on any other
>>>> eclipse - compatible platform too.
>>>
>>>> Thanks.
>>>
>>>> Evgeni.
>>>
Previous Topic:set background color in odd even row in table
Next Topic:No background on text, label...
Goto Forum:
  


Current Time: Sat Apr 20 05:52:40 GMT 2024

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

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

Back to the top