You are not logged in.
Pages: 1
Hello. I've started to learn Python in the last 2 days. I have heard about PyGTK (I'm using Gnome) and Glade. How can I build the GUI for a simple program. For example a simple "Hello World"? Thaks.
Sorry for my english.
Offline
pygtk.org
I am a gated community.
Offline
Having used both PyGTK and WXPython, I'd suggest WXPython is a little easier to use and more featureful. PyGTK has tended to be more stable in the past though.
I don't have python (or even linux :'() installed at the moment, or I'd create a hello world window right inside the python interpreter for you. But since google is awesome, I'll link you:
http://www.google.ca/search?q=hello+world+wxpython
Dusty
Offline
I also suggest WxPython. Whenever I first started using PyGTK I thought it was great. Then I tried to use some very simple, very basic controls and realized how anal PyGTK can really be. I'd like to try PyQT(4) sometime too. Anybody have any experience with it?
Offline
Here are some tutorials: http://www.learningpython.com/
Offline
import gtk
import gnome.ui
import gtk.glade
wTree = gtk.glade.XML("nameofgladefile.glade") # Name of the gladefile you made
window = wTree.get_widget("window1") # Name of the main window, you can set the name in glade
window.show()
Offline
PyQt4 ftw. I wrote simple ipod manager using it
IRC: Stalwart @ FreeNode
Skype ID: thestalwart
WeeChat-devel nightly packages for i686
Offline
ok. i think ill learn some wxpython. but there is some tool like glade for python? i have found XRCed http://xrced.sourceforge.net/ its a good tool.
Offline
Offline
I'd like to try PyQT(4) sometime too. Anybody have any experience with it?
I can't comment on QT4 yet, but QT3 is simply awsome. I found it much more straight forward than pyGTK. Unfortunately there is far more pyGTK tutorials floating around the web. qtdoc makes up for that though.
"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."
SETH / Jane Roberts
Offline
I'd like to try PyQT(4) sometime too. Anybody have any experience with it?
I can't comment on QT4 yet, but QT3 is simply awsome. I found it much more straight forward than pyGTK. Unfortunately there is far more pyGTK tutorials floating around the web. qtdoc makes up for that though.
I have been working on a project using pyqt4 for a while now and am very impressed, though I think pygtk might be easier for a beginner (except maybe the tree/list-view stuff). glade is quite a lot simpler than qtdesigner, which rather confused me with its many features, so I haven't been using it. Qt4 is really very big, with unbelievably many classes and widgets, many of which you wouldn't normally need to touch, but they are there when you need them (gtk is at present a bit more limited). The documentation is pretty good, but doesn't cover absolutely everything you might need to know. I have had to work out quite a bit myself by guessing and playing around. I'm not absolutely sold on some of the features (such as the signals/slots implementation), but I would certainly recommend giving it a look, it feels really solid and comprehensive.
Oh, and if you are in the unfortunate position of needing to write code which which also run on w****ws, pyqt4 looks like a pretty good choice.
My (very limited) experience with wxpython was not so positive (it seemed buggy and the documentation confused as often as it enlightened me), but as that could just be my problem I'll not say any more about it.
larch: http://larch.berlios.de
Offline
Offline
except maybe the tree/list-view stuff
Doing tree/list-view stuff made me angry. I sobbed like a little girl. Then I used WxPython and all my tears dried away (though some of the design choices the wxPython devs made irritated me). Then I tried PyQT4 and the room brightened and rainbows surrounded me. A blind man that was walking in front of my house gained back his sense of vision, and the corpse of a dead dog rose and did a flip, happy to be alive once more.
Offline
Then I tried PyQT4 and the room brightened and rainbows surrounded me. A blind man that was walking in front of my house gained back his sense of vision, and the corpse of a dead dog rose and did a flip, happy to be alive once more.
That's freakin awsome bro'. It it sounds so great in your poetical words...
"Your beliefs can be like fences that surround you.
You must first see them or you will not even realize that you are not free, simply because you will not see beyond the fences.
They will represent the boundaries of your experience."
SETH / Jane Roberts
Offline
hahaha!
That is the funniest thing I have read on the forums in months!
"Be conservative in what you send; be liberal in what you accept." -- Postel's Law
"tacos" -- Cactus' Law
"t̥͍͎̪̪͗a̴̻̩͈͚ͨc̠o̩̙͈ͫͅs͙͎̙͊ ͔͇̫̜t͎̳̀a̜̞̗ͩc̗͍͚o̲̯̿s̖̣̤̙͌ ̖̜̈ț̰̫͓ạ̪͖̳c̲͎͕̰̯̃̈o͉ͅs̪ͪ ̜̻̖̜͕" -- -̖͚̫̙̓-̺̠͇ͤ̃ ̜̪̜ͯZ͔̗̭̞ͪA̝͈̙͖̩L͉̠̺͓G̙̞̦͖O̳̗͍
Offline
Then I tried PyQT4 and the room brightened and rainbows surrounded me. A blind man that was walking in front of my house gained back his sense of vision, and the corpse of a dead dog rose and did a flip, happy to be alive once more.
That's freakin awsome bro'. It it sounds so great in your poetical words...
LMAO.. and some say Python is a beginners language.. sounds pretty damn powerful to me!
Could we see a snippit of code you used to witness these things?
Best Post Ever!
Offline
I personally love pygtk.
I am a gated community.
Offline
The python's bite's an antidote to poison inflicted on humans and other entities by way too complex programming?
Sounds nice nontheless.
I like poetical wording, wherever it may find its usage.
celestary
Intel Core2Duo E6300 @ 1.86 GHz
kernel26
KDEmod current repository
Offline
Pages: 1