Class SfTabView
The SfTabViewclass control lets users explore and switch among different views.
Inheritance
Implements
Namespace: Syncfusion.Android.TabView
Assembly: Syncfusion.SfTabView.Android.dll
Syntax
public class SfTabView : FrameLayout, INotifyPropertyChanged
Constructors
SfTabView(Context)
Initializes a new instance of the SfTabView class.
Declaration
public SfTabView(Context context)
Parameters
Type | Name | Description |
---|---|---|
Android.Content.Context | context | Context type. |
SfTabView(Context, IAttributeSet)
Initializes a new instance of the SfTabView class.
Declaration
public SfTabView(Context context, IAttributeSet attribute)
Parameters
Type | Name | Description |
---|---|---|
Android.Content.Context | context | Context Type. |
Android.Util.IAttributeSet | attribute | Attribute sets. |
Properties
CenterButtonSettings
Gets or sets the value to configure the overflow button attributes.
Declaration
public CenterButtonSettings CenterButtonSettings { get; set; }
Property Value
Type |
---|
CenterButtonSettings |
Remarks
The CenterButtonSettings property will customize the tabview CenterButton Title, BackgroundColor, Width.
CenterButtonView
Gets or sets the View for the CenterButton
Declaration
public View CenterButtonView { get; set; }
Property Value
Type |
---|
Android.Views.View |
Remarks
The CenterButtonView property used to customize the tabview CenterButton.
ContentTransitionDuration
Gets or sets a value indicating whether this Com.Syncfusion.SfTabView.SfTabView Content Transition Duration.
Declaration
public int ContentTransitionDuration { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | Default values is 200. |
Remarks
The ContentTransitionDuration property will represents the loading time of new tabitem content.
DisplayMode
Gets or sets the value to define the type of header. By default it will display title from SfTabItem.
Declaration
public TabDisplayMode DisplayMode { get; set; }
Property Value
Type | Description |
---|---|
TabDisplayMode | Default value of Display mode is Text. |
Remarks
Based on DisplayMode property the tabitem will be displayed in text, image or image with text. Default value is Text.
Elevation
Gets or sets the boolean variable to enable shadow of Tab Header. Available only in android.
Declaration
public double Elevation { get; set; }
Property Value
Type | Description |
---|---|
System.Double | Default value is 0. |
Remarks
The Elevation property will define the size of tabheader shadow.
ElevationShadowColor
Gets or sets shadow color of elevation Available only in android.
Declaration
public Color ElevationShadowColor { get; set; }
Property Value
Type |
---|
Android.Graphics.Color |
Remarks
The ElevationShadowColor property will define the tab header shadow color. Default color is Black.
EnableScrollButton
Gets or sets a value indicating whether Enable Scroll Button.
Declaration
public bool EnableScrollButton { get; set; }
Property Value
Type |
---|
System.Boolean |
Remarks
The EnableScrollButton property will show the scroll button on both sides of tabview, Default value is false.
EnableSwiping
Gets or sets a value indicating whether this Com.Syncfusion.SfTabView.SfTabView enable swiping.
Declaration
public bool EnableSwiping { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean | Default value of enable swiping is true |
Remarks
The EnableSwiping property will restrict the user interaction with the tabitem.
Items
Gets or sets children for tab control through the collection of SfTabItem.
Declaration
public TabItemCollection Items { get; set; }
Property Value
Type |
---|
TabItemCollection |
Remarks
While creating collection of tabitems, Items property holds the collection.
OverflowButtonSettings
Gets or sets the value to configure the overflow button attributes.
Declaration
public OverflowButtonSettings OverflowButtonSettings { get; set; }
Property Value
Type |
---|
OverflowButtonSettings |
Remarks
The OverflowButtonSetting property will customize the tabview overflow button.
OverflowMode
Gets or sets the value to choose navigation option for the exceeded headers which can't be occupied in the current view.
Declaration
public OverflowMode OverflowMode { get; set; }
Property Value
Type | Description |
---|---|
OverflowMode | Default value is scroll mode. |
Remarks
The OverflowMode proeprty will represents how the hidden tabitems need to display.
ScrollButtonBackgroundColor
Gets or sets the color for the Scroll Button Background color.
Declaration
public Color ScrollButtonBackgroundColor { get; set; }
Property Value
Type |
---|
Android.Graphics.Color |
Remarks
The ScrollButtonBackgroundColor proeprty will customize the scrollbutton bakcgroundcolor. Defalut color is Transparant.
ScrollButtonTextColor
Gets or sets the color for the Scrollable Font Icon color.
Declaration
public Color ScrollButtonTextColor { get; set; }
Property Value
Type |
---|
Android.Graphics.Color |
Remarks
The ScrollButtonTextColor property will define the scrollable font icon color. Default color is white.
SelectedIndex
Gets or sets the index of the selected item.
Declaration
public int SelectedIndex { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | A value of -1 represents no item selected. |
Remarks
An 0-based index representing the selected item in the list. Default is -1
SelectionIndicatorSettings
Gets or sets value to configure the attributes of SelectionIndicatorSettings.
Declaration
public SelectionIndicatorSettings SelectionIndicatorSettings { get; set; }
Property Value
Type |
---|
SelectionIndicatorSettings |
Remarks
SelectionIndicatorSettings is used to customize the selection indicator position and color of SfTabView.
TabHeaderBackgroundColor
Gets or sets the color of the tab header background in SfTabView.
Declaration
public Color TabHeaderBackgroundColor { get; set; }
Property Value
Type | Description |
---|---|
Android.Graphics.Color | Default color is transparant |
Remarks
The TabHeaderBackgroundColor property will customize the tabitem header backgroundcolor
TabHeaderPosition
Gets or sets the value for the position of the header.
Declaration
public TabHeaderPosition TabHeaderPosition { get; set; }
Property Value
Type | Description |
---|---|
TabHeaderPosition | Default TabHeaderPosition is Top. |
Remarks
The TabHeaderPosition property will represents the position of tab item header, TabHeaderPosition have Top and Bottom options.
TabHeight
Gets or sets the value for the height of header in SfTabView.
Declaration
public double TabHeight { get; set; }
Property Value
Type | Description |
---|---|
System.Double | Default value is 48 |
Remarks
The TabHeight property will define the height of the tabview.
TabWidth
Gets or sets the value for the width of each header in SfTabView.
Declaration
public double TabWidth { get; set; }
Property Value
Type | Description |
---|---|
System.Double | Default value is 100. |
Remarks
The TabWidth property will define the width of the tabview.
TabWidthMode
Gets or sets a value indicating whether the auto tab width is enabled.
Declaration
public TabWidthMode TabWidthMode { get; set; }
Property Value
Type | Description |
---|---|
TabWidthMode | true if auto tab width is enabled; otherwise, false.The default value is false. |
VisibleHeaderCount
Gets or sets the value for the number of headers to be displayed in the visible region.
Declaration
public Nullable<int> VisibleHeaderCount { get; set; }
Property Value
Type |
---|
System.Nullable<System.Int32> |
Remarks
The VisibleHeaderCount property will define the number of tabitem need to display in visible screen.
Methods
Dispose(Boolean)
The override diposing method.
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | The disposing. |
OnLayout(Boolean, Int32, Int32, Int32, Int32)
The override OnLayout changed emethod.
Declaration
protected override void OnLayout(bool changed, int left, int top, int right, int bottom)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | changed | The changed. |
System.Int32 | left | The left. |
System.Int32 | top | The top. |
System.Int32 | right | The right. |
System.Int32 | bottom | The bottom. |
RaiseOnPropertyChanged(String, Boolean)
This method is called by the Set accessor of each property. The CallerMemberName attribute that is applied to the optional propertyName parameter causes the property name of the caller to be substituted as an argument.
Declaration
protected virtual void RaiseOnPropertyChanged(string propertyName = null, bool indexUpdate = true)
Parameters
Type | Name | Description |
---|---|---|
System.String | propertyName | String type. |
System.Boolean | indexUpdate | The index update. |
Events
CenterButtonTapped
Occurs when Center button tapped.
Declaration
public event EventHandler<EventArgs> CenterButtonTapped
Event Type
Type |
---|
System.EventHandler<System.EventArgs> |
OverflowButtonTapped
Occurs when overflow button tapped.
Declaration
public event EventHandler<CancelEventArgs> OverflowButtonTapped
Event Type
Type |
---|
System.EventHandler<System.ComponentModel.CancelEventArgs> |
PropertyChanged
The property changed event.
Declaration
public event PropertyChangedEventHandler PropertyChanged
Event Type
Type |
---|
System.ComponentModel.PropertyChangedEventHandler |
SelectionChanged
Occurs when index changed.
Declaration
public event EventHandler<SelectionChangedEventArgs> SelectionChanged
Event Type
Type |
---|
System.EventHandler<SelectionChangedEventArgs> |
SelectionChanging
Occurs before Selected
Declaration
public event EventHandler<SelectionChangingEventArgs> SelectionChanging
Event Type
Type |
---|
System.EventHandler<SelectionChangingEventArgs> |
TabItemTapped
Occurs when tab header item tapped.
Declaration
public event EventHandler<TabItemTappedEventArgs> TabItemTapped
Event Type
Type |
---|
System.EventHandler<TabItemTappedEventArgs> |