Google 致力于为黑人社区推动种族平等。查看具体举措

AppCompatMultiAutoCompleteTextView

open class AppCompatMultiAutoCompleteTextView : MultiAutoCompleteTextView, TintableBackgroundView
kotlin.Any
   ↳ android.view.View
   ↳ android.widget.TextView
   ↳ android.widget.EditText
   ↳ android.widget.AutoCompleteTextView
   ↳ android.widget.MultiAutoCompleteTextView
   ↳ androidx.appcompat.widget.AppCompatMultiAutoCompleteTextView

A MultiAutoCompleteTextView which supports compatible features on older version of the platform, including:

  • Supports R.attr#textAllCaps style attribute which works back to Gingerbread.
  • Allows dynamic tint of its background via the background tint methods in androidx.core.view.ViewCompat.
  • Allows setting of the background tint using R.attr#backgroundTint and R.attr#backgroundTintMode.

This will automatically be used when you use MultiAutoCompleteTextView in your layouts. You should only need to manually use this class when writing custom views.

Summary

Public constructors
<init>(@NonNull context: Context)

<init>(@NonNull context: Context, @Nullable attrs: AttributeSet?)

<init>(@NonNull context: Context, @Nullable attrs: AttributeSet?, defStyleAttr: Int)

Public methods
open InputConnection!

open Unit
setBackgroundDrawable(@Nullable background: Drawable?)

open Unit
setBackgroundResource(@DrawableRes resId: Int)

open Unit
setDropDownBackgroundResource(@DrawableRes resId: Int)

open Unit
setTextAppearance(context: Context!, resId: Int)

Protected methods
open Unit

Public constructors

<init>

AppCompatMultiAutoCompleteTextView(@NonNull context: Context)

<init>

AppCompatMultiAutoCompleteTextView(
    @NonNull context: Context,
    @Nullable attrs: AttributeSet?)

<init>

AppCompatMultiAutoCompleteTextView(
    @NonNull context: Context,
    @Nullable attrs: AttributeSet?,
    defStyleAttr: Int)

Public methods

onCreateInputConnection

open fun onCreateInputConnection(outAttrs: EditorInfo!): InputConnection!

setBackgroundDrawable

open fun setBackgroundDrawable(@Nullable background: Drawable?): Unit

setBackgroundResource

open fun setBackgroundResource(@DrawableRes resId: Int): Unit

setDropDownBackgroundResource

open fun setDropDownBackgroundResource(@DrawableRes resId: Int): Unit

setTextAppearance

open fun setTextAppearance(
    context: Context!,
    resId: Int
): Unit

Protected methods

drawableStateChanged

protected open fun drawableStateChanged(): Unit