python - Pygtk VS Pyqt VS WxPython VS Tkinter - Stack Overflow
I can't really say which one is the most used, but here are some feature comparisons:
Tkinter:
- Built in to Python
- Not native-looking GUIs by default before Python 2.7
- Simple, easy to learn
- In Python 2.7, ttk support was added (themed widgets)
- Some GUI designers, but they aren't really as functional as those for other toolkits (but the simplicity of Tkinter alleviates this)
PyGTK:
- Focused on Linux, works on Windows but can be a pain (thanks to detly for pointing this out)
- Has a GUI designer, Glade
- More functionality/weight than Tkinter
- LGPL
PyGObject (GTK3, will replace PyGTK):
-- http://article.gmane.org/gmane.comp.gnome.gtk%2B.python/15449
- Still focused on Linux
- Basically the same, but access is done through GObject
- Relatively new, but will replace PyGTK
New users wising to develop Python applications using GTK are recommended to use the GObject-Introspection features available in PyGObject. Existing authors of PyGtk applications are also recommended to port their applications to PyGObject if they wish to take advantage of new features appearing in GTK-3 and beyond.
wxPython:
- Cross-platform
- Native widgets on each platform
- More functionality/weight than Tkinter
- GUI designers like wxGlade and others
- wxWindows license (similar to LGPL)
PyQt:
- Cross-platform
- Native (or at least native-looking) widgets on each platform, styleable with CSS
- More functionality/weight than Tkinter (probably the most here: JavaScript, QML...)
- GPL licensed (commercial licenses available)
- QtDesigner (made by Nokia) and utilities to convert to Python
PySide:
- Python Qt binding (like PyQT) but LGPL
- Cross-platform
- API is almost the same as PyQT, but it only supports the "new-style" PyQT API.
PyQt, wxWidgets, and PyGTK all support OpenGL.
All three have Webkit bindings, though PyQt's/PySide's seem to be the easiest to use (it is integrated, after all).
Tkinter is the simplest, but least feature-complete. wxPython and PyQt are probably the most powerful in terms of what's built in (as far as I know), but PyGTK is also good, especially if you're targeting Linux. New apps using GTK should use GObject rather than the old PyGTK interface.
All are cross-platform. (PySide also supports MeeGo.)
All support Python 3, except for PySide and wxPython, whose support is forthcoming (0,1).
Some links: Developing user interface in Python - TkInter Vs PyQt
0 意見:
張貼留言