|
The Personal Web Pages of Chris X. EdwardsA Simplified Tk Reference |
| Keyword: | scale |
| Description: | Slider widget for setting/displaying a continuous variable setting. |
| Example: | #note- The simplest example of a scale scale .s; pack .s; |
![]() |
|
| Example: |
#note- This example produces a slider bar which is ideal for setting
#note- a greyscale level. When it is adjusted the slider is set to the
#note- grey value.
proc greyit { valnow } {
set t [expr int($valnow*2.55)]
set t [format "%02X" $t]
.shade configure -bg "#$t$t$t"
}
scale .shade -fg red -bg black -orient horiz -command greyit;
.shade set 50; pack .shade;
|
![]() |
|
| Official Syntax: |
http://www.scriptics.com/man/tcl8.4/TkCmd/scale.htm |
| Previous | Home | Next |
|
This page was created with only free, open-source, publicly licensed software.
This page was designed to be viewed with any browser on any system. | ||
| Chris X. Edwards ~ January 2004 | ||