Is there a way to change the background color of wx.Choice

classic Classic list List threaded Threaded
8 messages Options
Reply | Threaded
Open this post in threaded view
|

Is there a way to change the background color of wx.Choice

john fabiani`

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.


All I trying to do is create a special disable color for one wx.Choice control.


Does anyone know the proper way to change the color of a wx.Choice?


Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

jie chen
you should refresh the window after change someting to the ui.

john fabiani` <[hidden email]> 于2018年12月7日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.


All I trying to do is create a special disable color for one wx.Choice control.


Does anyone know the proper way to change the color of a wx.Choice?


Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

john fabiani`

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf


On 12/06/2018 11:00 PM, jie chen wrote:
you should refresh the window after change someting to the ui.

john fabiani` <[hidden email]> 于2018年12月7日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.


All I trying to do is create a special disable color for one wx.Choice control.


Does anyone know the proper way to change the color of a wx.Choice?


Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

jie chen
 the below is my try.
image.png

image.png

john fabiani` <[hidden email]> 于2018年12月7日周五 下午9:29写道:

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf


On 12/06/2018 11:00 PM, jie chen wrote:
you should refresh the window after change someting to the ui.

john fabiani` <[hidden email]> 于2018年12月7日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.


All I trying to do is create a special disable color for one wx.Choice control.


Does anyone know the proper way to change the color of a wx.Choice?


Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

john fabiani`

Thank you for your effort but you made me realize I have mis-lead the group.  I wasn't making reference to the dropdown list (yours is the green and black) but what appears to be the blue on the pic.  Just using the enabled = False does not provide enough of a contrast (color difference) that the user can tell that the control is disabled.  My current thinking is to hide the control (refresh the screen) so that no mistakes are made as to which control is available to enter data.  But of course that will also mean the users will need extra training since they will not see the controls.

Johnf


On 12/09/2018 07:15 PM, jie chen wrote:
 the below is my try.
image.png

image.png

john fabiani` <[hidden email]> 于2018年12月7日周五 下午9:29写道:

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf


On 12/06/2018 11:00 PM, jie chen wrote:
you should refresh the window after change someting to the ui.

john fabiani` <[hidden email]> 于2018年12月7日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.


All I trying to do is create a special disable color for one wx.Choice control.


Does anyone know the proper way to change the color of a wx.Choice?


Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

RE: Is there a way to change the background color of wx.Choice

GadgetSteve

Johnf,

 

Just an idea - You could always replace the actual control with a disabled text control the same size, (possibly with some appropriate text in), whenever the actual control needs to be disabled. Not quite as easy as hiding it but you do get a visual marker for the users.

 

Steve

 

From: [hidden email] <[hidden email]> On Behalf Of john fabiani`
Sent: 10 December 2018 14:48
To: [hidden email]
Subject: Re: [wxPython-users] Is there a way to change the background color of wx.Choice

 

Thank you for your effort but you made me realize I have mis-lead the group.  I wasn't making reference to the dropdown list (yours is the green and black) but what appears to be the blue on the pic.  Just using the enabled = False does not provide enough of a contrast (color difference) that the user can tell that the control is disabled.  My current thinking is to hide the control (refresh the screen) so that no mistakes are made as to which control is available to enter data.  But of course that will also mean the users will need extra training since they will not see the controls.

Johnf

 

On 12/09/2018 07:15 PM, jie chen wrote:

 the below is my try.

image.png

 

image.png

 

john fabiani` <[hidden email]> 2018127日周五 下午9:29写道:

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf

 

On 12/06/2018 11:00 PM, jie chen wrote:

you should refresh the window after change someting to the ui.

 

john fabiani` <[hidden email]> 2018127日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.

 

All I trying to do is create a special disable color for one wx.Choice control.

 

Does anyone know the proper way to change the color of a wx.Choice?

 

Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

john fabiani`

I like that thought - I'll try it.

Thanks

Johnf


On 12/10/2018 09:45 PM, Steve Barnes wrote:

Johnf,

 

Just an idea - You could always replace the actual control with a disabled text control the same size, (possibly with some appropriate text in), whenever the actual control needs to be disabled. Not quite as easy as hiding it but you do get a visual marker for the users.

 

Steve

 

From: [hidden email] [hidden email] On Behalf Of john fabiani`
Sent: 10 December 2018 14:48
To: [hidden email]
Subject: Re: [wxPython-users] Is there a way to change the background color of wx.Choice

 

Thank you for your effort but you made me realize I have mis-lead the group.  I wasn't making reference to the dropdown list (yours is the green and black) but what appears to be the blue on the pic.  Just using the enabled = False does not provide enough of a contrast (color difference) that the user can tell that the control is disabled.  My current thinking is to hide the control (refresh the screen) so that no mistakes are made as to which control is available to enter data.  But of course that will also mean the users will need extra training since they will not see the controls.

Johnf

 

On 12/09/2018 07:15 PM, jie chen wrote:

 the below is my try.

image.png

 

image.png

 

john fabiani` <[hidden email]> 2018127日周五 下午9:29写道:

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf

 

On 12/06/2018 11:00 PM, jie chen wrote:

you should refresh the window after change someting to the ui.

 

john fabiani` <[hidden email]> 2018127日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.

 

All I trying to do is create a special disable color for one wx.Choice control.

 

Does anyone know the proper way to change the color of a wx.Choice?

 

Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: Is there a way to change the background color of wx.Choice

Chris Barker - NOAA Federal

 

Just an idea - You could always replace the actual control with a disabled text control the same size, (possibly with some appropriate text in), whenever the actual control needs to be disabled.

or draw something over it to make it stand out the way you want.

-CHB

 

Not quite as easy as hiding it but you do get a visual marker for the users.

 

Steve

 

From: [hidden email] [hidden email] On Behalf Of john fabiani`
Sent: 10 December 2018 14:48
To: [hidden email]
Subject: Re: [wxPython-users] Is there a way to change the background color of wx.Choice

 

Thank you for your effort but you made me realize I have mis-lead the group.  I wasn't making reference to the dropdown list (yours is the green and black) but what appears to be the blue on the pic.  Just using the enabled = False does not provide enough of a contrast (color difference) that the user can tell that the control is disabled.  My current thinking is to hide the control (refresh the screen) so that no mistakes are made as to which control is available to enter data.  But of course that will also mean the users will need extra training since they will not see the controls.

Johnf

 

On 12/09/2018 07:15 PM, jie chen wrote:

 the below is my try.

image.png

 

image.png

 

john fabiani` <[hidden email]> 2018127日周五 下午9:29写道:

I did try a refresh.

But let ask you - are you able to change the background color of a wx.Choice?

Johnf

 

On 12/06/2018 11:00 PM, jie chen wrote:

you should refresh the window after change someting to the ui.

 

john fabiani` <[hidden email]> 2018127日周五 上午2:17写道:

Hi,

I have tried several ways in a fruitless effort to change the background color of a wx.Choice control.

I have tried :

ClearBackground()

SetBackgroundColour()

even tried SetForegroundColour()

Nothing changes the background color.

 

All I trying to do is create a special disable color for one wx.Choice control.

 

Does anyone know the proper way to change the color of a wx.Choice?

 

Johnf

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

 

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.


--

Christopher Barker, Ph.D.
Oceanographer

Emergency Response Division
NOAA/NOS/OR&R            (206) 526-6959   voice
7600 Sand Point Way NE   (206) 526-6329   fax
Seattle, WA  98115       (206) 526-6317   main reception

[hidden email]

--
You received this message because you are subscribed to the Google Groups "wxPython-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
For more options, visit https://groups.google.com/d/optout.