Reputation: 1619
I want an image below an EditText so that it give me a look that I am actually writing on image. Forexample a cursor showing on the image.Can anybody help me?
Upvotes: 0
Views: 202
Reputation: 2824
You can do as Android Killer told or you can use a relative layout then place a imageview and then place edittext before the imageview. Code will be like
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".EventActivity" >
<ImageView
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="#CCFFCC"/>
<EditText
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="#00000000"
/>
</RelativeLayout>
Upvotes: 0
Reputation: 18489
First of all you can set an image as background of Edittext
secondly you can use frameLayout like this
<FrameLayout
......
...... >
<ImageView
.....
....../>
<EditText
....
..../>
</FrameLayout>
Upvotes: 1