android - How to change colour of the thumb in seekbar? -


i have default seekbar in android app. noticed when thumb on seekbar held, turns yellow. instead, want turn blue when held. how can done? apologize if basic question, new android development. thanks.

if don't default thumb, have create own drawable, can set thumb in code like:

drawable thumb = getresources().getdrawable( r.drawable.mythumb ); seekbar mseekbar = (seekbar) findviewbyid(r.id.myseekbar); mseekbar.setthumb(thumb); 

or can set thumb in xml with:

<seekbar      ...     android:thumb="@drawable/seek_thumb" /> 

the actual drawable can image, shape, or other kind of drawable possibly desire. if want thumb change appearance when pressed, want create state list drawable.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -