I want to achieve something like this, I am able to do just TextView but with EditText adjacent to it, I am stuck.
Here is my code so far -
Drawable -
<shape xmlns:android="http://schemas.android.com/apk/res/android"
android:shape="line">
<stroke android:color="#3F51B5" android:width="2dp"/>
<padding android:top="-30dp" />
</shape>
Layout -
android:layout_width="match_parent"
android:layout_height="40dp"
android:background="@drawable/signup_screen_input_field"
android:layout_marginTop="20dp"
android:orientation="horizontal">
<TextView
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:padding="5dp"
android:text="UserName"
android:textColor="@android:color/black"/>
<EditText
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@android:color/transparent"
android:gravity="center"
android:hint="John Doe"
android:padding="5dp"
android:textColor="@android:color/white"
android:textColorHint="@android:color/white"/>
</LinearLayout>
Also my code is hacky, which isn't good.
The image of what I am trying to achieve -