Scale: get Scale value : Scale « GUI Tk « Python






Scale: get Scale value

Scale: get Scale value

from Tkinter import *
root = Tk()
scl = Scale(root, from_=-100, to=100, tickinterval=50, resolution=10)
scl.pack(expand=YES, fill=Y)

def report(): print scl.get()

Button(root, text='state', command=report).pack(side=RIGHT)
root.mainloop()

           
       








Related examples in the same category

1.Scale Demo: random choiceScale Demo: random choice
2.Use Scale
3.Bound Scale action with a canvasBound Scale action with a canvas
4.Scale widgetScale widget
5.Scale Demo: get scale value and open different dialogsScale Demo: get scale value and open different dialogs
6.Scale used to control the size of a circleScale used to control the size of a circle
7.Canvas paint: controlled by ScaleCanvas paint: controlled by Scale