[prjkt.io] Udzi:
Hey Guys,

im pretty new to Substratum and i'm creating a theme for my personal use. Replacing some icons and colors to make my Device (OnePlus 5T) look like i want.

So, i know how to replace values in colors.xml, drawables etc. but know i have problems replacing values in the styles.xml

Example: Google DeskClock

There is a color value in values-v22/styles.xml called "colorAccent". To change it i know i have to self-refer it to the packagename. So it goes from this

<resources>
<style name="Theme.DeskClock" parent="@style/Theme.Design.NoActionBar">
<item name="colorAccent">#ff5e97f6</item>
</style>
</resources>

to this

<resources>
<style name="Theme.DeskClock" parent="@*com.google.android.deskclock:style/Theme.Design.NoActionBar">
<item name="@*com.google.android.deskclock:colorAccent">#ff1783d8</item>
</style>
</resources>

After changing this, the App goes from (Before.jpg) to (After.jpg). And now i'm confused. I didn't change any Background Color BUT there a values in the styles.xml which defines them:

<resources>
<style name="Theme.DeskClock" parent="@style/Theme.Design.NoActionBar">
<item name="android:colorBackground">?colorPrimary</item>
<item name="android:windowBackground">?android:colorBackground</item>
<item name="android:windowContentOverlay">@null</item>
<item name="android:navigationBarColor">@android:color/black</item>
<item name="android:timePickerStyle">@style/Widget.TimePicker</item>
<item name="android:popupTheme">?popupTheme</item>
<item name="android:colorBackgroundFloating">?colorBackgroundFloating</item>
<item name="popupTheme">@style/ThemeOverlay.Popup</item>
<item name="imageButtonStyle">@style/Widget.ImageButton</item>
<item name="colorPrimary">@color/grey_900</item>
<item name="colorPrimaryDark">#66000000</item>
<item name="colorAccent">#ff5e97f6</item>
<item name="colorControlNormal">?android:textColorPrimary</item>
<item name="colorControlActivated">?android:textColorPrimary</item>
<item name="colorBackgroundFloating">#ff303030</item>
</style>
</resources>

Do i have to put them all in my styles.xml? (I don't have to to this in the colors.xml) If i do so, self-refering the values would look like this

<resources>
<style name="Theme.DeskClock" parent="@*com.google.android.deskclock:style/Theme.Design.NoActionBar">
<item name="android:colorBackground">?colorPrimary</item>
<item name="android:windowBackground">?android:colorBackground</item>
<item name="android:windowContentOverlay">@null</item>
<item name="android:navigationBarColor">@android:color/black</item>
<item name="android:timePickerStyle">@*com.google.android.deskclock:style/Widget.TimePicker</item>
<item name="android:popupTheme">?popupTheme</item>
<item name="android:colorBackgroundFloating">?colorBackgroundFloating</item>
<item name="@*com.google.android.deskclock:popupTheme">@*com.google.android.deskclock:style/ThemeOverlay.Popup</item>
<item name="@*com.google.android.deskclock:imageButtonStyle">@*com.google.android.deskclock:style/Widget.ImageButton</item>
<item name="@*com.google.android.deskclock:colorPrimary">@*com.google.android.deskclock:color/grey_900</item>
<item name="@*com.google.android.deskclock:colorPrimaryDark">#66000000</item>
<item name="@*com.google.android.deskclock:colorAccent">#ff5e97f6</item>
<item name="@*com.google.android.deskclock:colorControlNormal">?android:textColorPrimary</item>
<item name="@*com.google.android.deskclock:colorControlActivated">?android:textColorPrimary</item>
<item name="@*com.google.android.deskclock:colorBackgroundFloating">#ff303030</item>
</style>
</resources>

But then Substratum can't compile because the value for <item name="android:colorBackground">?colorPrimary</item> can't be found

What am i missing? Please enlighten me :)

Cheers