Python GUIs: Abandoning TkInter and welcoming wxPython?

Vlachidis Costas vlachid at otenet.gr
Sat Jun 26 01:56:58 EDT 1999


Hi
Yes , me too I thinc that wxwindows are very good in programming very simple
GUIs and no some complex ones.,but they are not made to handle complex canvas
aporations in a easy way.
 This hapens because wxWindows abd wxPython are developed from few people like
Julian Smart, and some others, and then thinks stoped there.In contrast
,Tcl/Tk community is  yet developing their software.In the other hand
wxWindows is compact, fast and very effective for simple applications.
Costas


Jeffrey Chang wrote:

> On Fri, 25 Jun 1999, Mikael Lyngvig wrote:
> > I'd like some discussion on whether or not it is a good idea to
> > abandon TkInter, before it gets too widely used, and instead adopt
> > wxPython as the primary GUI framework for Python.
>
> Abandoning Tkinter seems a little bit extreme, since there are some
> applications for which its event model is well-suited.
>
> A few weeks ago I needed to build a viewer that displays binary trees
> whose branches have variable lengths (actually, phylogenetic trees for
> biological data).  Since the trees are large, I need to be able to slide
> it around the window.  In addition, I needed each node to be clickable so
> that the user can query for more data.
>
> Tkinter is very good for that type of thing.  All I needed to do was
> create a Canvas and then for each node, create an Oval with a callback to
> a function that handles node clicks.  Tk keeps track of the coordinates of
> each Item so that I don't have to.  Also, whenever I wanted to move the
> tree, all I had to do was:
> for widget in self._canvas.find_all():
>     self._canvas.move(widget, xoff, yoff)
>
> Of course, Tk incurrs an overhead by making everything you draw on the
> canvas its own object, but for this case, it made thigns a lot easier.
>
> Although I haven't used wxWindows before, but the documentation suggests
> that it would be a lot more difficult for this kind of application.  In
> wxWindows, I would need to draw each of my nodes into a window using a
> device context.  Then, I'd have to write a function that would handle
> mouse clicks in the window.  That function would need to get the
> coordinates and then figure out whether it intersects with any of my
> nodes, which Tk would've handled for me.  In addition, whenever I wanted
> to move the tree, I'd have to erase the window and redraw each node.  If I
> wanted that optimized, I'd need to write routines that would only redraw
> the uncovered parts of the tree, which means figuring out which nodes are
> newly revealed.
>
> From what other people have said about wxPython, it seems like it may be
> appropriate for other types of applications.  However, I'd hate to see
> Tkinter dumped because it's not appropriate for everything!
>
> Jeff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vlachid.vcf
Type: text/x-vcard
Size: 366 bytes
Desc: Card for Vlachidis Costas
URL: <http://mail.python.org/pipermail/python-list/attachments/19990626/c3ccf06b/attachment.vcf>


More information about the Python-list mailing list