comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: Can't set input focus to draw widget
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: Can't set input focus to draw widget [message #35206 is a reply to message #35169] Thu, 15 May 2003 10:47 Go to previous message
David Fanning is currently offline  David Fanning
Messages: 11724
Registered: August 2001
Senior Member
James Rioux (jamesriouxctm@hotmail.com) writes:

> I'm trying to use a draw widget to capture keyboard events in IDL 5.6
> for Macintosh OS X. The code I have written works fine on a PC but
> when I move it over to the Macintosh I can't get the draw widget to
> receive input focus programmatically, even though a text widget on the
> same base can get focus.
>
> Specifically, the follow piece of code works properly:
> WIDGET_CONTROL, theTextWidget, /INPUT_FOCUS
> but this piece of code does nothing at all:
> WIDGET_CONTROL, theDrawWidget, /INPUT_FOCUS
>
> The draw widget itself is defined as follows:
> WIDGET_DRAW(base, XSIZE=512, YSIZE=512, BUTTON_EVENTS=1,
> KEYBOARD_EVENTS=1, RETAIN=2)
> so it should be receiving input focus, and indeed, it is on a PC.
>
> I can give the draw widget focus by hitting Tab repeatedly, of course,
> but I'd rather not make the user Tab through all of the controls on
> the screen every time they want to use the keyboard for something.
>
> I am aware of JD's hidden text widget hack, but since I'd like to
> catch arrow and control keys, I don't believe that will work the way I
> want it to.
>
> Any suggestions or comments? Does Mac OS X not support keyboard input
> focus for draw widgets?

Wasn't this reported as a bug just a couple of weeks ago!?
A couple of brain cells seem to be firing, but I can't tell
if I am remembering something or if the anti-inflamatories
are causing hallucinations again. :-(

Cheers,

David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
[Message index]
 
Read Message
Read Message
Previous Topic: Can't set input focus to draw widget
Next Topic: patch update message on idlde

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Sat Oct 11 19:33:40 PDT 2025

Total time taken to generate the page: 1.05491 seconds