How to change the hint size of TextInputLayout
In your styles.xml
<style name="TextLabel" parent="TextAppearance.Design.Hint"> <item name="android:textSize">16sp</item></style>
And then in your layout file:
<android.support.design.widget.TextInputLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginLeft="@dimen/activity_horizontal_margin" android:layout_marginRight="@dimen/activity_horizontal_margin" android:layout_marginTop="12dp" app:hintTextAppearance="@style/TextLabel" android:minHeight="30dp">
Change the TextInputLayout's app:errorTextAppearance
in XML.
<android.support.design.widget.TextInputLayout android:layout_width="wrap_content" android:layout_height="wrap_content" app:errorTextAppearance="@style/CustomTextInputLayoutStyle.ErrorTextStyle">
Where CustomTextInputLayoutStyle.ErrorTextStyle
is defined in styles.xml
as
<style name="CustomTextInputLayoutStyle.ErrorTextStyle" parent="TextAppearance.Design.Error"> <item name="android:textSize">10sp</item></style>
@Santiago MartÃnez answer only works for hints on non empty Edittext
(inside TextInputLayout
)
But for empty Edittext
, TextInputLayout
hint takes property from Edittext
textSize
.