added a stock OK button, increased minimum width of the command window
This commit is contained in:
parent
299eb9b615
commit
40d433d815
@ -4,11 +4,17 @@ import gtk
|
||||
class CmdWindow:
|
||||
def __init__(self):
|
||||
self.window = gtk.Window(gtk.WINDOW_TOPLEVEL)
|
||||
self.window.set_geometry_hints(min_width = 350);
|
||||
self.window.connect("delete_event", self.delete_event)
|
||||
self.window.connect("destroy", self.destroy_event)
|
||||
self.entry = gtk.Entry()
|
||||
self.entry.connect("activate", self.activate_event)
|
||||
self.window.add(self.entry)
|
||||
self.button = gtk.Button(stock = gtk.STOCK_OK)
|
||||
self.button.connect("clicked", self.activate_event)
|
||||
self.hbox = gtk.HBox()
|
||||
self.hbox.pack_start(self.entry)
|
||||
self.hbox.pack_start(self.button, expand = False)
|
||||
self.window.add(self.hbox)
|
||||
self.window.show_all()
|
||||
|
||||
def main(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user