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

Home » Public Forums » archive » Re: IDL Slider Widget with discrete values
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: IDL Slider Widget with discrete values [message #1974 is a reply to message #1958] Tue, 19 April 1994 10:25 Go to previous messageGo to previous message
mark_cadwell is currently offline  mark_cadwell
Messages: 10
Registered: February 1994
Junior Member
In article <CoFCwC.LzB@freenet.carleton.ca>, al662@FreeNet.Carleton.CA
(Jean-Francois Pelletier) wrote:

>
>
> Hi,
>
> I'm trying to make a slider which would show (and retrurn of course)
> the following 3 values: 25, 50, 100 and nothing else.
>
> Someone from RSI told me how to make a slider which would
> only stop on these values but when I move the cursor I still
> see the other numbers. I first thought it would be quite
> easy to pass a vector containing the allowed values to the widget
> but it ain't so.
>
> Any answers or hints would be very welcomed.
>
> Jeff


The slider function is going to show the full range of integers for
whatever
range you define (which is what you want). To make it stop ONLY on
specific
values, set up some logic in your slider callback to set the slider value
to
the closest discrete value you want to display. For example; if the
slider
was moved to a value of 18, have your callback set the slider value to 25.
If
the slider was moved to 53, have your callback set the slider value to 50.
(You
get the idea.) Hope this helps.
--
************************************
mark_cadwell@qmail4.trw.sp.com
Redondo Beach, CA
************************************
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: Plotting Color Strips - thermograms.
Next Topic: Why is comp.lang.idl-pvwave unthreaded?

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

Current Time: Sun Oct 12 02:04:44 PDT 2025

Total time taken to generate the page: 1.48659 seconds