To solve the problem of style style

<style name="WindowTitleBackground">
<item name="android:background">#7f7f7f</item><!- here is the background color of the title bar ->
</style>

<style name="titlebar_style" parent="android:Theme">
<item name="android:windowTitleBackgroundStyle">@style/CustomWindowTitleBackground</item>
<item name="android:background">#ff0000</item><!- here, set the background color to red, but the background color will give rushed the title bar of the background color, which is the activity, the title bar and the content of the background color is red, how to recover for the background color of the title bar ->
</style>

Started by Tina at November 27, 2016 - 1:30 PM

Oh, this is good, I also want to know

Posted by Ingemar at December 05, 2016 - 2:12 PM

To solve it, nobody?

Posted by Tina at December 10, 2016 - 2:13 PM

The
<item name="android:windowTitleBackgroundStyle">@style/CustomWindowTitleBackground</item>       
Change
<item name="android:windowTitleBackgroundStyle">@style/WindowTitleBackground</item>       

Posted by Aaron at December 25, 2016 - 2:27 PM

Feel shy, this is when the paste paste is wrong, the source code is@style/WindowTitleBackground

Posted by Tina at December 27, 2016 - 2:28 PM

I define a android:theme= "@style/titlebar_style" in the Manifest application label, it is normal, not like you said the title bar of the background color is red too. You look elsewhere are not written in a problem.

Posted by Aaron at January 02, 2017 - 3:22 PM

Your layout is not a problem.

Posted by Spencer at January 05, 2017 - 3:01 PM