Fixed
Status Update
Comments
al...@android.com <al...@android.com>
ch...@google.com <ch...@google.com>
ch...@google.com <ch...@google.com> #2
Can you provide the below requested information to better understand the issue:
Steps to reproduce
What steps do others need to take in order to reproduce the issue themselves?
Please provide sample application or apk to reproduce the issue.
Also kindly mention the steps to reproduce the issue using the sample application or apk.
Frequency
How frequently does this issue occur? (e.g 100% of the time, 10% of the time)
Expected output
What do you expect to occur?
Current output
What do you see instead?
Steps to reproduce
What steps do others need to take in order to reproduce the issue themselves?
Please provide sample application or apk to reproduce the issue.
Also kindly mention the steps to reproduce the issue using the sample application or apk.
Frequency
How frequently does this issue occur? (e.g 100% of the time, 10% of the time)
Expected output
What do you expect to occur?
Current output
What do you see instead?
Description
Version used: 24.2.0
Theme used: Theme.Design
Devices/Android versions reproduced on: Sony Xperia Z1 Compact
Since TextView (as opposed to AppCompatTextView) does not support ColorStateLists with theme attribute references below API 23 the following code always fails:
TextInputLayout.java:561
mErrorView.setTextAppearance(getContext(), mErrorTextAppearance);
Caused by:
TextInputLayout.java:559
mErrorView = new TextView(getContext());
Suggested fix:
TextInputLayout.java:559
mErrorView = new AppCompatTextView(getContext());
---
Additional resources:
design_error.xml
<selector xmlns:android="
<item android:state_enabled="false" android:color="?android:attr/textColorTertiary"/>
<item android:color="?attr/textColorError"/>
</selector>
values.xml
<style name="TextAppearance.Design.Error" parent="TextAppearance.AppCompat.Caption">
<item name="errorTextAppearance">@style/TextAppearance.Design.Error</item>
...
</style>