Manual Pages for UNIX Darwin command on man tklib_history
MyWebUniversity

Manual Pages for UNIX Darwin command on man tklib_history

history(n) Provides a history for Entry widgets history(n)

NAME

history - Provides a history for Entry widgets

SYNOPSIS

package require TTccll 88..44 package require TTkk 88..44 package require hhiissttoorryy ??00..11?? ::::hhiissttoorryy::::iinniitt pathName ?length? ::::hhiissttoorryy::::rreemmoovvee pathName ::::hhiissttoorryy::::aadddd pathName text ::::hhiissttoorryy::::ggeett pathName ::::hhiissttoorryy::::cclleeaarr pathName ::::hhiissttoorryy::::ccoonnffiigguurree pathName option ?value? bell

DESCRIPTION

This package provides a convenient history mechanism for Entry widgets. The history may be accessed with the up and down arrow keys. ::::hhiissttoorryy::::iinniitt pathName ?length? Arranges to remember the history of the named Entry widget. An optional length determines the number of history entries to

keep. This may be changed later with ::::hhiissttoorryy::::ccoonnffiigguurree. His-

tory entries must be added with the ::::hhiissttoorryy::::aadddd command before they can be seen. ::::hhiissttoorryy::::rreemmoovvee pathName Forgets all history entries for the Entry pathName and removes the history bindings. ::::hhiissttoorryy::::aadddd pathName text This command is used to add history entries to an Entry that has previously had ::::hhiissttoorryy::::iinniitt called on it. This command should be called from your Entry handler with the contents of the entry (or whatever you wish to add to the history). ::::hhiissttoorryy::::ggeett pathName This command returns a list containing the history entries for the Entry pathName ::::hhiissttoorryy::::cclleeaarr pathName This command clears the history list for the named Entry. ::::hhiissttoorryy::::ccoonnffiigguurree pathName option ?value? This command queries or sets configuration options. Currently the options recognized are length and alert. Setting the length determines the number of history entries to keep for the named Entry. Alert specifies the command to run when the user reaches the end of the history, it defaults to bell entry .e

bind .e [list ProcessEntry %W]

::history::init .e pack .e proc ProcessEntry {w} {

set text [$w get]

if {$text == ""} { return }

::history::add $w $text

puts $text

$w delete 0 end

} KKEEYYWWOORRDDSS entry, history history 0.1 history(n)




Contact us      |      About us      |      Term of use      |       Copyright © 2000-2019 MyWebUniversity.com ™