Android edittext 输入时带下划线 [英] Android edittext is underlined when typing

查看:33
本文介绍了Android edittext 输入时带下划线的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在 Android 中输入编辑文本字段时,我需要删除下划线.对于名字,编辑文本的第一个字母应该是大写的,所以我已经给出了 textCapSentences,但在我的例子中,我在 edittext 字段中看到了下划线.如何删除它?

I need to removed underline when type in edit text field in Android. For the first name edit text first letter should be capital so that I have given textCapSentences, but in my case I see underline in edittext fields. how to remove that?

textFilter|textNoSuggestions|textCapSentences

这是我的名字编辑文本:

its my first name edit text:

    <EditText
        android:id="@+id/signup_lname"
        android:layout_width="match_parent"
        android:layout_height="60dp"
        android:background="@color/signup_layer_bg2"
        android:ems="10"
        android:gravity="center"
        android:hint="@string/signup_lname"
        android:imeOptions="actionDone"
        android:inputType="textFilter|textNoSuggestions|textCapSentences"
        android:paddingLeft="5dp"
        android:paddingRight="5dp"
        android:singleLine="true"
        android:textColor="@android:color/white"
        android:textColorHint="@android:color/white"
        android:textCursorDrawable="@drawable/custom_cursor" />

我的屏幕:

推荐答案

android:inputType="textVisiblePassword" 禁用文本自动更正

这篇关于Android edittext 输入时带下划线的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆