Reputation: 23
By default, Xamarin forms Slider is from Left to Right
I have a requirement where I need this slider starting count from left and moving towards right (Cross platform Android and iOS).
Please can anyone share, how can we achieve this using Xamarin Forms?
Upvotes: 0
Views: 464
Reputation: 8174
I think one of the smartest thing you can do is to use Rotation
property
<Slider x:Name="slider"
Maximum="360"
Rotation="180"/>
It will start from Right to Left.
Upvotes: 4
Reputation: 3387
You can use the default slider but implement your logic in a reverse manner in ValueChanged Event. Also for the UI to Appear like its right to left you can set a dark colour MaximumTrackerColour and a light (white color) for MinimumTrackerColour.
Also you can use the ThumbImage as an icon "<" this will give a full look as it is right to left.
The only important point is that implementation of ValueChanged Event which should be in reverse manner.
Upvotes: 0