listcontrol selected item is not correctly highlighted when catching focus event

James Stone wrote:

Hi there.

I am sure this is really obvious, but I am trying to catch the
EVT_SET_FOCUS events for my listctrl widgets (in wxpython 2.6, Linux). It
works OK, but the colour of the selected item in the listcontrol is not
correct (it is grey: looks like it does not have focus, instead of blue).
If I do not catch the set focus event, the colour is correct. Is there
something I should call after to get the item to show up correctly
highlighted?
  
Probably event.Skip() (or whatever your event object is named).

- Mike Rooney

Thanks! That's the one :slight_smile:

James

···

On Wed, 25 Apr 2007 14:33:14 -0400, Mike Rooney wrote:

James Stone wrote:

Hi there.

I am sure this is really obvious, but I am trying to catch the
EVT_SET_FOCUS events for my listctrl widgets (in wxpython 2.6, Linux).
It works OK, but the colour of the selected item in the listcontrol is
not correct (it is grey: looks like it does not have focus, instead of
blue). If I do not catch the set focus event, the colour is correct. Is
there something I should call after to get the item to show up correctly
highlighted?
  
Probably event.Skip() (or whatever your event object is named).