| Itcl  | Itk  | Itcl @ Wiki  | Itcl @ SF  | Tcl  | Tcl @ Wiki |
  home || iwidgets || man pages cross ref distribution docs faq  
buttonbox
calendar
canvasprintbox
canvasprintdialog
checkbox
combobox
dateentry
datefield
dialog
dialogshell
disjointlistbox
entryfield
extbutton
extfileselectionbox
extfileselectiondialog
feedback
fileselectionbox
fileselectiondialog
finddialog
hierarchy
hyperhelp
labeledframe
labeledwidget
mainwindow
menubar
messagebox
messagedialog
notebook
optionmenu
panedwindow
promptdialog
pushbutton
radiobox
regexpfield
scrolledcanvas
scrolledframe
scrolledhtml
scrolledlistbox
scrolledtext
scrolledwidget
selectionbox
selectiondialog
shell
spindate
spinint
spinner
spintime
tabnotebook
tabset
timeentry
timefield
toolbar
watch

man page | options | methods

Feedback

The feedback iwidget is used to display the status of a task, so the user has some feedback on the status of the task. The user gets a graphical progress indicator (progress bar) as well as a numerical one (percentage). As the task progresses, the bar and the percentage increase. This is achieved through the step public method. By default, the step method increases the progess by one step. A numerical value can also be given to the method to increment more than one step. Each step is determined by what is given for the option -steps. Each step will be equal to (-steps)/100 percentage points. So, if (-steps) is equal to 20, then each step will be 5%. For further information, see the Feedback manpage

Components: bar hull label percentage trough
				

wm title . "Feedback Example"
wm geometry . 225x75

##=========================================================
##  Create a Feedback iwidget
##=========================================================
##
iwidgets::feedback .fb \
  -steps 40 \
  -labeltext "Loading File..." \
  -barcolor red \
  -barheight 90 \
  -troughcolor ghostwhite

pack .fb \
  -fill x


##
##	Change the appearance of the trough and bar
##
.fb component trough configure \
  -relief ridge \
  -bd 3

.fb component bar configure \
  -bd 10 \
  -relief sunken

.fb component hull configure \
  -relief groove \
  -bd 4


##
##	Create a task that needs feedback
##
foreach s {1 2 3 4 5} {

  update idletasks
  .fb step $s
  after 1000
}


Download this sample code
man page | options | methods
 
  home || iwidgets || man pages cross ref distribution docs faq  
Copyright | Contributions | Development Team | Credits
Bugs/Comments/Suggestions about this web site