How to duplicate the F2 behavior of a wxGrid

Calling grid_ctrl.ShowCellEditControl() starts the editing but the text is not selected.

If you write a custom cell editor, you could select the text within the cell editor's BeginEdit() method, using

wxTextCtrl::SetSelection() or wxChoice::SetSelection(), whatever fits your needs

.

You may find a sample of custom cell editor at http://wiki.wxpython.org/index.cgi/wxGridCellChoiceEditor

HTH,

Cristina.

I am working on a small program that looks up a number gets a name that goes with it and the comments are written to a text file.
What I am having trouble with is the events. I cant find what events I can use with the controls I want to use.
So far I have a :
Text Control
Static Text
Menu Control
Status Bar

I have been looking through the wxpython demo but trying to find events by trial and error is making me crazy.
Where can I find what events can be used with each controls ?

Fred

They are listed with in the class reference. Go to the alphabetical
class reference, then choose the control you're interested in. Here are
the ones listed for the text control:

EVT_TEXT(id, func) Respond to a wxEVT_COMMAND_TEXT_UPDATED event,
generated when the text changes. Notice that this event will always be
sent when the text controls contents changes - whether this is due to
user input or comes from the program itself (for example, if SetValue()
is called)
EVT_TEXT_ENTER(id, func) Respond to a wxEVT_COMMAND_TEXT_ENTER
event, generated when enter is pressed in a single-line text control.
EVT_TEXT_URL(id, func) A mouse event occured over an URL in the text
control (Win32 only)
EVT_TEXT_MAXLEN(id, func) User tried to enter more text into the
control than the limit set by SetMaxLength.

ยทยทยท

On Fri, 28 Nov 2003 23:03:07 -0500 pxlpluker <pxlpluker@cfl.rr.com> wrote:

I am working on a small program that looks up a number gets a name
that goes with it and the comments are written to a text file.
What I am having trouble with is the events. I cant find what events I

can use with the controls I want to use.
So far I have a :
Text Control
Static Text
Menu Control
Status Bar

I have been looking through the wxpython demo but trying to find
events by trial and error is making me crazy.
Where can I find what events can be used with each controls ?

Fred