material-components/material-components-android

[TextInputEditText] Several issues with typefaces in TextInputEditText (e.g.,Typeface is not applied with textPassword inputType)

Open

#584 建立於 2019年9月10日

在 GitHub 查看
 (16 留言) (13 反應) (0 負責人)Java (15,910 star) (3,023 fork)batch import
Good First IssueWidget: TextFieldbug

描述

Description: Typeface is not applied with textPassword inputType.

Expected behavior: When android:inputType="text|textPassword|textNoSuggestions" (incorrect behaviour) Screenshot_1568119309

When android:inputType="text|textNoSuggestions" (expected behaviour) Screenshot_1568119497

Source code:

        <com.google.android.material.textfield.TextInputLayout
            android:id="@+id/passwordInputAlphanumeric"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:layout_margin="@dimen/margin_padding_size_medium"
            android:theme="@style/Widget.App.TextInputLayout"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            >

            <com.google.android.material.textfield.TextInputEditText
                android:id="@+id/passwordAlphanumeric"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:hint="@string/login_hint_password"
                android:imeOptions="actionDone"
                android:inputType="text|textPassword|textNoSuggestions"
                android:maxLines="1"
                tools:ignore="Autofill,LabelFor"
                tools:text="11223344"
                />
        </com.google.android.material.textfield.TextInputLayout>


<style name="Base.TextAppearance" parent="@style/TextAppearance.AppCompat">
    <item name="android:fontFamily">@font/ubuntu_regular</item>
    <item name="fontFamily">@font/ubuntu_regular</item>
</style>

Android API version: All

Material Library version: 1.0.0

Device: Emulators

貢獻者指南