Search code examples
androiduser-interfaceuser-experienceseekbar

How can I remove default attributes from Android views when loaded from XML?


I am working on an app that uses some basic view types, but I find the default attributes extremely ugly in Android (for example, a bright yellow SeekBar). I can get the basic seekbar if I create it from code, using only the context parameter, but I would like to know if there is a way to do this inside an XML Layout file. Is there an attribute I can set that will remove all default attributes - such as android:style="@null"?


Solution

  • There are two right answers. The first is to set the theme, such as how it is done for How to change android indeterminate ProgressBar color?. The second option is to set the progress and thumb attributes as discussed in Seek bar, change path color from yellow to white