Quantcast
Channel: xda-developers - Android Themes
Viewing all articles
Browse latest Browse all 4090

[Q] Overlaying different packages' resources on CM Themes

$
0
0
Hi, First of all i know i shouldn't post question here,anyways i checked out Q/A section and its like a noob trash.So if i write it there i don't think i can get an answer.

So let me tell you what i want to do..

Let's look that code snip

--------------------
<style name="TextAppearance.Holo.Widget.Switch" parent="@android:style/TextAppearance.Holo.Small">
<item name="android:textColor">#00ffffff</item>
</style>
---------------
you know red text is like getting that style from framework-res.apk and blue one is overwriting to red one's specific parts.
So,you didn't lose main stuff from red part...

That's okay for framework-res styling...

but how about working on another app packages' styles
The code snip below is from original Settings app's styles.xml
-----------------
<style name="Theme.Settings" [COLOR="rgb(46, 139, 87)"]parent="@*android:style/Theme.Holo"[/COLOR]>
<item name="android:actionBarStyle">@*android:style/Widget.Holo.ActionBar.Solid</item>
<item name="apnPreferenceStyle">@style/ApnPreference</item>
<item name="ic_menu_add">@drawable/ic_menu_add_dark</item>
<item name="ic_menu_moreoverflow">@*android:drawable/finger_print_arrow_019</item>
<item name="ic_wps">@drawable/ic_wps_dark</item>
<item name="wifi_signal">@drawable/wifi_signal_dark</item>
</style>
------------

The code below is my code which i used on cm11 theme
-------------
<style name="Theme.Settings" parent="@*android:style/Theme.Holo">

<item name="android:actionBarStyle">@style/MyActionBar</item>
</style>
------------
if i use that changed code it correctly changes things on Settings app..
But when i enter into Wifi settings app crashes because of these things

<item name="apnPreferenceStyle">@style/ApnPreference</item>
<item name="ic_menu_add">@drawable/ic_menu_add_dark</item>
<item name="ic_menu_moreoverflow">@*android:drawable/finger_print_arrow_019</item>
<item name="ic_wps">@drawable/ic_wps_dark</item>
<item name="wifi_signal">@drawable/wifi_signal_dark</item>


everything else in app works good.
So theme's wifi part will be broken if i use like above.

Let me tell you the another way,

hmm @*android:style/Theme.Holo comes from framework-res so i can easily create overlay for it but if i do that for Theme.Holo , it will change the Settings app correctly but it also will broke all other Theme.Holo used apps


I don't want both of these things.
How about overlaying settings's Theme.Settings
like that
So app won't crash and it will be themed only the settings app
-------------
<style name="Theme.Settings" parent="THEMES SETTINGS STYLE RESOURCE FROM SETTINGS APP">

<item name="android:actionBarStyle">@style/MyActionBar</item>
</style>
------------

I couldn't find something like this.
What am i supposed to do??

Viewing all articles
Browse latest Browse all 4090

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>