How do I do this slider
I am still a beginner in programming and I am creating an object that
behaves more or less like a slider.
The slider goes this way. The dragger slides horizontally from the
coordinate x = -180px (full left) to + 180px (full right).
When the slider is full left, it has to represent the value defined by the
user and stored on the variable minValue. When the slider is full right it
has to represent tha value stored on the variable maxValue.
So, while the dragger slides from -180 to 180 pixels, it must return a
value from minValue to maxValue.
Suppose the slider is on position -32. How do I calculate the value of the
slider in the minValue/maxValue range?
Sorry about the question, but I am a beginner.
thanks.
No comments:
Post a Comment