The thumb for my Switch-button seems to get skewed(for on&off state). There were similar problems on github, but those were for people making libraries to support Switch
I had the same requirement. I checked Android code and found that
This makes really hard to make a circle thumb.
But if you specify the thumb drawable as a layer drawable for the sole reason to be able to specify padding for the single layer of the drawable, you can get the desired effect.
Thumb selector:
-
-
I set the on and off text of switch to empty (actually to "" to prevent warning about empty resource).
track:
-
-
Switch style:
And finally, the dimens:
30dp
15dp
2dp
So the only 'tricky' thing is to keep height = radius * 2.