Added in API level 1

TextSwitcher


open class TextSwitcher : ViewSwitcher
kotlin.Any
   ↳ android.view.View
   ↳ android.view.ViewGroup
   ↳ android.widget.FrameLayout
   ↳ android.widget.ViewAnimator
   ↳ android.widget.ViewSwitcher
   ↳ android.widget.TextSwitcher

Specialized android.widget.ViewSwitcher that contains only children of type android.widget.TextView. A TextSwitcher is useful to animate a label on screen. Whenever setText(java.lang.CharSequence) is called, TextSwitcher animates the current text out and animates the new text in.

Summary

Inherited XML attributes
Inherited constants
Public constructors
TextSwitcher(context: Context!)

Creates a new empty TextSwitcher.

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

Creates a new empty TextSwitcher for the given context and with the specified set attributes.

Public methods
open Unit
addView(child: View!, index: Int, params: ViewGroup.LayoutParams!)

Adds a child view with the specified layout parameters.

open CharSequence!

open Unit

Sets the text of the text view that is currently showing.

open Unit

Sets the text of the next view and switches to the next view.

Inherited functions