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 屬性授權中所述的詞彙使用。

適用於

另請參閱