walt | 7 Oct 19:44

MouseWheel binding bug in listbox and text widgets?

I've found several other posters with this same problem but I've never
seen a solution offered.  When starting any tk application (including
wish) I get this:

/usr/lib64/tk8.4/tk.tcl: no event type or button # or keysym
no event type or button # or keysym
    while executing
"bind Text <MouseWheel> {
        %W yview scroll [expr {- (%D / 120) * 4}] units
    }"

My workaround is to comment these lines in listbox.tcl and text.tcl:

--- text.tcl.orig       2008-10-07 09:01:39.000000000 -0700
+++ text.tcl    2008-10-07 10:38:57.000000000 -0700
@@ -460,9 +460,9 @@
         %W xview scroll [expr {-10 * (%D)}] units
     }
 } else {
-    bind Text <MouseWheel> {
-        %W yview scroll [expr {- (%D / 120) * 4}] units
-    }
+#    bind Text <MouseWheel> {
+#        %W yview scroll [expr {- (%D / 120) * 4}] units
+#    }
 }

The strange part is that only one of my two linux machines has this
error (the amd64 machine) but I had the same error for awhile on my
NetBSD machine.  The NetBSD error fixed itself when I upgraded a few
(Continue reading)

Donald G Porter | 7 Oct 20:15
Favicon

Re: MouseWheel binding bug in listbox and text widgets?

walt wrote:
> /usr/lib64/tk8.4/tk.tcl: no event type or button # or keysym
> no event type or button # or keysym
>     while executing
> "bind Text <MouseWheel> {
>         %W yview scroll [expr {- (%D / 120) * 4}] units
>     }"

> Any idea what's going wrong?

You've hit Tk Bug 2010422.

https://sourceforge.net/tracker/index.php?func=detail&aid=2010422&group_id=12997&atid=112997

Your system has a very recent release of X11 from X.org.  That release
broke interface compatibility, so you also must get the very latest
release of Tk, 8.5.4, that's been modified to account for that.

In the future, issues like this are better raised in the Tracker.

--

-- 
| Don Porter          Mathematical and Computational Sciences Division |
| donald.porter@...             Information Technology Laboratory |
| http://math.nist.gov/~DPorter/                                  NIST |
|______________________________________________________________________|

-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
(Continue reading)


Gmane