TextView.InputType 属性

定义

获取可编辑内容的类型。 - 或 - 使用定义的 EditorInfo#inputType常量设置内容类型。

public virtual Android.Text.InputTypes InputType { [Android.Runtime.Register("getInputType", "()I", "GetGetInputTypeHandler")] get; [Android.Runtime.Register("setInputType", "(I)V", "GetSetInputType_IHandler")] set; }
[<get: Android.Runtime.Register("getInputType", "()I", "GetGetInputTypeHandler")>]
[<set: Android.Runtime.Register("setInputType", "(I)V", "GetSetInputType_IHandler")>]
member this.InputType : Android.Text.InputTypes with get, set

属性值

属性

注解

属性 getter 文档:

获取可编辑内容的类型。

适用于 . 的 android.widget.TextView.getInputType()Java 文档

属性 setter 文档:

使用定义的 EditorInfo#inputType常量设置内容类型。 这将负责通过调用 #setKeyListener(KeyListener)来更改密钥侦听器以匹配给定内容类型。 如果给定内容类型为 EditorInfo#TYPE_NULL 软键盘,将不会显示此文本视图的软键盘。

请注意,如果更改EditorInfo#TYPE_TEXT_FLAG_MULTI_LINE输入类型的标志,将修改显示的最大行数(请参阅#setMaxLines(int))。

适用于 . 的 android.widget.TextView.setInputType(int)Java 文档

本页的某些部分是根据 Android 开放源代码项目创建和共享的工作进行的修改,并根据 Creative Commons 2.5 属性许可证中所述的术语使用。

适用于

另请参阅