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

Home » Public Forums » archive » Draw Widget Object Graphics Scrolling, Confused
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Draw Widget Object Graphics Scrolling, Confused [message #72041] Tue, 03 August 2010 13:00 Go to next message
j.coenia@gmail.com is currently offline  j.coenia@gmail.com
Messages: 36
Registered: December 2008
Member
I want to scroll through a zoomed object graphics scene bigger than
the viewport by dragging draw widget scrollbars. This works if RETAIN
= 2, but performance is too slow, which is why it is not recommended
in the documentation.

If RETAIN is 0 or 1, the view only redraws itself *after* I release
the scrollbars, so I can't really interactively scroll through my
object graphics. While I'm dragging, until I release, the viewport
goes almost all white, so I can't see where I am scrolling.

I'm re-drawing with every expose or viewport event, as suggested in
the help, but these events are not generated *while* I'm dragging the
scrollbars.

How do I use the draw widget scrollbars to scroll through an object
graphics scene if RETAIN is 0, the recommended setting for object
graphics windows?

Thanks.
Re: Draw Widget Object Graphics Scrolling, Confused [message #72103 is a reply to message #72041] Mon, 09 August 2010 13:39 Go to previous message
j.coenia@gmail.com is currently offline  j.coenia@gmail.com
Messages: 36
Registered: December 2008
Member
> How about an alternative approach? A "slippy map" type of control with
> the mouse, i.e., no scrollbars, you grab the image with your mouse and move:
>
>   http://michaelgalloy.com/2006/04/15/idlgrimage-tiling-in-idl -62.html
>

The slippy map is cool, and I'll definitely use idlgrimage tiling in
the future if it increases zoom performance, but the mouse is being
used to draw ROIs on the images right now. The interface can't be too
creative -- the intended users aren't necessarily good with computers
or with mice, and they'll expect scrollbars to scroll (not turn the
screen white until released).

It seems like window scrollbar dragging should generate viewport
change events that I could use to redraw. Dr. Fanning's answer above
suggests that he thinks I should be getting these events in my
handler. I'm not, though. There must be some trick to using
scrollbars when RETAIN = 0 that I just haven't found yet.

Thanks
Re: Draw Widget Object Graphics Scrolling, Confused [message #72104 is a reply to message #72041] Mon, 09 August 2010 13:20 Go to previous message
Michael Galloy is currently offline  Michael Galloy
Messages: 1114
Registered: April 2006
Senior Member
On 8/9/10 12:04 PM, j.coenia@gmail.com wrote:
>
>> Is this because you are not getting events in your event
>> handler (seems doubtful) or because you are not updating the
>> scene in your event handler when you get a motion event?
>
> There are no events generated at all while scrolling (?), only when
> the scrollbars are released (IDL 7.1, Windows 7 32). If there is
> some switch I'm missing to turn on scrolling events so I could redraw,
> that would solve my problem.

How about an alternative approach? A "slippy map" type of control with
the mouse, i.e., no scrollbars, you grab the image with your mouse and move:

http://michaelgalloy.com/2006/04/15/idlgrimage-tiling-in-idl -62.html

This above example talks a lot about JPEG 2000 and using IDLgrWindow's
tiling capabilities, but you might be just interested in the portion of
the event handler that handles motion events.

Mike
--
www.michaelgalloy.com
Research Mathematician
Tech-X Corporation
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: iTools problem with setting isotropic in 8.0
Next Topic: Re: IDL 8.0 now available

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

Current Time: Wed Oct 08 13:38:02 PDT 2025

Total time taken to generate the page: 0.00668 seconds