If you find Anatomy of a Scale elsewhere on wikipython you will recognize this widget.
# TEST AREA Scale, simple, horizontal demo
# standard set up header code 2
# see Anatomy of a Scale for attribute identificaiton
from tkinter import *
root = Tk()
root.attributes('-fullscreen', True)
root.configure(background='SteelBlue4')
scrW = root.winfo_screenwidth()
scrH = root.winfo_screenheight()
workwindow = str(1024) + "x" + str(768)+ "+" +str(int((scrW-1024)/2)) + "+" +str(int((scrH-768)/2))
top1 = Toplevel(root, bg="light blue")
top1.geometry(workwindow)
top1.title("Top 1 - Workwindow")
top1.attributes("-topmost", 1) # make sure top1 is on top to start
root.update() # but don't leave it locked in place
top1.attributes("-topmost", 0) # in case you use lower or lift
#exit button - note: uses grid
b3=Button(root, text="Egress", command=root.destroy)
b3.grid(row=0,column=0,ipadx=10, ipady=10, pady=5, padx=5, sticky = W+N)
#____________________________
def scaletest(self):
l1.configure(text=myscalevalue.get())
myscalevalue=IntVar() # have to have a variable to hold position value
myscalevalue.set(125) # set it to start in the middle in this case
myscale=Scale(top1,
activebackground="orangered",
bg="AntiqueWhite3",
bigincrement=20,
bd=20,
command=scaletest,
digits=3,
font="Arial 10 bold",
fg="blue3",
from_= 0,
to=255,
highlightbackground="goldenrod3",
highlightcolor="red",
highlightthickness=15,
label="Test Scale",
length=900,
orient="horizontal", # can be vertical or horizontal
relief=SUNKEN,
repeatdelay=900,
repeatinterval=100,
resolution=1,
showvalue=True,
sliderlength=125,
sliderrelief=RAISED,
state=NORMAL,
takefocus=1,
troughcolor="SpringGreen3",
tickinterval=50,
variable=myscalevalue,
width=100)
myscale.pack(pady=100)
l1=Label(top1, text=myscalevalue.get(), width=30, \
relief=SUNKEN, height=2, font="Arial 10 bold")
l1.pack(pady=50)
#____________________________
root.mainloop()

