From jfox at mcmaster.ca  Fri Jun  6 13:31:19 2003
From: jfox at mcmaster.ca (John Fox)
Date: Fri Jun  6 18:31:36 2003
Subject: [Rd] stuck tcltk scrollbars under Windows XP
In-Reply-To: <00d801c32c34$5e1ee370$0201a8c0@MARC>
References: <00d701c32c33$4fc9df10$0201a8c0@MARC>
Message-ID: <5.1.0.14.2.20030606122929.01eac500@mcmail.cis.mcmaster.ca>

At 09:03 AM 6/6/2003 -0500, Marc Schwartz wrote:
>SNIP
>
> >...
> >tkbind(window2, "<Return>", onOK)
> >
> ># Here is the change
> >tkwm.deiconify(window2)
> >tkgrab.set(window2)
> >tkfocus(xBox)
> >tkwait.window(window2)
> >
> >Using the above code, I seem to have eliminated the scroll bar
> >problem. This is the approach that I took with the tkSelectList()
> >function which I sent to you during our offline exchange.
> >
> >Note that I have tkfocus() set to the scrollbar xBox and not to
> >window2, which results in the mouse scroll wheel working, whereas it
> >does not when the focus is set to window2.
> >
> >Lastly, by using the tkwm.deiconify(...) function window2 is raised
>to
> >obtain focus.  That was a quirk that I found by experimentation.
>
>
>Quick correction:
>
>The sentence in the paragraph above should read:
>
>"Note that I have tkfocus() set to the **ListBox** xBox..."
>
>Sorry for any confusion.
>
>Marc


Dear Marc,

Thank you for the suggestions -- I'll try them out. I'd prefer to 
understand why things work as they do, for fear of introducing other 
problems. Focusing on the list box won't work for me, I think, since many 
of the Rcmdr dialogs have more than one list box.

Thanks again,
  John
-----------------------------------------------------
John Fox
Department of Sociology
McMaster University
Hamilton, Ontario, Canada L8S 4M4
email: jfox@mcmaster.ca
phone: 905-525-9140x23604
web: www.socsci.mcmaster.ca/jfox


[Rd] stuck tcltk scrollbars under Windows XP
John Fox