ttk::progressbar can't be disabled?

19 Views Asked by At

Testing this ( 8.6.11 - Win7 32 )

package require Tk
set p [ttk::progressbar .progreso -orient horizontal -mode indeterminate ]
set b [ttk::button .botonc -text "Disable bar ?" -command  {$p configure -state disabled} ]
set v [ttk::button .botons -text "Yes,please!" -command {$p state disabled } ]
set s [ttk::button .show -text "Show me" -command { puts "state [$p state]"} ]
pack $b $v $p $s -fill both -expand 1
$p start 5

If you click "Disable bar ?" you get "Error: unknown option "-state".

If you click "Yes, please!" and then click "Show me" you get "state disabled" (but the widget is still enabled)

If you click first "Show me" you get "state ".

According to documentation you could disable a progressbar, however as showed in this example it seems not possible.

So, it's possible set ttk::progressbar's state as disabled ?

Thanks,

Alejandro

0

There are 0 best solutions below