Reputation: 729
I am creating an application of light in which i am displaying image of light. On light i am changing the brightness of light. If i set my slider minimum and maximum value as
slider.minimumValue = -100;
slider.maximumValue = 100;
then slider shows marker at 0th position which displays as in center.But now my slider initial and maximum value has been changed as
slider.minimumValue = 0;
slider.maximumValue = 100;
I want my slider marker should be initially at 100th position of slider i.e. on the top position of slider.
Please help me to solve this problem.
Upvotes: 4
Views: 3797
Reputation: 1145
Try setting value of slider:
initialization slider:
slider.value = 5.0;
minimum value:
slider.minimumValue = 0.0;
maximum value:
slider.maximumValue = 100.0;
Upvotes: 0