summaryrefslogtreecommitdiffstats
path: root/gui.py
diff options
context:
space:
mode:
authorMatt Wilson <msw@redhat.com>1999-04-25 20:06:53 +0000
committerMatt Wilson <msw@redhat.com>1999-04-25 20:06:53 +0000
commit3a44d1f8ea178f88e2e9f540de6cfdcfcbaba001 (patch)
treeddfc76462ae9d4be2da8c609396c1b9365082c7e /gui.py
parent785d44bf73ccc1d57d771895cc94112a34857809 (diff)
downloadanaconda-3a44d1f8ea178f88e2e9f540de6cfdcfcbaba001.tar.gz
anaconda-3a44d1f8ea178f88e2e9f540de6cfdcfcbaba001.tar.xz
anaconda-3a44d1f8ea178f88e2e9f540de6cfdcfcbaba001.zip
wee! first taste of python exception handling
Diffstat (limited to 'gui.py')
-rwxr-xr-xgui.py20
1 files changed, 11 insertions, 9 deletions
diff --git a/gui.py b/gui.py
index 4d6f7fb4d..992dbbd64 100755
--- a/gui.py
+++ b/gui.py
@@ -13,7 +13,7 @@ def WelcomeWindow():
window.connect("destroy", destroy)
window.set_border_width(10)
window.set_title("Welcome to Red Hat Linux!")
-
+
label = GtkLabel("Welcome to Red Hat Linux!\n\n"
"This installation process is outlined in detail in the "
"Official Red Hat Linux Installation Guide available from "
@@ -26,17 +26,20 @@ def WelcomeWindow():
button = GtkButton("Ok")
button.connect("clicked", mainquit)
vbox = GtkVBox (FALSE, 10)
- vbox.pack_start(label, TRUE, TRUE, 0)
- vbox.pack_start(button, FALSE, TRUE, 0)
+ vbox.pack_start(label, FALSE, FALSE, 0)
+ vbox.pack_start(button, FALSE, FALSE, 0)
hbox = GtkHBox (FALSE, 10)
+
try:
- im = GdkImlib.Image("shadowman-200.png")
- except RuntimeError: return
+ im = GdkImlib.Image("shadowman-200.png")
+ im.render()
+ pix = im.make_pixmap()
+ hbox.pack_start(pix, TRUE, TRUE, 0)
+
+ except:
+ print "Unable to load shadowman-200.png"
- im.render()
- pix = im.make_pixmap()
- hbox.pack_start(pix, TRUE, TRUE, 0)
hbox.pack_start(vbox, TRUE, TRUE, 0)
window.add(hbox)
@@ -57,4 +60,3 @@ for step in steps.keys():
if steps[step]:
steps[step]()
mainloop()
-