Reputation: 7065
Using TextInputEditText
inside a TextInputLayout
in an Android layout xaml, it's possible to create Matrial style text input fields with 'fly up' hint text which moves out of the way as you start typing. How can the hint be made to appear further above the inputted text than it does by default?
Edit: You asked for pictures...
Upvotes: 0
Views: 2048
Reputation: 39191
You can do this rather simply by putting a top padding on the TextInputEditText
. For example:
<android.support.design.widget.TextInputLayout
android:layout_width="match_parent"
android:layout_height="wrap_content">
<android.support.design.widget.TextInputEditText
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:paddingTop="15dp" />
</android.support.design.widget.TextInputLayout>
Upvotes: 1