I'm trying to have all text in a certain wxTextCtrl become selected when the user enters the control with the mouse. I've tried using an EVT_SET_FOCUS, and the handler looks like
I'm trying to have all text in a certain wxTextCtrl become
selected when the user enters the control with the mouse. I've
tried using an EVT_SET_FOCUS, and the handler looks like
> I'm trying to have all text in a certain wxTextCtrl become
> selected when the user enters the control with the mouse. I've
> tried using an EVT_SET_FOCUS, and the handler looks like
The reason for using wx.CallAfter here is that the text control does it's own selection management in its default EVT_SET_FOCUS handler. Using wx.CallAfter allows you to do your selection after the control has done its own.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!