Skip to content

Instantly share code, notes, and snippets.

@Alexander-Prime
Created September 20, 2014 19:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Alexander-Prime/427c3d58e871598041cc to your computer and use it in GitHub Desktop.
Save Alexander-Prime/427c3d58e871598041cc to your computer and use it in GitHub Desktop.
<!--attrs.xml-->
<resources>
<attr name="primaryColor" format="color" />
</resources>
<!--themes.xml-->
<!-- Other themes may inherit from AppTheme and define their own primaryColor -->
<style name="AppTheme" parent="android:Theme.Holo.Light.DarkActionBar">
<item name="android:actionBarStyle">@style/actionBar</item>
<item name="primaryColor">@color/primary_500</item>
<!-- ... -->
</style>
<!--styles_meta.xml-->
<style name="actionBar" parent="android:Widget.Holo.Light.ActionBar.Solid.Inverse">
<item name="android:background">@drawable/bkg_actionbar</item>
<!-- ... -->
</style>
<!--bkg_actionbar.xml-->
<shape android:shape="rectangle" xmlns:android="http://schemas.android.com/apk/res/android">
<solid android:color="?attr/primaryColor" />
</shape>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment