Re: How to set float value by TGSlider

From: Fons Rademakers (Fons.Rademakers@cern.ch)
Date: Mon Aug 10 1998 - 16:38:25 MEST


Hi Xie,

   floating point values are not directly supported by sliders.
You'll have to do a little math yourself to scale a slider position
to some floating point value and back.

Cheers, Fons.


Wei Xie wrote:
> 
> Dear Rooters,
> 
> One way to set values in a TGTextBuffer by TGSlider is to
> use its implementation "GetPosition()", as it is done in "guitest.cxx"
> in test directory.
> 
> But only integer value can be set in this way. Is there any other method
> that can set float values in a TGTextBuffer by TGSlider.
> 
> Sincerely
> 
> Xie

-- 
Org:    CERN, European Laboratory for Particle Physics.
Mail:   1211 Geneve 23, Switzerland          Phone: +41 22 7679248
E-Mail: Fons.Rademakers@cern.ch              Fax:   +41 22 7677910



This archive was generated by hypermail 2b29 : Tue Jan 04 2000 - 00:34:36 MET