It is a little confusing about "Glade": "Glade" as a GUI HTML-code generating tool has not been depreciated. Also note that this tutorial references the revised GtkBuilder code (initially crafted above by FokkerCharlie, but simplified in the video by deleting some lines - see below).ģ. When you click on the link to the tutorial, don't click Play because that is a different tutorial ("List Comprehension"), but go down to "Tutorial - A GUI application using Python". However, the newer code posted above and below does work (because it is indented).Ģ. All of the Python code that he shows on the first page will not run if you copy and paste it because it is lacking indentation. I would like to clarify a couple things to help others reading/watching this tutorial for the first time:ġ. Anyway, thank you very much for your tutorial! And now I need to figure out how to convert my program from Python and Gtk/Glade to. So, I googled the two main components of Quickly, Python and Gtk, and found Glade and your tutorial! I installed Python, Glade, gtk, and pygtk on my Windows PC and everything works great (except that I am using Eclipse for the Python code and Eclipse doesn't find gtk - although the Python command line finds it just fine - UPDATE: See solution below to get gtk to work in Eclipse). But, I also wanted to do a Windows version of my program that I created in Quickly, found Windows API very difficult, and found that wxPython would not do everything I wanted (or at least easily - it uses separate sizers and I couldn't get it to size bitmap pictures). I am new to programming and this was one of the most helpful things that I have come across in months! Actually, in Ubuntu, Quickly does all of this in one program, and will even create files for you to distribute your program. No one will remember all the features on offer. Python has great docs, and having them open can really help. There are lots of very small, simple apps out there, just try making something, get into the flow of thinking about how to do something.Īnd whenever you are writing python, always have the reference open. As to where to go next, I'd suggest thinking up a small project, something that you want, and create it. Gtk.main()I daresay that it could be tidier or bettered in many ways (pointers welcome). _object("entryResult").set_text(thistime.giveResult()) Thistime = adder( entry1.get_text(), entry2.get_text() ) Self.result = int( number1 ) + int( number2 )
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |