From: Bo G. <bo...@sy...> - 2005-06-01 15:47:34
|
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> </head> <body bgcolor="#ffffff" text="#000000"> <br> This is true. You do have to code straight wxPython, which means using wx events and handlers. For the grid, I fired up BoaConstructor, generated the code for the grid I wanted, and copied the relevant fragments into my pythoncard app. Then I modified a custom gridCellEditor from the Python Cookbook, and added that too. Presto, a grid.<br> It's not actually a secret that you can mix wx widgets with pythoncard components, I've seen it explicitly mentioned on this list before (by KA I think).<br> <br> <br> <a class="moz-txt-link-abbreviated" href="mailto:bra...@om...">bra...@om...</a> wrote: <blockquote cite="mid...@om..." type="cite"><br> <font face="sans-serif" size="2">I'm glad to hear it's possible to add non-PythonCard wx widgets into PythonCard.</font> <br> <font face="sans-serif" size="2">I take it that none of the normal PythonCard events will be generated by these</font> <br> <font face="sans-serif" size="2">kinds of add-ins? As in, on_mouseClick or on_closeField or on_select are all</font> <br> <font face="sans-serif" size="2">events that only come from PythonCard widgets, right?<br> </font> <br> <br> <font size="2"><tt>Bo Green wrote on 06/01/2005 07:02:42 AM:<br> <br> > <br> > Thanks Brad. First, an aside, the grid is working fine for all but <br> > the problem of creating and loading inside the same event handler. <br> > Your comments were helpful, because they made me rethink the methods<br> > and modules. I remembered a list member talking about a childWindow <br> > problem with event handling (in their case it was trying to Raise() <br> > the window after creating it in the same event handler). Same <br> > problem, same solution. The solution was to move the Raise() into <br> > the on_initialize method. I borrowed that logic, and moved my <br> > set_grid_data() method call into the on_initialize method. I also <br> > moved the get_grid_data() and set_grid_data() methods into <br> > FileSpecsWin as a better style choice. Works like a charm. <br> > </tt></font> </blockquote> <br> </body> </html> |