wxListCtrl - Calling Editor Directly

Annius Groenink wrote:

"C:\Python23\Lib\site-packages\wx-2.5.3-msw-ansi\wx\lib\mixins\listctrl.p
y", line 491, in OpenEditor
  x0 = self.col_locs[col]
AttributeError: 'EDITLISTCTRL' object has no attribute 'col_locs'

Is there another way to achieve the same result without having to
rewrite the class??

col_locs is initialized in OnLeftDown, so you could either duplicate
that part of the code, refactor it out into another method, or just send
a left down event.

I've seen this error too, triggered by something completely different.
Shouldn't 'col_locs' be initialized to some neutral default value in the
mixin constructor?

Yes, or at least factored out into its own method so it can be called from wherever it is needed. If anybody is interested in doing it send me a patch.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!