Make tab text and indicator themeable

This commit is contained in:
Thialfihar 2015-06-26 15:16:34 +02:00
parent 0d1d6542ea
commit 8227db3778
5 changed files with 15 additions and 9 deletions

View file

@ -17,8 +17,8 @@
android:layout_width="match_parent"
android:layout_height="?attr/actionBarSize"
android:background="?attr/colorPrimary"
android:textColor="@color/tab_text"
app:pstsTextColorSelected="@color/tab_text_selected"
app:pstsIndicatorColor="@color/tab_indicator" />
android:textColor="?attr/colorTabText"
app:pstsTextColorSelected="?attr/colorTabTextSelected"
app:pstsIndicatorColor="?attr/colorTabIndicator" />
</RelativeLayout>

View file

@ -75,7 +75,7 @@
android:layout_marginEnd="48dp"
android:text=""
tools:text="My Key"
android:textColor="@color/tab_text"
android:textColor="?attr/colorTabText"
android:textAppearance="?android:attr/textAppearanceSmall"
android:layout_above="@+id/toolbar2" />

View file

@ -14,5 +14,8 @@
<attr name="colorText" format="color" />
<attr name="colorBrightToolbar" format="color" />
<attr name="colorCardViewBackground" format="color" />
<attr name="colorTabText" format="color" />
<attr name="colorTabTextSelected" format="color" />
<attr name="colorTabIndicator" format="color" />
</declare-styleable>
</resources>

View file

@ -9,11 +9,6 @@
<color name="key_flag_orange">#ff9800</color>
<color name="key_flag_green">#7bad45</color>
<!-- tabs -->
<color name="tab_text">#70FFFFFF</color>
<color name="tab_text_selected">#FFFFFF</color>
<color name="tab_indicator">#FFFFFF</color>
<color name="password_strength_low">#f44336</color>
<color name="password_strength_medium">#ff9800</color>
<color name="password_strength_high">#7bad45</color>

View file

@ -12,6 +12,10 @@
<item name="colorFabBackground">#b2000000</item>
<item name="colorFabText">#fafafa</item>
<item name="colorTabText">#70ffffff</item>
<item name="colorTabTextSelected">#ffffff</item>
<item name="colorTabIndicator">#ffffff</item>
<item name="colorEmphasis">#2196f3</item>
<item name="colorButtonRow">#33cccccc</item>
<item name="colorLogBackground">#cecbce</item>
@ -41,6 +45,10 @@
<item name="colorFabBackground">#b2000000</item>
<item name="colorFabText">#fafafa</item>
<item name="colorTabText">#70ffffff</item>
<item name="colorTabTextSelected">#ffffff</item>
<item name="colorTabIndicator">#ffffff</item>
<item name="colorEmphasis">#2196f3</item>
<item name="colorButtonRow">#33cccccc</item>
<item name="colorLogBackground">#303030</item>