Since: API Level 1
package

android.widget

Classes | Description

The widget package contains (mostly visual) UI elements to use on your Application screen.

more...

Interfaces

AbsListView.OnScrollListenerInterface definition for a callback to be invoked when the list or grid has been scrolled. 
AbsListView.RecyclerListenerA RecyclerListener is used to receive a notification whenever a View is placed inside the RecycleBin's scrap heap. 
AdapterAn Adapter object acts as a bridge between an AdapterView and the underlying data for that view. 
AdapterView.OnItemClickListenerInterface definition for a callback to be invoked when an item in this AdapterView has been clicked. 
AdapterView.OnItemLongClickListenerInterface definition for a callback to be invoked when an item in this view has been clicked and held. 
AdapterView.OnItemSelectedListenerInterface definition for a callback to be invoked when an item in this view has been selected. 
AutoCompleteTextView.ValidatorThis interface is used to make sure that the text entered in this TextView complies to a certain format. 
CheckableDefines an extension for views that make them checkable. 
Chronometer.OnChronometerTickListenerA callback that notifies when the chronometer has incremented on its own. 
CompoundButton.OnCheckedChangeListenerInterface definition for a callback to be invoked when the checked state of a compound button changed. 
DatePicker.OnDateChangedListenerThe callback used to indicate the user changes the date. 
ExpandableListAdapterAn adapter that links a ExpandableListView with the underlying data. 
ExpandableListView.OnChildClickListenerInterface definition for a callback to be invoked when a child in this expandable list has been clicked. 
ExpandableListView.OnGroupClickListenerInterface definition for a callback to be invoked when a group in this expandable list has been clicked. 
ExpandableListView.OnGroupCollapseListenerUsed for being notified when a group is collapsed  
ExpandableListView.OnGroupExpandListenerUsed for being notified when a group is expanded  
Filter.FilterListener

Listener used to receive a notification upon completion of a filtering operation. 

Filterable

Defines a filterable behavior. 

FilterQueryProviderThis class can be used by external clients of CursorAdapter and CursorTreeAdapter to define how the content of the adapter should be filtered. 
HeterogeneousExpandableListAdditional methods that when implemented make an ExpandableListAdapter take advantage of the Adapter view type mechanism. 
ListAdapterExtended Adapter that is the bridge between a ListView and the data that backs the list. 
MediaController.MediaPlayerControl 
MultiAutoCompleteTextView.Tokenizer 
PopupWindow.OnDismissListenerListener that is called when this popup window is dismissed. 
RadioGroup.OnCheckedChangeListener

Interface definition for a callback to be invoked when the checked radio button changed in this group. 

RatingBar.OnRatingBarChangeListenerA callback that notifies clients when the rating has been changed. 
SectionIndexerInterface that should be implemented on Adapters to enable fast scrolling in an AbsListView between sections of the list. 
SeekBar.OnSeekBarChangeListenerA callback that notifies clients when the progress level has been changed. 
SimpleAdapter.ViewBinderThis class can be used by external clients of SimpleAdapter to bind values to views. 
SimpleCursorAdapter.CursorToStringConverterThis class can be used by external clients of SimpleCursorAdapter to define how the Cursor should be converted to a String. 
SimpleCursorAdapter.ViewBinderThis class can be used by external clients of SimpleCursorAdapter to bind values fom the Cursor to views. 
SimpleCursorTreeAdapter.ViewBinderThis class can be used by external clients of SimpleCursorTreeAdapter to bind values from the Cursor to views. 
SlidingDrawer.OnDrawerCloseListenerCallback invoked when the drawer is closed. 
SlidingDrawer.OnDrawerOpenListenerCallback invoked when the drawer is opened. 
SlidingDrawer.OnDrawerScrollListenerCallback invoked when the drawer is scrolled. 
SpinnerAdapterExtended Adapter that is the bridge between a Spinner and its data. 
TabHost.OnTabChangeListenerInterface definition for a callback to be invoked when tab changed  
TabHost.TabContentFactoryMakes the content of a tab when it is selected. 
TextView.OnEditorActionListenerInterface definition for a callback to be invoked when an action is performed on the editor. 
TimePicker.OnTimeChangedListenerThe callback interface used to indicate the time has been adjusted. 
ViewSwitcher.ViewFactoryCreates views in a ViewSwitcher. 
WrapperListAdapterList adapter that wraps another list adapter. 
ZoomButtonsController.OnZoomListenerInterface that will be called when the user performs an interaction that triggers some action, for example zooming. 

Classes

AbsListViewBase class that can be used to implement virtualized lists of items. 
AbsListView.LayoutParamsAbsListView extends LayoutParams to provide a place to hold the view type. 
AbsoluteLayout This class is deprecated. Use FrameLayout, RelativeLayout or a custom layout instead.  
AbsoluteLayout.LayoutParamsPer-child layout information associated with AbsoluteLayout. 
AbsSeekBar 
AbsSpinnerAn abstract base class for spinner widgets. 
AdapterView<T extends Adapter>An AdapterView is a view whose children are determined by an Adapter
AdapterView.AdapterContextMenuInfoExtra menu information provided to the onCreateContextMenu(ContextMenu, View, ContextMenuInfo) callback when a context menu is brought up for this AdapterView. 
AlphabetIndexerA helper class for adapters that implement the SectionIndexer interface. 
AnalogClockThis widget display an analogic clock with two hands for hours and minutes. 
ArrayAdapter<T>A ListAdapter that manages a ListView backed by an array of arbitrary objects. 
AutoCompleteTextView

An editable text view that shows completion suggestions automatically while the user is typing. 

BaseAdapterCommon base class of common implementation for an Adapter that can be used in both ListView (by implementing the specialized ListAdapter interface} and Spinner (by implementing the specialized SpinnerAdapter interface. 
BaseExpandableListAdapterBase class for a ExpandableListAdapter used to provide data and Views from some data to an expandable list view. 
ButtonRepresents a push-button widget. 
CheckBox

A checkbox is a specific type of two-states button that can be either checked or unchecked. 

CheckedTextViewAn extension to TextView that supports the Checkable interface. 
ChronometerClass that implements a simple timer. 
CompoundButton

A button with two states, checked and unchecked. 

CursorAdapterAdapter that exposes data from a Cursor to a ListView widget. 
CursorTreeAdapterAn adapter that exposes data from a series of Cursors to an ExpandableListView widget. 
DatePickerA view for selecting a month / year / day based on a calendar like layout. 
DialerFilter 
DigitalClockLike AnalogClock, but digital. 
EditTextEditText is a thin veneer over TextView that configures itself to be editable. 
ExpandableListViewA view that shows items in a vertically scrolling two-level list. 
ExpandableListView.ExpandableListContextMenuInfoExtra menu information specific to an ExpandableListView provided to the onCreateContextMenu(ContextMenu, View, ContextMenuInfo) callback when a context menu is brought up for this AdapterView. 
Filter

A filter constrains data with a filtering pattern. 

Filter.FilterResults

Holds the results of a filtering operation. 

FrameLayoutFrameLayout is designed to block out an area on the screen to display a single item. 
FrameLayout.LayoutParamsPer-child layout information for layouts that support margins. 
GalleryA view that shows items in a center-locked, horizontally scrolling list. 
Gallery.LayoutParamsGallery extends LayoutParams to provide a place to hold current Transformation information along with previous position/transformation info. 
GridViewA view that shows items in two-dimensional scrolling grid. 
HeaderViewListAdapterListAdapter used when a ListView has header views. 
HorizontalScrollViewLayout container for a view hierarchy that can be scrolled by the user, allowing it to be larger than the physical display. 
ImageButton

Displays a button with an image (instead of text) that can be pressed or clicked by the user. 

ImageSwitcher 
ImageViewDisplays an arbitrary image, such as an icon. 
LinearLayoutA Layout that arranges its children in a single column or a single row. 
LinearLayout.LayoutParamsPer-child layout information associated with ViewLinearLayout. 
ListViewA view that shows items in a vertically scrolling list. 
ListView.FixedViewInfoA class that represents a fixed view in a list, for example a header at the top or a footer at the bottom. 
MediaControllerA view containing controls for a MediaPlayer. 
MultiAutoCompleteTextViewAn editable text view, extending AutoCompleteTextView, that can show completion suggestions for the substring of the text where the user is typing instead of necessarily for the entire thing. 
MultiAutoCompleteTextView.CommaTokenizerThis simple Tokenizer can be used for lists where the items are separated by a comma and one or more spaces. 
OverScrollerThis class encapsulates scrolling with the ability to overshoot the bounds of a scrolling operation. 
PopupWindow

A popup window that can be used to display an arbitrary view. 

ProgressBar

Visual indicator of progress in some operation. 

QuickContactBadgeWidget used to show an image with the standard QuickContact badge and on-click behavior. 
RadioButton

A radio button is a two-states button that can be either checked or unchecked. 

RadioGroup

This class is used to create a multiple-exclusion scope for a set of radio buttons. 

RadioGroup.LayoutParams

This set of layout parameters defaults the width and the height of the children to WRAP_CONTENT when they are not specified in the XML file. 

RatingBarA RatingBar is an extension of SeekBar and ProgressBar that shows a rating in stars. 
RelativeLayoutA Layout where the positions of the children can be described in relation to each other or to the parent. 
RelativeLayout.LayoutParamsPer-child layout information associated with RelativeLayout. 
RemoteViewsA class that describes a view hierarchy that can be displayed in another process. 
ResourceCursorAdapterAn easy adapter that creates views defined in an XML file. 
ResourceCursorTreeAdapterA fairly simple ExpandableListAdapter that creates views defined in an XML file. 
ScrollerThis class encapsulates scrolling. 
ScrollViewLayout container for a view hierarchy that can be scrolled by the user, allowing it to be larger than the physical display. 
SeekBarA SeekBar is an extension of ProgressBar that adds a draggable thumb. 
SimpleAdapterAn easy adapter to map static data to views defined in an XML file. 
SimpleCursorAdapterAn easy adapter to map columns from a cursor to TextViews or ImageViews defined in an XML file. 
SimpleCursorTreeAdapterAn easy adapter to map columns from a cursor to TextViews or ImageViews defined in an XML file. 
SimpleExpandableListAdapterAn easy adapter to map static data to group and child views defined in an XML file. 
SlidingDrawerSlidingDrawer hides content out of the screen and allows the user to drag a handle to bring the content on screen. 
SpinnerA view that displays one child at a time and lets the user pick among them. 
TabHostContainer for a tabbed window view. 
TabHost.TabSpecA tab has a tab indicator, content, and a tag that is used to keep track of it. 
TableLayout

A layout that arranges its children into rows and columns. 

TableLayout.LayoutParams

This set of layout parameters enforces the width of each child to be MATCH_PARENT and the height of each child to be WRAP_CONTENT, but only if the height is not specified. 

TableRow

A layout that arranges its children horizontally. 

TableRow.LayoutParams

Set of layout parameters used in table rows. 

TabWidgetDisplays a list of tab labels representing each page in the parent's tab collection. 
TextSwitcherSpecialized ViewSwitcher that contains only children of type TextView
TextViewDisplays text to the user and optionally allows them to edit it. 
TextView.SavedStateUser interface state that is stored by TextView for implementing onSaveInstanceState()
TimePickerA view for selecting the time of day, in either 24 hour or AM/PM mode. 
ToastA toast is a view containing a quick little message for the user. The toast class helps you create and show those.  
ToggleButtonDisplays checked/unchecked states as a button with a "light" indicator and by default accompanied with the text "ON" or "OFF". 
TwoLineListItem

A view group with two children, intended for use in ListViews. 

VideoViewDisplays a video file. 
ViewAnimatorBase class for a FrameLayout container that will perform animations when switching between its views. 
ViewFlipperSimple ViewAnimator that will animate between two or more views that have been added to it. 
ViewSwitcherViewAnimator that switches between two views, and has a factory from which these views are created. 
ZoomButton 
ZoomButtonsControllerThe ZoomButtonsController handles showing and hiding the zoom controls and positioning it relative to an owner view. 
ZoomControlsThe ZoomControls class displays a simple set of controls used for zooming and provides callbacks to register for events. 

Enums

ImageView.ScaleTypeOptions for scaling the bounds of an image to the bounds of this view. 
TextView.BufferType 

Exceptions

RemoteViews.ActionExceptionException to send when something goes wrong executing an action