|
| 1 | + The Scrolling Utilities Package Scrollutil |
| 2 | + |
| 3 | + by |
| 4 | + |
| 5 | + Csaba Nemethi |
| 6 | + |
| 7 | + csaba.nemethi@t-online.de |
| 8 | + |
| 9 | + |
| 10 | +What Is Scrollutil? |
| 11 | +------------------- |
| 12 | + |
| 13 | +Scrollutil is a library package for Tcl/Tk versions 8.0 or higher, |
| 14 | +written in pure Tcl/Tk code. It contains: |
| 15 | + |
| 16 | + - the implementation of the "scrollarea" and "scrollsync" mega- |
| 17 | + widgets, including a general utility module for mega-widgets; |
| 18 | + - commands for user-friendly mouse wheel event handling in scrollable |
| 19 | + widget containers like BWidget ScrollableFrame and |
| 20 | + iwidgets::scrolledframe. These commands require Tcl/Tk versions 8.4 |
| 21 | + or higher on X11 and Mac OS X and Tk 8.6b2 or later on Windows; |
| 22 | + - demo scripts illustrating the use of the Scrollutil package in |
| 23 | + connection with various scrollable widgets and the above-mentioned |
| 24 | + scrollable widget containers; |
| 25 | + - a tutorial in HTML format; |
| 26 | + - reference pages in HTML format. |
| 27 | + |
| 28 | +The reason for requiring at least Tk version 8.6b2 on Windows for the |
| 29 | +above-mentioned commands for mouse wheel event handling is that in |
| 30 | +earlier Tk versions on this platform the mouse wheel events were sent to |
| 31 | +the widget having the focus rather than to the one under the pointer. |
| 32 | + |
| 33 | +How to Get It? |
| 34 | +-------------- |
| 35 | + |
| 36 | +Scrollutil is available for free download from the Web page |
| 37 | + |
| 38 | + http://www.nemethi.de |
| 39 | + |
| 40 | +The distribution file is "scrollutil1.1.tar.gz" for UNIX and |
| 41 | +"scrollutil1_1.zip" for Windows. These files contain the same |
| 42 | +information, except for the additional carriage return character |
| 43 | +preceding the linefeed at the end of each line in the text files for |
| 44 | +Windows. |
| 45 | + |
| 46 | +Scrollutil is also included in tklib, which has the address |
| 47 | + |
| 48 | + http://core.tcl.tk/tklib |
| 49 | + |
| 50 | +How to Install It? |
| 51 | +------------------ |
| 52 | + |
| 53 | +Install the package as a subdirectory of one of the directories given |
| 54 | +by the "auto_path" variable. For example, you can install it as a |
| 55 | +directory at the same level as the Tcl and Tk script libraries. The |
| 56 | +locations of these library directories are given by the "tcl_library" |
| 57 | +and "tk_library" variables, respectively. |
| 58 | + |
| 59 | +To install Scrollutil on UNIX, "cd" to the desired directory and unpack |
| 60 | +the distribution file "scrollutil1.1.tar.gz": |
| 61 | + |
| 62 | + gunzip -c scrollutil1.1.tar.gz | tar -xf - |
| 63 | + |
| 64 | +On most UNIX systems this can be replaced with |
| 65 | + |
| 66 | + tar -zxf scrollutil1.1.tar.gz |
| 67 | + |
| 68 | +Both commands will create a directory named "scrollutil1.1", with the |
| 69 | +subdirectories "demos", "doc", and "scripts". |
| 70 | + |
| 71 | +On Windows, use WinZip or some other program capable of unpacking the |
| 72 | +distribution file "scrollutil1_1.zip" into the directory |
| 73 | +"scrollutil1.1", with the subdirectories "demos", "doc", and "scripts". |
| 74 | + |
| 75 | +How to Use It? |
| 76 | +-------------- |
| 77 | + |
| 78 | +The Scrollutil distribution provides two packages, called Scrollutil and |
| 79 | +Scrollutil_tile. The main difference between the two is that |
| 80 | +Scrollutil_tile enables the tile-based, theme-specific appearance of |
| 81 | +scrollarea widgets; this package requires Tcl/Tk 8.4 or higher and tile |
| 82 | +0.6 or higher. It is not possible to use both packages in one and the |
| 83 | +same application, because both are implemented in the same "scrollutil" |
| 84 | +namespace and provide identical commands. |
| 85 | + |
| 86 | +To be able to use the commands and variables implemented in the package |
| 87 | +Scrollutil, your scripts must contain one of the lines |
| 88 | + |
| 89 | + package require scrollutil ?version? |
| 90 | + package require Scrollutil ?version? |
| 91 | + |
| 92 | +Likewise, to be able to use the commands and variables implemented in |
| 93 | +the package Scrollutil_tile, your scripts must contain one of the lines |
| 94 | + |
| 95 | + package require scrollutil_tile ?version? |
| 96 | + package require Scrollutil_tile ?version? |
| 97 | + |
| 98 | +Since the packages Scrollutil and Scrollutil_tile are implemented in the |
| 99 | +"scrollutil" namespace, you must either import the procedures you need, |
| 100 | +or use qualified names like "scrollutil::scrollarea". |
| 101 | + |
| 102 | +For a detailed description of the commands and variables provided by |
| 103 | +Scrollutil and of the examples contained in the "demos" directory, see |
| 104 | +the tutorial "scrollutil.html" and the reference pages, all located in |
| 105 | +the "doc" directory. |
0 commit comments