From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mo DeJong To: sourcenav@sources.redhat.com Subject: Re: rebinding editor keys Date: Mon, 16 Jul 2001 11:09:00 -0000 Message-id: References: X-SW-Source: 2001-q3/msg00051.html On Mon, 16 Jul 2001, Left Spin wrote: > I'm new to Tcl/Tk. I'm rebinding keystrokes for a text widget in Source > Navigator. > > I'm trying to bind to a page up script. The online Man page for bind might help in this case: http://tcl.activestate.com/man/tcl8.3.2/TkCmd/bind.htm Also: http://tcl.activestate.com/man/tcl8.3.2/ > I have to admit I don't understand how this bind syntax works. I found it in > some of the Source Navigator source code. > I was thinking that maybe I could just map the keystroke to the already > defined page up functionality. Try it without all the SN stuff. Just start up a wish shell and play around with it. % wish % text .t .t % pack .t % bind .t {puts "linesperpage is [%W cget -height]"} (Move mouse into text widget and press Ctrl-R) linesperpage is 24 cheers Mo