jonhull / GradientSlider

MIT License
241 stars 29 forks source link

[Question/Help] Color only the current value of the slider #7

Open glennposadas opened 7 years ago

glennposadas commented 7 years ago

Hi @jonhull , this is a cool library. Thanks for this! I have one question though, I hope you get this and you have some time to respond to this:

Is it possible to just color the current value of the slider? Like in the image below. With your library, I can only color the min up to the max which is already a cool thing.

screen shot 2017-09-20 at 8 31 42 am

Thanks!

jonhull commented 7 years ago

Hi, It isn't possible using the built in functionality (though I will consider adding it in the future). It should be fairly easy to add yourself (if you don't want to wait for me) by adding a layer on top of the track layer with a gray background and then setting it's position as the thumb is moved (in layoutSublayersOfLayer(layer:)).

Lailan commented 6 years ago

I need too. Thanks.

momikim commented 5 years ago

Hi, any updates?

Thanks