Loading docs/html/guide/topics/ui/actionbar.jd +8 −8 Original line number Original line Diff line number Diff line Loading @@ -1427,7 +1427,7 @@ href="#ActionView">action views</a>. (Added in API level 14.)</dd> </style> </style> <!-- style for the action bar tab text --> <!-- style for the action bar tab text --> <style name="CustomTabTextStyle"> <style name="CustomTabTextStyle" parent="@android:style/TextAppearance.Holo"> <item name="android:textColor">#2456c2</item> <item name="android:textColor">#2456c2</item> </style> </style> </resources> </resources> Loading @@ -1443,8 +1443,7 @@ action bar styles you want to change without re-implementing the styles you want manifest file like this:</p> manifest file like this:</p> <pre> <pre> <application android:theme="@style/CustomActivityTheme" <application android:theme="@style/CustomActivityTheme" ... /> ... /> </pre> </pre> <p>For more information about using style and theme resources in your application, read <a <p>For more information about using style and theme resources in your application, read <a Loading @@ -1463,7 +1462,7 @@ android:backgroundStacked}. If you override these action bar styles, be sure tha parent action bar style such as {@link android.R.style#Widget_Holo_ActionBar parent action bar style such as {@link android.R.style#Widget_Holo_ActionBar Widget.Holo.ActionBar}.</p> Widget.Holo.ActionBar}.</p> <p>For example, if you want to change the action bar's background, you could use the following <p>For example, if you want to change the action bar's background, you can use the following styles:</p> styles:</p> <pre> <pre> Loading @@ -1471,14 +1470,15 @@ styles:</p> <resources> <resources> <!-- the theme applied to the application or activity --> <!-- the theme applied to the application or activity --> <style name="CustomActivityTheme" parent="@android:style/Theme.Holo"> <style name="CustomActivityTheme" parent="@android:style/Theme.Holo"> <item name="android:actionBarTabTextStyle">@style/customTabTextStyle</item> <item name="android:actionBarStyle">@style/MyActionBar</item> <!-- other activity and action bar styles here --> <!-- other activity and action bar styles here --> </style> </style> <!-- style for the action bar, simply to change the background --> <!-- style for the action bar backgrounds --> <style parent="@android:style/Widget.Holo.ActionBar"> <style name="MyActionBar" parent="@android:style/Widget.Holo.ActionBar"> <item name="android:background">@drawable/ab_background</item> <item name="android:background">@drawable/ab_background</item> <item name="android:backgroundSplit">@drawable/ab_background</item> <item name="android:backgroundStacked">@drawable/ab_background</item> <item name="android:backgroundSplit">@drawable/ab_split_background</item> </style> </style> </resources> </resources> </pre> </pre> Loading Loading
docs/html/guide/topics/ui/actionbar.jd +8 −8 Original line number Original line Diff line number Diff line Loading @@ -1427,7 +1427,7 @@ href="#ActionView">action views</a>. (Added in API level 14.)</dd> </style> </style> <!-- style for the action bar tab text --> <!-- style for the action bar tab text --> <style name="CustomTabTextStyle"> <style name="CustomTabTextStyle" parent="@android:style/TextAppearance.Holo"> <item name="android:textColor">#2456c2</item> <item name="android:textColor">#2456c2</item> </style> </style> </resources> </resources> Loading @@ -1443,8 +1443,7 @@ action bar styles you want to change without re-implementing the styles you want manifest file like this:</p> manifest file like this:</p> <pre> <pre> <application android:theme="@style/CustomActivityTheme" <application android:theme="@style/CustomActivityTheme" ... /> ... /> </pre> </pre> <p>For more information about using style and theme resources in your application, read <a <p>For more information about using style and theme resources in your application, read <a Loading @@ -1463,7 +1462,7 @@ android:backgroundStacked}. If you override these action bar styles, be sure tha parent action bar style such as {@link android.R.style#Widget_Holo_ActionBar parent action bar style such as {@link android.R.style#Widget_Holo_ActionBar Widget.Holo.ActionBar}.</p> Widget.Holo.ActionBar}.</p> <p>For example, if you want to change the action bar's background, you could use the following <p>For example, if you want to change the action bar's background, you can use the following styles:</p> styles:</p> <pre> <pre> Loading @@ -1471,14 +1470,15 @@ styles:</p> <resources> <resources> <!-- the theme applied to the application or activity --> <!-- the theme applied to the application or activity --> <style name="CustomActivityTheme" parent="@android:style/Theme.Holo"> <style name="CustomActivityTheme" parent="@android:style/Theme.Holo"> <item name="android:actionBarTabTextStyle">@style/customTabTextStyle</item> <item name="android:actionBarStyle">@style/MyActionBar</item> <!-- other activity and action bar styles here --> <!-- other activity and action bar styles here --> </style> </style> <!-- style for the action bar, simply to change the background --> <!-- style for the action bar backgrounds --> <style parent="@android:style/Widget.Holo.ActionBar"> <style name="MyActionBar" parent="@android:style/Widget.Holo.ActionBar"> <item name="android:background">@drawable/ab_background</item> <item name="android:background">@drawable/ab_background</item> <item name="android:backgroundSplit">@drawable/ab_background</item> <item name="android:backgroundStacked">@drawable/ab_background</item> <item name="android:backgroundSplit">@drawable/ab_split_background</item> </style> </style> </resources> </resources> </pre> </pre> Loading