How to change the color of the text upon highlighting it? Here is what I have tried:
edittext_text_color.xml:
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_selected="true" android:color="#FFFFFF"/>
<item android:state_selected="false" android:color="@color/custom_blue"/>
</selector>
some_layout.xml:
<org.holoeverywhere.widget.EditText
android:id="@+id/editText1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="right"
android:layout_margin="5dp"
android:background="@android:drawable/editbox_background_normal"
android:ems="10"
android:gravity="right"
android:inputType="textPersonName"
android:textColor="@drawable/edittext_text_color"
android:textCursorDrawable="@null">
Normal state:
Highlight state:
What I want upon highlighting the text: