10.12. Setting the Value of a Scale

You can force the value associated with the scale by using the setmethod:

$scale->set(value);

This method is great for setting an initial value if you aren't using the -variable option at all. If you were using -variable, just set that variable to the desired starting value.

Get Learning Perl/Tk now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.