3

here is my layout code:

<EditText
     android:id="@+id/trade_num_et"
     android:layout_width="match_parent"
     android:layout_height="wrap_content"
     android:gravity="center_vertical|right"
     android:hint="@string/input_num"
     android:inputType="number"
     android:padding="5dp"
     android:background="@color/transparent"
     android:textColor="@color/white"
     android:textColorHint="@color/gray"
      android:textSize="@dimen/font_52" >
</EditText>

So how can I put set the cursor to the right of the HintText?Thank you~

Darcy
  • 61
  • 4
  • possible duplicate of [Setting cursor to the right on an EditText with HINT Gravity to center](http://stackoverflow.com/questions/22694800/setting-cursor-to-the-right-on-an-edittext-with-hint-gravity-to-center) – duggu Oct 30 '14 at 09:16
  • I don't think that this can be done but check out this accepted answer on SO http://stackoverflow.com/questions/22562959/how-to-set-the-cursor-to-the-right-edittext – Mukesh Rana Oct 30 '14 at 09:29
  • @Duggu I dont think they are the same situation. – Darcy Oct 30 '14 at 10:02
  • @Mukesh Rana I have checked that before,but it cannot work.. – Darcy Oct 30 '14 at 10:03
  • So I don't think this can be possible.. :( @Darcy – Mukesh Rana Oct 30 '14 at 10:06

1 Answers1

0
            <EditText
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:background="@null"
                android:gravity="left|center_vertical"
                android:hint="@string/search_user"
                android:lines="1"
                android:maxLength="30"
                android:singleLine="true"
                android:textCursorDrawable="@null"
                android:textSize="@dimen/text_size_16" />