布局背景颜色与文本不同

时间:2020-06-08 15:41:53

标签: android android-layout android-styles

<resources>
    <style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar">
        <!-- Customize your theme here. -->
        <item name="android:textColor">@color/text</item>
        <item name="android:textColorPrimaryDisableOnly">@color/textDisabled</item>
        <item name="android:background">@color/background</item>
        <item name="textColorAlertDialogListItem">@color/text</item>
        <item name="android:textColorAlertDialogListItem">@color/text</item>
        <item name="android:textColorHint">@color/text</item>
        <item name="android:textColorPrimary">@color/text</item>
        <item name="android:textColorSecondary">@color/text</item>
        <item name="android:textColorTertiary">@color/text</item>
        <item name="colorAccent">@color/text</item>
    </style>
</resources>

    <androidx.appcompat.widget.Toolbar
        android:id="@+id/settings_toolbar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:title="Settings"
        app:titleTextColor="@color/text"
        android:background="@color/toolbarBackground"
        app:navigationIcon="?attr/homeAsUpIndicator"
        >
    </androidx.appcompat.widget.Toolbar>

正在生产

enter image description here

0 个答案:

没有答案