ClassRadSegmentedControl
Displays a list of horizontally aligned, mutually exclusive options, which can be selected by the user. Each option is a button that can display text or an image.
Definition
Namespace:Telerik.Maui.Controls
Assembly:Telerik.Maui.Controls.dll
Syntax:
public class RadSegmentedControl : RadBorder, IRadBorder, IRadContentView, IContentView, IView, IElement, ITransform, IPadding, ICrossPlatformLayout
Inheritance: objectRadContentViewRadBorderRadSegmentedControl
Implements:
Inherited Members
Constructors
RadSegmentedControl()
Initializes a new instance of the RadSegmentedControl class.
Declaration
public RadSegmentedControl()
Fields
ActualSelectionIndicatorStyleProperty
Identifies the ActualSelectionIndicatorStyle bindable property.
Declaration
public static readonly BindableProperty ActualSelectionIndicatorStyleProperty
Field Value
BindableProperty
ActualSeparatorStyleProperty
Identifies the ActualSeparatorStyle bindable property.
Declaration
public static readonly BindableProperty ActualSeparatorStyleProperty
Field Value
BindableProperty
ControlTemplateProperty
Identifies the ControlTemplate bindable property.
Declaration
public static readonly BindableProperty ControlTemplateProperty
Field Value
BindableProperty
CurrentItemProperty
Identifies the CurrentItem bindable property.
Declaration
public static readonly BindableProperty CurrentItemProperty
Field Value
BindableProperty
DisplayMemberPathProperty
Identifies the DisplayMemberPath bindable property.
Declaration
public static readonly BindableProperty DisplayMemberPathProperty
Field Value
BindableProperty
ItemTappedCommandProperty
Identifies the ItemTappedCommand bindable property.
Declaration
public static readonly BindableProperty ItemTappedCommandProperty
Field Value
BindableProperty
ItemTemplateProperty
Identifies the ItemTemplate bindable property.
Declaration
public static readonly BindableProperty ItemTemplateProperty
Field Value
BindableProperty
ItemViewStyleProperty
Identifies the ItemViewStyle bindable property.
Declaration
public static readonly BindableProperty ItemViewStyleProperty
Field Value
BindableProperty
ItemViewStyleSelectorProperty
Identifies the ItemViewStyleSelector bindable property.
Declaration
public static readonly BindableProperty ItemViewStyleSelectorProperty
Field Value
BindableProperty
ItemsSourceProperty
Identifies the ItemsSource bindable property.
Declaration
public static readonly BindableProperty ItemsSourceProperty
Field Value
BindableProperty
PaddingProperty
Identifies the Padding bindable property.
Declaration
public static readonly BindableProperty PaddingProperty
Field Value
BindableProperty
SelectedIndexProperty
Identifies the SelectedIndex bindable property.
Declaration
public static readonly BindableProperty SelectedIndexProperty
Field Value
BindableProperty
SelectedItemProperty
Identifies the SelectedItem bindable property.
Declaration
public static readonly BindableProperty SelectedItemProperty
Field Value
BindableProperty
SelectionIndicatorStyleProperty
Identifies the SelectionIndicatorStyle bindable property.
Declaration
public static readonly BindableProperty SelectionIndicatorStyleProperty
Field Value
BindableProperty
SelectionModeProperty
Identifies the SelectionMode bindable property.
Declaration
public static readonly BindableProperty SelectionModeProperty
Field Value
BindableProperty
SeparatorStyleProperty
Identifies the SeparatorStyle bindable property.
Declaration
public static readonly BindableProperty SeparatorStyleProperty
Field Value
BindableProperty
StyleProperty
Identifies the Style bindable property.
Declaration
public static readonly BindableProperty StyleProperty
Field Value
BindableProperty
Properties
ActualSelectionIndicatorStyle
Gets the actual style applied to the selection indicator, computed by merging the user-provided SelectionIndicatorStyle with the default style.
Declaration
public Style ActualSelectionIndicatorStyle { get; }
Property Value
Style
ActualSeparatorStyle
Gets the actual style applied to the separator rectangles between items, computed by merging the user-provided SeparatorStyle with the default style.
Declaration
public Style ActualSeparatorStyle { get; }
Property Value
Style
ControlTemplate
Gets or sets the control template of this view.
Declaration
public ControlTemplate ControlTemplate { get; set; }
Property Value
ControlTemplate
CurrentItem
Gets or sets the current item in the segmented control for keyboard navigation purposes. This is primarily used on desktop platforms to track which item has keyboard focus. The current item is visually highlighted and can be navigated using arrow keys.
DisplayMemberPath
Gets or sets the path to the property of the data item which will be used to display text in each segment.
ItemTappedCommand
Gets or sets the command that is executed when a segment item is tapped. The command parameter is the data item of the tapped segment.
Declaration
public ICommand ItemTappedCommand { get; set; }
Property Value
ItemTemplate
Gets or sets the DataTemplate that defines the appearance of each segment item. When set, replaces the default label content with custom content created from this template.
Declaration
public DataTemplate ItemTemplate { get; set; }
Property Value
DataTemplate
ItemViewStyle
Gets or sets the Style applied uniformly to each RadSegmentedControlItemView.
Declaration
public Style ItemViewStyle { get; set; }
Property Value
Style
ItemViewStyleSelector
Gets or sets the IStyleSelector that provides per-item style logic for RadSegmentedControlItemView instances. When set, the selector is invoked with the business item and the container view to determine the applied style.
Declaration
public IStyleSelector ItemViewStyleSelector { get; set; }
Property Value
ItemsSource
Gets or sets the collection of items of the control.
Declaration
public IEnumerable ItemsSource { get; set; }
Property Value
Padding
Gets or sets the padding inside the control, between its border and content.
Declaration
public Thickness Padding { get; set; }
Property Value
Thickness
SelectedIndex
Gets or sets the index of the item to be selected.
SelectedItem
Gets or sets the currently selected item.
SelectionIndicatorStyle
Gets or sets the Style applied to the selection indicator.
Declaration
public Style SelectionIndicatorStyle { get; set; }
Property Value
Style
SelectionMode
Gets or sets the selection mode that determines how items can be selected.
Declaration
public SegmentedControlSelectionMode SelectionMode { get; set; }
Property Value
SeparatorStyle
Gets or sets the Style applied to each separator rectangle between segment items.
Declaration
public Style SeparatorStyle { get; set; }
Property Value
Style
Style
Gets or sets the style of this view.
Declaration
public Style Style { get; set; }
Property Value
Style
Methods
IsSegmentEnabled(int)
Determines if the specified segment is enabled.
OnApplyTemplate()
Declaration
protected override void OnApplyTemplate()
SetSegmentEnabled(int, bool)
Sets the enabled state of the specified segment.
Events
ItemTapped
Raised when an item is tapped, regardless of the SelectionMode.
Declaration
public event EventHandler<RadTappedEventArgs<object>> ItemTapped
Event Value
EventHandler<RadTappedEventArgs<object>>
SelectionChanged
Raised when the current selection has changed.
Declaration
public event EventHandler<RadSelectionChangedEventArgs> SelectionChanged
Event Value
EventHandler<RadSelectionChangedEventArgs>