Closed vgartner closed 6 years ago
They dont supposed to change :-)
You should track I think ‘value’. min and max are the bounderies within min and max operates.
Op 28 mrt. 2018 om 04:35 heeft Vilson Cristiano Gärtner notifications@github.com het volgende geschreven:
When tracking the thumbs, the values of MinValue and MaxValue properties doesn't get updated. They always remain 0 and 100.
How to reproduce: 1 - Put a component on the form 2 - onChange event, add code: ShowMessage('valores: ' + FloatToStr(ALRangeTrackBar1.MinValue) + ', ' + FloatToStr(ALRangeTrackBar1.MaxValue) );
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.
As Spelt say, MinValue and MaxValue don't get updated when tracking the thumbs, they are here just to define the boundary. you should use "Value" instead ...
Hi guys, thanks for your quick reply!
But sorry, I didn't get it. ;-) If a component has a range selector, I think it should be possible to obtain the range of values, not? "Value" property in this case only returns the min selected value, not both.
I have played around with the component in design time and runtime, and noticed different behaviors.
In design time, "min" and "max" properties are used to set the boundaries. If I set "MinValue" and "MaxValue" the thumbs are repainted to the new location, reflecting the properties' values. Supposing that Max=100. When MaxValue=100, the thumb is located on the end of the selector. But when I change MaxValue=80 the thumbs are repainted to this new position, no more on the final. The same occurs with Mix.
Thus, in runtime, I guess that changing the thumbs position would update the values on MaxValue and MinValue properties. But actually what happens, is that "MinValue" and "MaxValue" just returns the same values of "Min" and "Max" properties. So I question myself what's the purpose of MinValue and MaxValue...?
Please don't get my message wrong, I just want to contribute, I'm just comparing the behavior with other range selector components... ;-)
Thank you. Best regards.
Sorry i was tired, yes maxValue return the value of the thumb on the right and minValue the value of the thumb on the left (I confuse with min/max that are the boundary)
yes at runtime changing the thumbs position must update the values on MaxValue and MinValue properties. With version of delphi do you have ?
No problem at all... ;-) My version is 10.2 Update 1
Thank you. Best regards.
I update the TALRangeTrackBar ... something was changed from berlin to tokyo. now it's must work!
I can confirm it's working on Tokyo 10.2.3. Thank you.
When tracking the thumbs, the values of MinValue and MaxValue properties doesn't get updated. They always remain 0 and 100.
How to reproduce: 1 - Put a component on the form 2 - onChange event, add code: ShowMessage('valores: ' + FloatToStr(ALRangeTrackBar1.MinValue) + ', ' + FloatToStr(ALRangeTrackBar1.MaxValue) );