Added white theme

This commit is contained in:
M66B 2022-02-19 22:30:55 +01:00
parent c2396b0ac0
commit 3032b7fe4b
5 changed files with 57 additions and 0 deletions

View File

@ -208,6 +208,9 @@ public class FragmentDialogTheme extends FragmentDialogBase {
case "black":
rgTheme.check(R.id.rbThemeBlack);
break;
case "white":
rgTheme.check(R.id.rbThemeWhite);
break;
case "black_and_white":
rgTheme.check(R.id.rbThemeBlackAndWhite);
break;
@ -306,6 +309,8 @@ public class FragmentDialogTheme extends FragmentDialogBase {
"solarized" + (dark ? "_dark" : "_light")).apply();
} else if (checkedRadioButtonId == R.id.rbThemeBlack) {
editor.putString("theme", "black").apply();
} else if (checkedRadioButtonId == R.id.rbThemeWhite) {
editor.putString("theme", "white").apply();
} else if (checkedRadioButtonId == R.id.rbThemeBlackAndWhite) {
editor.putString("theme", "black_and_white").apply();
} else if (checkedRadioButtonId == R.id.rbThemeYou) {
@ -452,6 +457,12 @@ public class FragmentDialogTheme extends FragmentDialogBase {
else
return R.style.AppThemeBlack;
case "white":
if (light)
return R.style.AppThemeGreySteelBlueLight;
else
return R.style.AppThemeWhite;
case "black_and_white":
if (light)
return R.style.AppThemeGreySteelBlueLight;

View File

@ -81,6 +81,14 @@
android:text="@string/title_setup_theme_black"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
<RadioButton
android:id="@+id/rbThemeWhite"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="6dp"
android:text="@string/title_setup_theme_white"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
<RadioButton
android:id="@+id/rbThemeBlackAndWhite"
android:layout_width="match_parent"

View File

@ -81,6 +81,14 @@
android:text="@string/title_setup_theme_black"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
<RadioButton
android:id="@+id/rbThemeWhite"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:padding="6dp"
android:text="@string/title_setup_theme_white"
android:textAppearance="@style/TextAppearance.AppCompat.Medium" />
<RadioButton
android:id="@+id/rbThemeBlackAndWhite"
android:layout_width="match_parent"

View File

@ -291,6 +291,7 @@
<string name="title_setup_theme_grey">Grey</string>
<string name="title_setup_theme_solarized" translatable="false">Solarized</string>
<string name="title_setup_theme_black">Black</string>
<string name="title_setup_theme_white">White</string>
<string name="title_setup_theme_black_and_white">Black and white</string>
<string name="title_setup_theme_you" translatable="false">Material You</string>

View File

@ -410,6 +410,31 @@
<item name="colorDrawerBackground">@color/black</item>
</style>
<style name="AppThemeWhite" parent="AppThemeBaseLight">
<item name="colorPrimary">@color/greyPrimary</item>
<item name="colorPrimaryDark">@color/greyPrimaryDark</item>
<item name="colorAccent">@color/greyPrimary</item>
<item name="colorUnreadHighlight">@color/greyPrimaryDark</item>
<item name="colorEncrypt">@color/colorEncryptDark</item>
<item name="colorDrawerBackground">@color/white</item>
<item name="colorFabBackground">@color/greyPrimary</item>
<item name="colorInfoForeground">@color/white</item>
<item name="colorInfoBackground">@color/greyPrimary</item>
<item name="actionBarTheme">@style/WhiteActionBar</item>
</style>
<style name="WhiteActionBar" parent="Theme.AppCompat.Light.DarkActionBar">
<item name="android:background">@color/white</item>
<item name="android:titleTextStyle">@style/ActionBarTitle</item>
<item name="android:textColor">@color/black</item>
</style>
<style name="AppThemeBlackAndWhite" parent="AppThemeBaseDark">
<item name="themeName">black</item>
<item name="colorPrimary">@color/blackAndWhitePrimary</item>
@ -461,6 +486,10 @@
<item name="colorInfoBackground">@color/greyPrimary</item>
</style>
<style name="ActionBarTitle" parent="Widget.AppCompat.ActionBar">
<item name="android:textColor">@color/black</item>
</style>
<style name="AppThemeGreySteelBlueDark" parent="AppThemeBaseDark">
<item name="themeName">black</item>
<item name="colorPrimary">@color/greyPrimary</item>