synchronising two scroll bars
"Henry Merryweather" <[email protected]> Wed, 12 Jul 2006 17:53:59 +0100
| Newsgroups | gmane.comp.lang.perl.tk |
|---|---|
| Message-ID | <001901c6a5d3$c565e670$0300aac0@eveshampc> |
I have two panes with scroll bars in the vertical and horizontal directions. I want to be able to move a scroll bar in one pane and get the equivalent scroll bar in the other pane to move at the same time and to the 'same' place. Using a button I can achieve this will the following Perl Tk lines @lcp = $one_pane->yview; $other_pane->yview(moveto => $lcp[0]); How can I get this to be done automatically when I move the scroll bars. I guess that I need to use a 'bind' whose 'sub' carries out the equivalent of the two lines. However I could not see a reference to this in Chapter 15 of Mastering Perl Tk and other web searches gave me anything I could use. Best regards Henry Merryweather Telephone: +44 (0) 1225 859051 Web: www.merryweathersolutions.co.uk --++**==--++**==--++**==--++**==--++**==--++**==--++**== ptk mailing list [email protected] https://mailman.stanford.edu/mailman/listinfo/ptk