First version of dark theme

This commit is contained in:
2016-04-08 17:15:14 -04:00
parent de8018af7d
commit f0701f7b35
17 changed files with 117 additions and 44 deletions

View File

@@ -20,5 +20,5 @@
<ripple xmlns:android="http://schemas.android.com/apk/res/android"
android:color="?android:colorControlHighlight">
<item android:drawable="@color/white" />
<item android:drawable="?attr/cardBackgroundColor" />
</ripple>

View File

@@ -21,7 +21,7 @@
<ScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:background="@color/windowBackground"
android:background="?windowBackgroundColor"
android:fillViewport="true">
<LinearLayout

View File

@@ -31,10 +31,10 @@
dslv:sort_enabled="true"
dslv:track_drag_sort="false"
android:layout_width="match_parent"
android:background="@color/windowBackground"
android:background="?windowBackgroundColor"
android:paddingTop="@dimen/checkmarkHeight"
android:layout_height="match_parent"
android:divider="@color/windowBackground"
android:divider="?windowBackgroundColor"
android:dividerHeight="1dp"/>
<LinearLayout

View File

@@ -25,7 +25,7 @@
android:layout_width="20dp"
android:layout_height="20dp"
android:background="@color/transparent"
android:textColor="@color/fadedTextColor"
android:textColor="?fadedTextColor"
android:textAllCaps="true"
android:textStyle="bold"
android:textSize="10sp"/>

View File

@@ -22,7 +22,7 @@
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:background="@color/windowBackground"
android:background="?windowBackgroundColor"
android:fillViewport="true">
<LinearLayout

View File

@@ -20,15 +20,42 @@
<resources>
<style name="AppBaseTheme" parent="android:Theme.Material.Light.DarkActionBar">
<item name="android:textColor">#606060</item>
<item name="android:colorPrimary">@color/primary</item>
<item name="android:colorPrimaryDark">@color/primary_darker</item>
<item name="android:dialogTheme">@style/MyDialogStyle</item>
<item name="android:alertDialogTheme">@style/MyDialogStyle</item>
<item name="android:windowContentTransitions">true</item>
<item name="android:windowAllowEnterTransitionOverlap">true</item>
<item name="android:windowAllowReturnTransitionOverlap">true</item>
<item name="android:spinnerItemStyle">@style/dialogFormSmallText</item>
<item name="android:colorPrimary">@color/blue_grey_800</item>
<item name="android:colorPrimaryDark">@color/blue_grey_900</item>
<item name="cardBackgroundColor">@color/white</item>
<item name="windowBackgroundColor">@color/grey_200</item>
<item name="headerBackgroundColor">@color/grey_200</item>
<item name="android:textColor">#606060</item>
<item name="fadedTextColor">@color/grey_600</item>
<item name="inactiveCheckmarkColor">@color/grey_600</item>
<item name="secondaryTextColor">@color/grey_800</item>
</style>
<style name="AppBaseThemeDark" parent="android:Theme.Material">
<item name="android:dialogTheme">@style/MyDialogStyleDark</item>
<item name="android:alertDialogTheme">@style/MyDialogStyleDark</item>
<item name="android:windowContentTransitions">true</item>
<item name="android:windowAllowEnterTransitionOverlap">true</item>
<item name="android:windowAllowReturnTransitionOverlap">true</item>
<item name="android:colorPrimary">@color/grey_900</item>
<item name="android:colorPrimaryDark">@color/black</item>
<item name="cardBackgroundColor">@color/grey_800</item>
<item name="windowBackgroundColor">@color/grey_850</item>
<item name="headerBackgroundColor">@color/grey_875</item>
<item name="android:textColor">@color/grey_50</item>
<item name="fadedTextColor">@color/grey_500</item>
<item name="inactiveCheckmarkColor">@color/grey_700</item>
<item name="secondaryTextColor">@color/grey_100</item>
</style>
<style name="MyDialogStyle" parent="android:Theme.Material.Light.Dialog">
@@ -36,8 +63,14 @@
<item name="android:spinnerDropDownItemStyle">@style/dialogFormSpinnerDropDown</item>
</style>
<style name="MyDialogStyleDark" parent="android:Theme.Material.Dialog">
<item name="android:spinnerItemStyle">@style/dialogFormText</item>
<item name="android:spinnerDropDownItemStyle">@style/dialogFormSpinnerDropDown</item>
</style>
<style name="Card" parent="CardCommon">
<item name="android:elevation">1dp</item>
<item name="android:background">?attr/cardBackgroundColor</item>
</style>
<style name="About.Item.Clickable" parent="About.Item">

View File

@@ -21,7 +21,7 @@
<resources>
<style name="ListHabits.Header">
<item name="android:background">#f0f0f0</item>
<item name="android:background">?headerBackgroundColor</item>
<item name="android:elevation">2dp</item>
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">wrap_content</item>

View File

@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="utf-8"?>
<!--
~ Copyright (C) 2016 Álinson Santos Xavier <isoron@gmail.com>
~
~ This file is part of Loop Habit Tracker.
~
~ Loop Habit Tracker is free software: you can redistribute it and/or modify
~ it under the terms of the GNU General Public License as published by the
~ Free Software Foundation, either version 3 of the License, or (at your
~ option) any later version.
~
~ Loop Habit Tracker is distributed in the hope that it will be useful, but
~ WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
~ or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
~ more details.
~
~ You should have received a copy of the GNU General Public License along
~ with this program. If not, see <http://www.gnu.org/licenses/>.
-->
<resources>
<attr name="windowBackgroundColor" format="reference"/>
<attr name="cardBackgroundColor" format="reference"/>
<attr name="fadedTextColor" format="reference"/>
<attr name="headerBackgroundColor" format="reference"/>
<attr name="secondaryTextColor" format="reference"/>
<attr name="inactiveCheckmarkColor" format="reference"/>
</resources>

View File

@@ -15,15 +15,6 @@
limitations under the License.
-->
<resources>
<color name="primary">#37474f</color>
<color name="primary_darker">#263238</color>
<color name="windowBackground">#e6e6e6</color>
<color name="primaryTextColor">@color/grey_900</color>
<color name="secondaryTextColor">@color/grey_800</color>
<color name="fadedTextColor">@color/grey_600</color>
<color name="white">#ffffff</color>
<!-- Time and Date picker -->
<color name="circle_background">#f2f2f2</color>
@@ -151,8 +142,8 @@
<!--<color name="blue_grey_500">#607D8B</color>-->
<!--<color name="blue_grey_600">#546E7A</color>-->
<!--<color name="blue_grey_700">#455A64</color>-->
<!--<color name="blue_grey_800">#37474F</color>-->
<!--<color name="blue_grey_900">#263238</color>-->
<color name="blue_grey_800">#37474F</color>
<color name="blue_grey_900">#263238</color>
<!--<color name="pink_50">#FCE4EC</color>-->
<!--<color name="pink_100">#F8BBD0</color>-->
@@ -324,5 +315,10 @@
<color name="grey_600">#757575</color>
<color name="grey_700">#616161</color>
<color name="grey_800">#424242</color>
<color name="grey_850">#303030</color>
<color name="grey_875">#282828</color>
<color name="grey_900">#212121</color>
<color name="white">#ffffff</color>
<color name="black">#000000</color>
</resources>

View File

@@ -41,7 +41,7 @@
<style name="CardList">
<item name="android:layout_width">match_parent</item>
<item name="android:layout_height">wrap_content</item>
<item name="android:background">@color/windowBackground</item>
<item name="android:background">?windowBackgroundColor</item>
<item name="android:orientation">vertical</item>
</style>
@@ -102,7 +102,7 @@
<item name="android:layout_height">wrap_content</item>
<item name="android:layout_marginLeft">8dp</item>
<item name="android:layout_marginRight">8dp</item>
<item name="android:textColor">@color/fadedTextColor</item>
<item name="android:textColor">?fadedTextColor</item>
</style>
</resources>

View File

@@ -45,19 +45,19 @@
<style name="dialogFormText">
<item name="android:textSize">@dimen/regularTextSize</item>
<item name="android:textColor">@color/secondaryTextColor</item>
<item name="android:textColor">?secondaryTextColor</item>
<item name="android:layout_width">wrap_content</item>
<item name="android:layout_height">wrap_content</item>
</style>
<style name="dialogFormSmallText">
<item name="android:textSize">@dimen/smallTextSize</item>
<item name="android:textColor">@color/fadedTextColor</item>
<item name="android:textColor">?fadedTextColor</item>
</style>
<style name="dialogFormSpinnerDropDown" parent="dialogFormText">
<item name="android:padding">12dp</item>
<item name="android:textColor">@color/secondaryTextColor</item>
<item name="android:textColor">?secondaryTextColor</item>
</style>
<style name="dialogFormInput" parent="dialogFormText">
@@ -74,7 +74,7 @@
<item name="android:minWidth">100dp</item>
<item name="android:gravity">left</item>
<item name="android:paddingLeft">6dp</item>
<item name="android:textColor">@color/fadedTextColor</item>
<item name="android:textColor">?fadedTextColor</item>
</style>
<style name="dialogFormSpinner" parent="android:Widget.DeviceDefault.Light.Spinner">
@@ -83,7 +83,7 @@
<item name="android:paddingLeft">12dp</item>
<item name="android:textSize">@dimen/regularTextSize</item>
<item name="android:minWidth">400dp</item>
<item name="android:textColor">@color/secondaryTextColor</item>
<item name="android:textColor">?secondaryTextColor</item>
</style>
<style name="dialogFormRow">