Tkinter vs wxPython

Discussion in 'Python' started by Esmail Bonakdarian, Dec 28, 2004.

  1. Greetings all.

    I will have about 2 weeks to pursue some Python related activities and
    would like to learn more about the graphical end of things. In that
    vein I would like some opinions regarding Tkinter and wxPython.
    (The previously recommended PyGame is appropriate for me for now, but
    I am looking ahead)

    I am especially interested in terms of learning curve, documentation,
    portability across platforms Linux/Windows and anything else you care
    to add. As I know only what I have read on this forum & surfing the
    web I would really appreciate the input of those who have used both,
    or decided to use one over the other.

    Thanks a bunch,

    Esmail

    ps: this is basically the same query as posted December 10 “Re: GUIs:
    wxPython vs. Tkinter (and others)”
    Esmail Bonakdarian, Dec 28, 2004
    #1
    1. Advertising

  2. My post wasn't complete, sorry for the additional post:

    ps: this is basically the same query as posted December 10 “Re: GUIs:
    wxPython vs. Tkinter (and others)” by Erik Johnson which really seemed
    to end up comparing PyQt (?)
    Esmail Bonakdarian, Dec 28, 2004
    #2
    1. Advertising

  3. Esmail Bonakdarian wrote:
    > My post wasn't complete, sorry for the additional post:
    >
    > ps: this is basically the same query as posted December 10 “Re: GUIs:
    > wxPython vs. Tkinter (and others)” by Erik Johnson which really seemed
    > to end up comparing PyQt (?)

    I recommend PyQt because of the easy to use designer progam that speeds
    up GUI development. Designer allows you to design your UI visually and
    establish handlers for events. It outputs a .ui file.

    You then call 'pyuic myui.ui > myui.py' to turn your ui into a python class.

    The Qt framework is very straightforward to use as well and
    www.trolltech.com maintains good documentation on the framework.

    Check it out: http://doc.trolltech.com/3.3/index.html

    PS: You can also use your .ui files to output C++ classes with 'uic'
    instead of 'pyuic'. I also think there is a 'puic' to create Perl code.
    So, that single ui description can be used in multiple languages.

    My two cents,
    Michael
    Michael McGarry, Dec 28, 2004
    #3
  4. Esmail Bonakdarian

    Guest

    Esmail Bonakdarian wrote:
    > Greetings all.
    >
    > I will have about 2 weeks to pursue some Python related activities

    and
    > would like to learn more about the graphical end of things. In that
    > vein I would like some opinions regarding Tkinter and wxPython.
    > (The previously recommended PyGame is appropriate for me for now, but
    > I am looking ahead)
    >
    > I am especially interested in terms of learning curve, documentation,
    > portability across platforms Linux/Windows and anything else you care
    > to add. As I know only what I have read on this forum & surfing the
    > web I would really appreciate the input of those who have used both,
    > or decided to use one over the other.


    Well I would recomend Tkinter because it's the easiest to use. I
    recomend using this document.
    http://infohost.nmt.edu/tcc/help/lang/python/tkinter.html I used it
    and just worked my way through it. I found it very useful.
    , Dec 28, 2004
    #4
  5. Esmail Bonakdarian

    Steve Holden Guest

    Michael McGarry wrote:

    > Esmail Bonakdarian wrote:
    >
    >> My post wasn't complete, sorry for the additional post:
    >>
    >> ps: this is basically the same query as posted December 10 “Re: GUIs:
    >> wxPython vs. Tkinter (and others)” by Erik Johnson which really seemed
    >> to end up comparing PyQt (?)

    >
    > I recommend PyQt because of the easy to use designer progam that speeds
    > up GUI development. Designer allows you to design your UI visually and
    > establish handlers for events. It outputs a .ui file.
    >
    > You then call 'pyuic myui.ui > myui.py' to turn your ui into a python
    > class.
    >
    > The Qt framework is very straightforward to use as well and
    > www.trolltech.com maintains good documentation on the framework.
    >
    > Check it out: http://doc.trolltech.com/3.3/index.html
    >
    > PS: You can also use your .ui files to output C++ classes with 'uic'
    > instead of 'pyuic'. I also think there is a 'puic' to create Perl code.
    > So, that single ui description can be used in multiple languages.
    >
    > My two cents,
    > Michael


    Michael:

    Just a bit less-than-helpful when the original post specifically asked
    for comparisons *between Tkinter and wxPython* in the context of having
    two weeks to work on *Python* ;-)

    regards
    Steve
    --
    Steve Holden http://www.holdenweb.com/
    Python Web Programming http://pydish.holdenweb.com/
    Holden Web LLC +1 703 861 4237 +1 800 494 3119
    Steve Holden, Dec 28, 2004
    #5
  6. Esmail Bonakdarian

    Peter Hansen Guest

    Esmail Bonakdarian wrote:
    > I will have about 2 weeks to pursue some Python related activities and
    > would like to learn more about the graphical end of things. In that
    > vein I would like some opinions regarding Tkinter and wxPython.


    This is an area where personal preference reigns strong.
    You really ought to try both out. Following through a
    tutorial or examining some example code and trying to
    make a few changes on your own will give you a far better
    perspective than anything you learn from others here.

    For example, I see "flaxeater" has just said that Tkinter
    is "the easiest to use". I, however, found it anything
    but, and had no end of trouble figuring out how to make it
    do the things I wanted. In spite of its "better" documentation,
    too, I might add.

    When I switched to wxPython, I faced some of the typical
    wxPython issues (the docs simply aren't as good), and yet
    I was able to make progress faster and get closer to my
    goals. The demo program, for example, is worth its weight
    in gold. (Well, bad analogy in the computer world. :-( )

    Try them both out for an hour or two, and go with whichever
    one "feels right". You very likely won't be making a mistake.

    -Peter
    Peter Hansen, Dec 28, 2004
    #6
  7. Hi

    I have found ALL of the posts useful, thank you so much.

    Please keep them coming! I am learning a lot.

    I will probably play a bit with Tkinter and wxPython and see how
    each feels, just as Peter Hansen suggested). PyQt also looks
    interesting, so I will take a look at that at some point down the
    line aswell.

    Thanks again, this is a great resource.

    Esmail
    Esmail Bonakdarian, Dec 28, 2004
    #7
  8. Esmail Bonakdarian

    F. GEIGER Guest

    "Esmail Bonakdarian" <> schrieb im Newsbeitrag
    news:...
    > Hi
    >
    > I have found ALL of the posts useful, thank you so much.
    >
    > Please keep them coming! I am learning a lot.
    >
    > I will probably play a bit with Tkinter and wxPython and see how
    > each feels, just as Peter Hansen suggested). PyQt also looks


    It couldn't have been said better than Peter has.

    I might add this: Try both *and learn both*. Despite the fact, that I do
    most GUI stuff with wxPython, I sometimes face situations, where I need to
    be able to do some Tkinter stuff (mostly by use of PMW). This could happen
    to you too, more likely than you might think now.

    As for the wxPython path: I recently prototyped a GUI-app for Windows with
    wxPython and then (alas) had to port it to C++. I simply could download the
    wxWidgets (which wxPython is built upon) and kind of simply translate the
    Python stuff into C++! It really helped me *a lot* having a working
    wx/Python app, and saved me a lot of time, of course (but no as much as I
    had saved, if I hadn't to port it to C++).

    And while I am at it: It was a big benefit for me to *not* use a GUI builder
    (which could be the next thing you might ask for), when I started Python
    programming. When I started Python programming with 1.5.2 there wasn't a
    descent GUI builder for wx (or at least I couldn't find one). And today,
    where there are a few options (wxDesigner, Boa, to be concrete), I'm really
    glad never having used one: Everything I do is under *my* full control, and
    I guess this is the only way to get the most out of wx/Python. And for sure,
    it's the only way knowing what you do.

    As Peter said, the wxPython demo is a bonanza - use it.

    Summary: Taking all my experience into account, I'd advise you to learn
    Tkinter, to learn wxPython and to not use a GUI builder (which could be not
    what a newbie likes to hear).

    HTH
    Franz GEIGER

    P.S.:
    Concerning PyQt: Yes, so far I only can speak for Tkinter and wxPython. But
    as soon as I will be on Linux (hopefully next year), I'll try PyQt. So if
    you would have asked me next year, I had said (phew, is that correct
    English?): Learn Tkinter and wxPython and/or PyQt and no GUI builder :)


    > interesting, so I will take a look at that at some point down the
    > line aswell.
    >
    > Thanks again, this is a great resource.
    >
    > Esmail
    F. GEIGER, Dec 28, 2004
    #8
  9. Definitely look at PyQt. It was the GUI framework I chose when going
    through the same process 3 weeks ago. I have to disagree with F.Geiger
    (sorry, F.Geiger), I think a GUI builder is a necessity. It saves you a
    lot of time. The alternative is to keep changing your code until your
    GUI looks as you want. With a GUI builder you "draw" what you want and
    have the tool generate the Python class for the GUI. It also sets up
    event handlers for you too.

    Visual elements are best designed visually!!!
    Michael McGarry, Dec 29, 2004
    #9
  10. Esmail Bonakdarian

    M.E.Farmer Guest

    I have to agree with F. Gieger learning to code a framework by hand
    only helps you.
    Sure wxGlade/Boa/etc can help speed design and layout up, but what
    happens when you want to do non standard things or just get stuck
    because some thing just isn't working.
    Check recent threads .....All the newbies needing help are using
    wxGlade or Boa and it helps them get neck deep into trouble before they
    even realize what they are doing wrong.
    Because they have not worked directly with the framework they don't
    understand the framework . But YMMV
    M.E.Farmer
    M.E.Farmer, Dec 29, 2004
    #10
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Anand
    Replies:
    1
    Views:
    352
    Cliff Wells
    Jul 23, 2003
  2. ulysses
    Replies:
    4
    Views:
    764
    Werner Schiendl
    Oct 22, 2003
  3. Logan
    Replies:
    5
    Views:
    762
    David Bolen
    Dec 11, 2003
  4. Ruben Charles
    Replies:
    6
    Views:
    498
    =?ISO-8859-1?Q?Michael_Str=F6der?=
    Oct 25, 2005
  5. Robin Dunn
    Replies:
    0
    Views:
    516
    Robin Dunn
    Mar 28, 2006
Loading...

Share This Page