Tab

abstract class Tab(source)

Deprecated

Action bar navigation modes are deprecated and not supported by inline toolbar action bars. Consider using other common navigation patterns instead.

A tab in the action bar.

Tabs manage the hiding and showing of Fragments.

Inheritors

Constructors

Link copied to clipboard
constructor()

Properties

Link copied to clipboard
An invalid position for a tab.

Functions

Link copied to clipboard
Gets a brief description of this tab's content for use in accessibility support.
Link copied to clipboard
abstract fun getCustomView(): View
Retrieve a previously set custom view for this tab.
Link copied to clipboard
abstract fun getIcon(): Drawable
Return the icon associated with this tab.
Link copied to clipboard
abstract fun getPosition(): Int
Return the current position of this tab in the action bar.
Link copied to clipboard
abstract fun getTag(): Any
Link copied to clipboard
abstract fun getText(): CharSequence
Return the text of this tab.
Link copied to clipboard
abstract fun select()
Select this tab.
Link copied to clipboard
Set a description of this tab's content for use in accessibility support.
Link copied to clipboard
abstract fun setCustomView(view: View): ActionBar.Tab
abstract fun setCustomView(layoutResId: Int): ActionBar.Tab
Set a custom view to be used for this tab.
Link copied to clipboard
abstract fun setIcon(icon: Drawable): ActionBar.Tab
abstract fun setIcon(@DrawableRes resId: Int): ActionBar.Tab
Set the icon displayed on this tab.
Link copied to clipboard
Set the TabListener that will handle switching to and from this tab.
Link copied to clipboard
abstract fun setTag(obj: Any): ActionBar.Tab
Give this Tab an arbitrary object to hold for later use.
Link copied to clipboard
abstract fun setText(resId: Int): ActionBar.Tab
abstract fun setText(text: CharSequence): ActionBar.Tab
Set the text displayed on this tab.