Class SfTimeSelector
Represents a selectable object inside the Syncfusion.UI.Xaml.Controls.Input.TimePicker.
Inheritance
Implements
Namespace: Syncfusion.Windows.Controls.Input
Assembly: Syncfusion.SfInput.Wpf.dll
Syntax
public class SfTimeSelector : Control, IDisposable
Remarks
TimeSelector is a Windows.UI.Xaml.Controls.Control
Constructors
SfTimeSelector()
Initializes a new instance of the Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
Declaration
public SfTimeSelector()
See Also
Fields
AccentBrushProperty
Using a DependencyProperty as the backing store for AccentBrush. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty AccentBrushProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
FormatStringProperty
Using a DependencyProperty as the backing store for ValueFormat. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty FormatStringProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
HeaderProperty
Using a DependencyProperty as the backing store for Header. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty HeaderProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
HeaderStyleProperty
Using a DependencyProperty as the backing store for HeaderStyle. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty HeaderStyleProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
HeaderTemplateProperty
Using a DependencyProperty as the backing store for HeaderTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty HeaderTemplateProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
HourCellTemplateProperty
Using a DependencyProperty as the backing store for HourCellTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty HourCellTemplateProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
HourCellTemplateSelectorProperty
Using a DependencyProperty as the backing store for HourCellTemplateSelector. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty HourCellTemplateSelectorProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MaxTimeProperty
Declaration
public static readonly DependencyProperty MaxTimeProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MeridiemCellTemplateProperty
Using a DependencyProperty as the backing store for MeridiemCellTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty MeridiemCellTemplateProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MeridiemCellTemplateSelectorProperty
Using a DependencyProperty as the backing store for MeridiemCellTemplateSelector. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty MeridiemCellTemplateSelectorProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MinTimeProperty
Declaration
public static readonly DependencyProperty MinTimeProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MinuteCellTemplateProperty
Using a DependencyProperty as the backing store for MinuteCellTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty MinuteCellTemplateProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MinuteCellTemplateSelectorProperty
Using a DependencyProperty as the backing store for MinuteCellTemplateSelector. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty MinuteCellTemplateSelectorProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
MinuteIntervalProperty
Using a DependencyProperty as the backing store for MinuteInterval. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty MinuteIntervalProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SecondCellTemplateProperty
Using a DependencyProperty as the backing store for MinuteCellTemplate. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SecondCellTemplateProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SecondCellTemplateSelectorProperty
Using a DependencyProperty as the backing store for MinuteCellTemplateSelector. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SecondCellTemplateSelectorProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SecondsIntervalProperty
Using a DependencyProperty as the backing store for SecondsInterval. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SecondsIntervalProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectedForegroundProperty
Using a DependencyProperty as the backing store for AccentBrush. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectedForegroundProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectedTimeProperty
Using a DependencyProperty as the backing store for SelectedDateTime. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectedTimeProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectorItemCountProperty
Using a DependencyProperty as the backing store for SelectorItemCount. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectorItemCountProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectorItemHeightProperty
Using a DependencyProperty as the backing store for SelectorItemHeight. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectorItemHeightProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectorItemSpacingProperty
Using a DependencyProperty as the backing store for SelectorItemSpacing. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectorItemSpacingProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectorItemWidthProperty
Using a DependencyProperty as the backing store for SelectorItemWidth. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectorItemWidthProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectorStyleProperty
Using a DependencyProperty as the backing store for SelectorStyle. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SelectorStyleProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ShowCancelButtonProperty
Using a DependencyProperty as the backing store for ShowCancelButton. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ShowCancelButtonProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ShowDoneButtonProperty
Using a DependencyProperty as the backing store for ShowSelectButton. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ShowDoneButtonProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
Properties
AccentBrush
Gets or sets the background for Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
Declaration
public Brush AccentBrush { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Media.Brush | The default value is null. |
See Also
FormatString
Gets or sets the FormatString for the control Windows.UI.Xaml.Controls.Control
Declaration
public object FormatString { get; set; }
Property Value
Type |
---|
System.Object |
Header
Gets or sets the data used for the header of Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
Declaration
public object Header { get; set; }
Property Value
Type | Description |
---|---|
System.Object | The default value is null. |
See Also
HeaderStyle
Gets or sets the style of the header of the time control field.
Declaration
public Style HeaderStyle { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Style | The default value is null. |
Remarks
The HeaderStyle property governs the appearance of any text displayed in the header item
See Also
HeaderTemplate
Gets or sets the datatemplate used to display the content of the Syncfusion.UI.Xaml.Controls.Input.TimeSelector header.
Declaration
public DataTemplate HeaderTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.DataTemplate | The default value is null. |
Remarks
Use the HeaderTemplate property to specify the custom content displayed for the header section of a time selector object
See Also
HourCellTemplate
Gets or sets the template for hour looping selector.
Declaration
public DataTemplate HourCellTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.DataTemplate | The default value is null. |
Remarks
Use as the datatemplate for the hour looping selector.
See Also
HourCellTemplateSelector
Gets or sets the templateselector for hour looping selector.
Declaration
public DataTemplateSelector HourCellTemplateSelector { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Controls.DataTemplateSelector | The default value is null. |
MaxTime
Gets or sets the Maximum Time to be listed in the Syncfusion.UI.Xaml.Controls.Input.TimeSelector control.
Declaration
public TimeSpan MaxTime { get; set; }
Property Value
Type |
---|
System.TimeSpan |
MeridiemCellTemplate
Gets or sets the template for day looping selector.
Declaration
public DataTemplate MeridiemCellTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.DataTemplate | The default value is null. |
Remarks
Use as the datatemplate for the day looping selector.
See Also
MeridiemCellTemplateSelector
Gets or sets the templateselector for meridiem looping selector.
Declaration
public DataTemplateSelector MeridiemCellTemplateSelector { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Controls.DataTemplateSelector | The default value is null. |
MinTime
Gets or sets the Minimum time to be listed in the Syncfusion.UI.Xaml.Controls.Input.TimeSelector control.
Declaration
public TimeSpan MinTime { get; set; }
Property Value
Type |
---|
System.TimeSpan |
MinuteCellTemplate
Gets or sets the template for minute looping selector.
Declaration
public DataTemplate MinuteCellTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.DataTemplate | The default value is null. |
Remarks
Use as the datatemplate for the Minute looping selector.
See Also
MinuteCellTemplateSelector
Gets or sets the templateselector for minute looping selector.
Declaration
public DataTemplateSelector MinuteCellTemplateSelector { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Controls.DataTemplateSelector | The default value is null. |
MinuteInterval
Gets or sets interval for minute values.
Declaration
public int MinuteInterval { get; set; }
Property Value
Type |
---|
System.Int32 |
SecondCellTemplate
Gets or sets the template for second looping selector.
Declaration
public DataTemplate SecondCellTemplate { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.DataTemplate | The default value is null. |
Remarks
Use as the datatemplate for the Second looping selector.
See Also
SecondCellTemplateSelector
Gets or sets the templateselector for second looping selector.
Declaration
public DataTemplateSelector SecondCellTemplateSelector { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Controls.DataTemplateSelector | The default value is null. |
SecondsInterval
Gets or sets interval for second values.
Declaration
public int SecondsInterval { get; set; }
Property Value
Type |
---|
System.Int32 |
SelectedForeground
Gets or sets the background for Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
Declaration
public Brush SelectedForeground { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Media.Brush | The default value is null. |
See Also
SelectedTime
Gets or sets the currently selected time for Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
Declaration
public Nullable<DateTime> SelectedTime { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.DateTime> | The default value is System.DateTime.Now. |
Remarks
Use to hold the currently selected time value.
See Also
SelectorItemCount
Gets or sets the SelectorItemCount for the time selector items
Declaration
public int SelectorItemCount { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 | The default value is 0 |
SelectorItemHeight
Gets or sets the SelectorItemHeight for the time selector items
Declaration
public double SelectorItemHeight { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 30 |
SelectorItemSpacing
Gets or sets the SelectorItemSpacing for the time selector items
Declaration
public double SelectorItemSpacing { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 4 |
SelectorItemWidth
Gets or sets the SelectorItemWidth for the time selector items
Declaration
public double SelectorItemWidth { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The default value is 30 |
SelectorStyle
Gets or sets the style that apply for the Syncfusion.UI.Xaml.Controls.LoopingSelector.
Declaration
public Style SelectorStyle { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Style | The default value is null. |
Remarks
Use to apply the style to the looping selector inside the Syncfusion.UI.Xaml.Controls.Input.TimeSelector.
See Also
ShowCancelButton
Gets or sets a value indicating whether show or hide the cancel button .
Declaration
public bool ShowCancelButton { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
Remarks
The default value is true.
See Also
ShowDoneButton
Gets or sets a value indicating whether show or hide the done button.
Declaration
public bool ShowDoneButton { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
Remarks
The default value is true.
See Also
Methods
Dispose()
Disposes the control while unloading.
Declaration
public void Dispose()
OnApplyTemplate()
Initializes all te child elements of the Syncfusion.UI.Xaml.Controls.Input.TimeSelector control.
Declaration
public override void OnApplyTemplate()
OnFormatStringChanged(DependencyPropertyChangedEventArgs)
Occurs when the FormatString is changed
Declaration
protected virtual void OnFormatStringChanged(DependencyPropertyChangedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyPropertyChangedEventArgs | args |
OnGotFocus(RoutedEventArgs)
Occurs when the SfTimeSelector receives focus.
Declaration
protected override void OnGotFocus(RoutedEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.RoutedEventArgs | e |
OnKeyDown(KeyEventArgs)
Handles keydown event Syncfusion.UI.Xaml.Controls.Input.TimeSelector control.
Declaration
protected override void OnKeyDown(KeyEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.KeyEventArgs | e |
OnMouseLeftButtonDown(MouseButtonEventArgs)
Invoked when an unhandled System.Windows.UIElement.MouseLeftButtonDown routed event is raised on this element. Implement this method to add class handling for this event.
Declaration
protected override void OnMouseLeftButtonDown(MouseButtonEventArgs e)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.Input.MouseButtonEventArgs | e | The System.Windows.Input.MouseButtonEventArgs that contains the event data. The event data reports that the left mouse button was pressed. |
Events
Cancel
Occurs when cancel button is clicked.
Declaration
public event RoutedEventHandler Cancel
Event Type
Type |
---|
System.Windows.RoutedEventHandler |
Select
Occurs when done is clicked.
Declaration
public event RoutedEventHandler Select
Event Type
Type |
---|
System.Windows.RoutedEventHandler |
SelectedTimeChanged
Occurs when selected time changed.
Declaration
public event PropertyChangedCallback SelectedTimeChanged
Event Type
Type |
---|
System.Windows.PropertyChangedCallback |
Remarks
raised when selected time property is changed.