android - Change text colour of SwitchCompat -
how can change text colour of switchcompat?i showing on , off text in switchcompat , want change text colour white.
<android.support.v7.widget.switchcompat android:id="@+id/switchttodisableorders" android:layout_width="wrap_content" android:layout_height="wrap_content" android:gravity="right" android:padding="5dp" android:layout_marginright="10dp" android:checked="true" android:texton="on" android:textoff="off" app:showtext="true" /> <style name="theme.mainactivity" parent="theme.appcompat.light.darkactionbar"> <!-- set appcompat’s color theming attrs --> <item name="windowactionbar">false</item> <item name="android:actionmenutextappearance">@style/mymenutextappearance</item> <item name="windownotitle">true</item> <item name="android:textstyle">normal</item> <item name="colorcontrolnormal">@color/colorcontrolnormal</item> <item name="android:textallcaps">false</item> <item name="colorcontrolactivated">@color/greencompleted</item> <item name="actionmenutextcolor">@color/white</item> <item name="coloraccent">@color/greenaccepted</item> <item name="colorswitchthumbnormal">@color/red</item> <item name="android:statusbarcolor" tools:targetapi="lollipop">@color/status_bar_darker_blue</item> </style>
Comments
Post a Comment