Customize theme's colors

Customize theme's colors - Hello Friend GENERAL INFO FOR ANDROID DEVELOPMENT, In the article you read this time with the title Customize theme's colors, We have prepared this article for you to read and retrieve information there in. Hopefully the contents of postings Artikel Material Design, We write this you can understand. Alright, good read.

The Title : Customize theme's colors
link : Customize theme's colors

Read also


Customize theme's colors


Last example show how to Apply Material Theme (with default color) to Activity. The video show how to further custom the theme colors.


Edit values/styles.xml to modify style of "AppTheme2", adding various color defination.
<resources>

<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/colorPrimary</item>
<item name="colorPrimaryDark">@color/colorPrimaryDark</item>
<item name="colorAccent">@color/colorAccent</item>
</style>

<style name="AppTheme2" parent="android:Theme.Material">
<item name="android:colorPrimary">@android:color/holo_orange_light</item>
<item name="android:colorPrimaryDark">@android:color/holo_orange_dark</item>
<item name="android:textColorPrimary">@android:color/holo_blue_bright</item>
<item name="android:windowBackground">@android:color/darker_gray</item>
<item name="android:navigationBarColor">@android:color/holo_green_dark</item>
</style>


</resources>


Make sure "@style/AppTheme2" is used in AndroidManifest.xml.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.blogspot.android_er.androidmultiwindow">

<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:supportsRtl="true"
android:theme="@style/AppTheme2">
<activity android:name=".MainActivity">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>

</manifest>


Reference:
Using the Material Theme



Thus Article Customize theme's colors

The End Article Customize theme's colors This time, hopefully can give benefits to all of you. well, see you in posting other articles.

You are now reading the article Customize theme's colors with the link address http://xorislogo.blogspot.com/2016/08/customize-theme-colors.html

0 Response to "Customize theme's colors"

Post a Comment