Re: [ROOT] TSlider (non)updates.

From: Fons Rademakers (Fons.Rademakers@cern.ch)
Date: Thu Aug 30 2001 - 11:40:05 MEST


Hi Brett,

   ForceRedraw() only works for TG classes.
Just send me a little example program.

Cheers, Fons.


Brett Viren wrote:
> 
> Hi,
> 
> I am using TSliders via the SetObject()/ExecuteEvent() method.  The
> object I set is a simple TObject which translates from the TSlider
> range to an internal Range object.  In response to Rt signals from
> this Range object a TPad is Range()d.
> 
> The problem I am having is that while my TPad is smoothly Ranged, the
> TSlider itself does not change size or possition until after the mouse
> button is released.
> 
> This same problem happened with TGDoubleSliders in guiviewer.  To fix
> it, Fons added TGClient::ForceRedraw() in the method that handles the
> TGDoubleSlider action.  Following that, I tried adding
> gClient->ForceRedraw() in my ExecuteEvent, but it fails to update the
> TSlider's position.  I also tried calling Modified() and Update() on
> the TSlider, but this also failed.
> 
> Is there some way I can cause the TSlider's graphical representation
> to stay in sync with its values?
> 
> If the solution isn't obvious, I'll try to reproduce the problem in
> some self contained code.
> 
> Thanks,
> -Brett.

-- 
Org:    CERN, European Laboratory for Particle Physics.
Mail:   1211 Geneve 23, Switzerland
E-Mail: Fons.Rademakers@cern.ch              Phone: +41 22 7679248
WWW:    http://root.cern.ch/~rdm/            Fax:   +41 22 7679480



This archive was generated by hypermail 2b29 : Tue Jan 01 2002 - 17:50:58 MET