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

Home » Public Forums » archive » Re: Generating events while a button is pressed
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: Generating events while a button is pressed [message #6234] Wed, 15 May 1996 00:00 Go to previous message
David Foster is currently offline  David Foster
Messages: 341
Registered: January 1996
Senior Member
Phil Williams <williams@irc.chmcc.org> wrote:
>
> I hope someone out there can give me a hand with this one.
>
> I want to have a widget_button that generates events while the button
> remains pressed (sorta like the action of DRAG on a widget_slider) so
> that I can scroll through a stack of data, say.
>

I wrote a program to allow the user to display a series of
images in a window, one at a time, and scroll through them forward
and back. It's meant for MR medical images, so send me an email
if you'd like a copy ... it's written for a UNIX system, but it'd
be pretty easy to modify.

Basically what I did was to use little draw widgets as the "scroll
buttons". I put text in the draws to identify them. When you do
this (using /BUTTON_EVENTS of course, and set the�UVALUE of the
draw widgets to identify the events) you can use

cursor, x, y, /nowait, /device
if ( x eq -1 or !err eq 0 ) then begin
print, 'Button released'
return, 0
endif

This also lets you use all three mouse buttons, if you want to have
multiple scroll modes (by one, by page, etc).

Hope this helps.

Dave Foster
UCSD Brain Image Analysis Lab
foster@bial1.ucsd.edu
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: Parameter Passing - Error in doc ?
Next Topic: IDL DLLs built with VC++

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

Current Time: Wed Oct 08 15:34:18 PDT 2025

Total time taken to generate the page: 0.00419 seconds