I want to create several button styles instyles.xml
. I want to support API 19 and higher so I would like to create button styles for both API. What I am doing:
I've created custom style in stylex.xml
:
<style name="AppTheme.ButtonGreen" parent="android:Widget.Holo.Button">
<iten name="android:textColor">@color/accent</iten>
<item name="android:background">@color/primary</item>
</style>
In facy the color does not change. Can you help me with theming and give some basic attributes like: background color, text color etc. cause those does not work (only font color works).
I have also implemented style for v21 in styles (v21).xml
:
<style name="AppTheme.ButtonGreen" parent="android:Widget.Material.Button">
<item name="android:textColor">@color/primary</item>
<item name="android:background">@color/text_icons</item>
</style>
But here I need font color, background color, elevation, font size etc. (only font color works).
Generally I guess I am doing something wrong. Can you guys help me style those buttons for different API?