user310291
user310291

Reputation: 38180

How to create a custom knob for iOS slider?

Is there a way to subclass just the knob for iOS slider (if yes, how: can you point to a tutorial) or does one has to create the whole slider from scratch ?

Upvotes: 0

Views: 3430

Answers (1)

bneely
bneely

Reputation: 9093

Apple's documentation for UISlider indicates that the thumb is customizable. You need to set the currentThumbImage property and override - (CGRect)thumbRectForBounds:(CGRect)bounds trackRect:(CGRect)rect value:(float)value in a UISlider subclass.

Upvotes: 5

Related Questions