Created
November 21, 2012 09:58
-
-
Save trietptm/4124069 to your computer and use it in GitHub Desktop.
Colorized Labels in various fonts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from Tkinter import * | |
root = Tk() | |
Label(root, | |
text = "Red Text in Times Font", | |
fg = "red", | |
font = "Times").pack() | |
Label(root, | |
text = "Green Text in Helvetica Font", | |
fg = "light green", | |
bg = "darkgreen", | |
font = "Helvetica 16 bold italic").pack() | |
Label(root, | |
text = "Blue Text in Verdana bold", | |
fg = "blue", | |
bg = "yellow", | |
font = "Verdana 10 bold").pack() | |
root.mainloop() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment