setText

open fun setText(resId: Int)

Sets the text to be displayed using a string resource identifier.

Parameters

resId

the resource identifier of the string resource to be displayed


open fun setText(resId: Int, type: TextView.BufferType)

Sets the text to be displayed using a string resource identifier and the TextView.BufferType.

Parameters

resId

the resource identifier of the string resource to be displayed

type

a TextView.BufferType which defines whether the text is stored as a static text, styleable/spannable text, or editable text


open fun setText(text: CharSequence?)

Sets the text to be displayed.

Parameters

text

text to be displayed


open fun setText(text: CharSequence?, type: TextView.BufferType)

Sets the text to be displayed and the TextView.BufferType.

Parameters

text

text to be displayed

type

a TextView.BufferType which defines whether the text is stored as a static text, styleable/spannable text, or editable text

See also