Tcl/Tk: How to create a progress bar with a status text inside? -


i want create progress bar using tcl/tk >= 8.5 not show progress in graphical way percentage of progress number (centered) within progress bar (e. g. "12 %").

i thinking overlaying progress bar , label transparently or 1 making parent of other widget not figure out solution.

any ideas?

here simple program frame:

proc counter {} {   {set 0} {$i < 100} {incr i} {     puts "$i"     after 25     .pb configure -value $i     update idletask   } }  ttk::progressbar .pb -orient horizontal -maximum 100 -length 400 -value 0 button .bt -text "start counter" -command counter pack .pb pack .bt 

usually, don't. standard platform rendering of progress bars doesn't support such label.

however, can hack frames , labels (and clever use of place). wrote this page long ago has links code that. should still work, might not how want: standard these things should has changed lot on years.

enter image description here

i hate self-promotion, don't know of other code this.


Comments

Popular posts from this blog

how to insert data php javascript mysql with multiple array session 2 -

multithreading - Exception in Application constructor -

windows - CertCreateCertificateContext returns CRYPT_E_ASN1_BADTAG / 8009310b -