Robin
July 23, 2007, 6:21pm
1
Tim doe wrote:
hi in my example i want to increament the value in the "number" col by 1 when i left click, it seems to happen after my 2nd click not the first?
Does it always take 2 clicks or is it only the first one that gets lost?
and how come even though i'm setting colLabels, i still only get the default label values in my grid?
Because you need to override the GetColLabelValue and return the label string for the requested column from there.
···
--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
the first click gets lost. I’ve fixed it with a hack for the moment by manually setting the cursor position using event, but if there’s a better way i’m all ears?
···
On 7/24/07, Robin Dunn robin@alldunn.com wrote:
Tim doe wrote:
hi in my example i want to increament the value in the “number” col by 1
when i left click, it seems to happen after my 2nd click not the first?
Does it always take 2 clicks or is it only the first one that gets lost?
and how come even though i’m setting colLabels, i still only get the
default label values in my grid?
Because you need to override the GetColLabelValue and return the label
string for the requested column from there.
–
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org
ahh ok well that’s how i’m doing it, good to see my solution was correct after all!
···
On 7/24/07, Chris Mellon < arkanes@gmail.com > wrote:
On 7/23/07, Tim doe < > myfirstmullet@gmail.com > wrote:
the first click gets lost. I’ve fixed it with a hack for the moment by
manually setting the cursor position using event, but if there’s a better
way i’m all ears?
It’s because you’re accessing the current cell by looking at the
cursor position, but the cursor position isn’t set until the base
class event handling happens. Retrieve the information from the event
object instead.
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-users-help@lists.wxwidgets.org