Added in API level 1

CheckedTextView


open class CheckedTextView : TextView, Checkable
kotlin.Any
   ↳ android.view.View
   ↳ android.widget.TextView
   ↳ android.widget.CheckedTextView

An extension to TextView that supports the Checkable interface and displays.

This is useful when used in a ListView where the setChoiceMode has been set to something other than CHOICE_MODE_NONE.

Summary

XML attributes
android:checkMark Drawable used for the check mark graphic.
android:checked Indicates the initial checked state of this text.
Inherited XML attributes
Inherited constants
Public constructors

CheckedTextView(context: Context!, attrs: AttributeSet!)

CheckedTextView(context: Context!, attrs: AttributeSet!, defStyleAttr: Int)

CheckedTextView(context: Context!, attrs: AttributeSet!, defStyleAttr: Int, defStyleRes: Int)

Public methods
open Unit

This function is called whenever the view hotspot changes and needs to be propagated to drawables or child views managed by the view.

open CharSequence!

Return the class name of this object to be used for accessibility purposes.

open Drawable!

Gets the checkmark drawable

open BlendMode?

Returns the blending mode used to apply the tint to the check mark drawable, if specified.

open ColorStateList?

Returns the tint applied to the check mark drawable, if specified.

open PorterDuff.Mode?

Returns the blending mode used to apply the tint to the check mark drawable, if specified.

open Boolean

open Unit

Call Drawable.jumpToCurrentState() on all Drawable objects associated with this view.

open Unit

Hook allowing a view to re-apply a representation of its internal state that had previously been generated by onSaveInstanceState.

open Unit
onRtlPropertiesChanged(layoutDirection: Int)

Called when any RTL property (layout direction or text direction or text alignment) has been changed.

open Parcelable?

Hook allowing a view to generate a representation of its internal state that can later be used to create a new instance with that same state.

open Unit

Set the check mark to the specified drawable.

open Unit

Sets the check mark to the drawable with the specified resource ID.

open Unit

Specifies the blending mode used to apply the tint specified by setCheckMarkTintList(ColorStateList) to the check mark drawable.

open Unit

Applies a tint to the check mark drawable.

open Unit

Specifies the blending mode used to apply the tint specified by setCheckMarkTintList(ColorStateList) to the check mark drawable.

open Unit
setChecked(checked: Boolean)

Sets the checked state of this view.

open Unit
setVisibility(visibility: Int)

Set the visibility state of this view.

open Unit

Change the checked state of the view to the inverse of its current state

Protected methods
open Unit

This function is called whenever the state of the view changes in such a way that it impacts the state of drawables being shown.

open IntArray!

Generate the new android.graphics.drawable.Drawable state for this view.

open Unit
onDraw(canvas: Canvas)

Implement this to do your drawing.

open Boolean

If your view subclass is displaying its own Drawable objects, it should override this function and return true for any Drawable it is displaying.

Inherited functions