Tkinter Relief Styles: The relief of the components refers to the influence of some of the components outside of the analog-to-digital periphery. Below is a row of buttons for the screen showing all possible relief style elements of the relief type refers to some simulation of the influence of the outside of the components around. Here's a line of buttons that shows all the possible relief styles:
The following is a list of possible constants that can be used to provide relief properties.
FLAT
Raised
SUNKEN
GROOVE
RIDGE
Example:
From Tkinter import *import tkintertop = tkinter.tk () B1 = Tkinter.button (top, Text = "FLAT", Relief=flat) B2 = Tkinter.butt On (top, Text = "raised", relief=raised) B3 = Tkinter.button (top, Text = "SUNKEN", relief=sunken) B4 = Tkinter.button (Top, TE XT = "GROOVE", relief=groove) B5 = Tkinter.button (top, Text = "RIDGE", Relief=ridge) B1.pack () B2.pack () B3.pack () B4.pack () B5.pack () Top.mainloop ()
This will produce the following results:
Tkinter Relief styles (style)