| | |
Best GUI toolkit?
Thread Solved
![]() |
Ok, so I'm gonna work on a program, and I want to enable a gui for it.
I have a few questions though...
Question: Are there any out there that wont need a class structure? (I;ve never gotten them, and I'm working on them right now...)
Question: How about easily updated and most versitile?
Question: In your opinion, which is best?
I have a few questions though...
Question: Are there any out there that wont need a class structure? (I;ve never gotten them, and I'm working on them right now...)
Question: How about easily updated and most versitile?
Question: In your opinion, which is best?
Blender is by far the best free 3D computer Graphics program and it is expandable with python! GoTo www.blender3d.org
I think visual studio, is insanely easy to create a good looking gui.
Of course you'll need the dotnet framework, but that's not a problem if you don't have it. You just download it. And learning oop is a piece of cake ain't it.
Java as well, with a GUI builder would also be quick and easy. As long as you have a good idea regarding back end programming you shouldn't have a problem.
For python try this:
http://wxglade.sourceforge.net/
Respect, from one blender fan to another.
Of course you'll need the dotnet framework, but that's not a problem if you don't have it. You just download it. And learning oop is a piece of cake ain't it.
Java as well, with a GUI builder would also be quick and easy. As long as you have a good idea regarding back end programming you shouldn't have a problem.
For python try this:
http://wxglade.sourceforge.net/
Respect, from one blender fan to another.
Last edited by iamthwee; Nov 25th, 2006 at 11:10 am.
*Voted best profile in the world*
None of the traditional GUI toolkits for Python require you to use object oriented programming ('OOP has class'), but it makes more complex programs easier to write and maintain. For some additional info see:
http://www.daniweb.com/techtalkforums/thread61194.html
http://www.daniweb.com/techtalkforums/thread61194.html
May 'the Google' be with you!
I have started to program with windows concepts. It is different then console and that is were the learning curve sets in. Once you realize how to approach a GUI with its frames, windows, dialog boxes, buttons, labels and so on, you will enjoy it. I use Tkinter right now, it is part of the Python installation, and seems to be the easiest GUI toolkit to learn with.
No one died when Clinton lied.
Hi there danizzil14, I am giving you two examples of a simple Tkinter 'Hello World' code. The first one is without the use of class:
Here is the same program using a class structure:
python Syntax (Toggle Plain Text)
# Tkinter programming without a class from Tkinter import * def say_hi(): # function for hi_button action # show new text on the label hi_label.config(text="Hi there, everyone!") # create the basic window root = Tk() frame = Frame(root) frame.pack() # specify button action with command=function # foreground/fg is red to color text q_button = Button(frame, text=" QUIT ", fg="red", command=root.destroy) q_button.pack(side=LEFT) hi_button = Button(frame, text=" Hello ", command=say_hi) hi_button.pack(side=LEFT) # width of label is in characters hi_label = Label(frame, text=" Hello, world! ", bg='yellow', width=20) hi_label.pack(side=LEFT) # start the event loop to respond to mouse clicks etc. root.mainloop()
python Syntax (Toggle Plain Text)
# Tkinter programming using a class from Tkinter import * class App(object): """create a frame/window with 2 buttons and a label""" def __init__(self, master): frame = Frame(master) frame.pack() # specify button action with command=function # foreground/fg is red to color text self.q_button = Button(frame, text=" QUIT ", fg="red", command=root.destroy) self.q_button.pack(side=LEFT) self.hi_button = Button(frame, text=" Hello ", command=self.say_hi) self.hi_button.pack(side=LEFT) # width of label is in characters self.hi_label = Label(frame, text=" Hello, world! ", bg='yellow', width=20) self.hi_label.pack(side=LEFT) def say_hi(self): # function for hi_button action # show new text on the label self.hi_label.config(text="Hi there, everyone!") # create the basic window root = Tk() # instantiate the App class app = App(root) # start the event loop to respond to mouse clicks etc. root.mainloop()
Last edited by vegaseat; Aug 13th, 2009 at 4:02 pm. Reason: newer code tags
drink her pretty
![]() |
Similar Threads
- Fix Tkinter Widget Location (Python)
- text editor (C++)
- business online app/business graphic app (Java)
- Project calculator (Python)
Other Threads in the Python Forum
- Previous Thread: pygame level problems
- Next Thread: GIFs in a Dict
| Thread Tools | Search this Thread |
alarm ansi app assignment backend beginner binary bluetooth character cipher cmd coordinates curves customdialog cx-freeze data decimals development directory dynamic exe feet file float format function generator getvalue gnu graphics halp heads homework http ideas input ip itunes java keycontrol leftmouse line linux list lists loop maintain maze millimeter module mouse number numbers output parsing path pointer prime programming progressbar push py2exe pygame pymailer python queue random recursion recursive schedule screensaverloopinactive script slicenotation sqlite ssh statistics string strings sudokusolver text thread time tlapse tuple type ubuntu unicode url urllib urllib2 variable ventrilo vigenere web webservice wikipedia write wxpython xlib xlwt






