0

Can someone tell me how to create a simple but attractive splash screen to load at the start of my program which will highlight:

1) the program title
2) who the program is for
3) who designed the program and
4) what version of the program it is

thanks

3
Contributors
4
Replies
9
Views
8 Years
Discussion Span
Last Post by MikeyFTW
0

Which GUI toolkit are you using?

what like Tkinter or something...im not sure

0

Here is an example of using the Tkinter GUI toolkit to bring up a 5 second splash screen. All the info you want needs to be written into the picture itself, using one of the popular image editing utilities:

# create a splash screen, 80% of display screen size, centered,
# displaying a GIF image with needed info, disappearing after 5 seconds

import Tkinter as tk

root = tk.Tk()
# show no frame
root.overrideredirect(True)
width = root.winfo_screenwidth()
height = root.winfo_screenheight()
root.geometry('%dx%d+%d+%d' % (width*0.8, height*0.8, width*0.1, height*0.1))

# take a .jpg picture you like, add text with a program like PhotoFiltre
# (free from http://www.photofiltre.com) and save as a .gif image file
image_file = "LakeSplash.gif"
#assert os.path.exists(image_file)
# use Tkinter's PhotoImage for .gif files
image = tk.PhotoImage(file=image_file)
canvas = tk.Canvas(root, height=height*0.8, width=width*0.8, bg="brown")
canvas.create_image(width*0.8/2, height*0.8/2, image=image)
canvas.pack()

# show the splash screen for 5000 milliseconds then destroy
root.after(5000, root.destroy)
root.mainloop()

# your console program can start here ...
print "How did you like my informative splash screen?"
Attachments LakeSplash.gif 96.67 KB
0

Here is an example of using the Tkinter GUI toolkit to bring up a 5 second splash screen. All the info you want needs to be written into the picture itself, using one of the popular image editing utilities:

# create a splash screen, 80% of display screen size, centered,
# displaying a GIF image with needed info, disappearing after 5 seconds

import Tkinter as tk

root = tk.Tk()
# show no frame
root.overrideredirect(True)
width = root.winfo_screenwidth()
height = root.winfo_screenheight()
root.geometry('%dx%d+%d+%d' % (width*0.8, height*0.8, width*0.1, height*0.1))

# take a .jpg picture you like, add text with a program like PhotoFiltre
# (free from http://www.photofiltre.com) and save as a .gif image file
image_file = "LakeSplash.gif"
#assert os.path.exists(image_file)
# use Tkinter's PhotoImage for .gif files
image = tk.PhotoImage(file=image_file)
canvas = tk.Canvas(root, height=height*0.8, width=width*0.8, bg="brown")
canvas.create_image(width*0.8/2, height*0.8/2, image=image)
canvas.pack()

# show the splash screen for 5000 milliseconds then destroy
root.after(5000, root.destroy)
root.mainloop()

# your console program can start here ...
print "How did you like my informative splash screen?"

Awesome man! thanks for your help :)

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.