Show / Hide Table of Contents

Class TimeSlider

The TimeSlider is a utility Control that emits TimeExtent values typically for use with the Map Control to enhance the viewing of geographic features that have attributes based upon Date/Time information.

Inheritance
Object
TimeSlider
Namespace: Esri.ArcGISRuntime.Toolkit.UI.Controls
Assembly: Esri.ArcGISRuntime.Toolkit.WinUI.dll
Syntax
public class TimeSlider : Control

Constructors

| Improve this Doc View Source

TimeSlider()

Initializes a new instance of the TimeSlider class.

Declaration
public TimeSlider()

Fields

| Improve this Doc View Source

CurrentExtentFillProperty

Identifies the CurrentExtentFill dependency property.

Declaration
public static readonly DependencyProperty CurrentExtentFillProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

CurrentExtentLabelColorProperty

Identifies the CurrentExtentLabelColor dependency property.

Declaration
public static readonly DependencyProperty CurrentExtentLabelColorProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

CurrentExtentLabelFormatProperty

Identifies the CurrentExtentLabelFormat dependency property.

Declaration
public static readonly DependencyProperty CurrentExtentLabelFormatProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

CurrentExtentProperty

Identifies the CurrentExtent dependency property.

Declaration
public static readonly DependencyProperty CurrentExtentProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

FullExtentFillProperty

Identifies the FullExtentFill dependency property.

Declaration
public static readonly DependencyProperty FullExtentFillProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

FullExtentLabelColorProperty

Identifies the FullExtentLabelColor dependency property.

Declaration
public static readonly DependencyProperty FullExtentLabelColorProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

FullExtentLabelFormatProperty

Identifies the FullExtentLabelFormat dependency property.

Declaration
public static readonly DependencyProperty FullExtentLabelFormatProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

FullExtentProperty

Identifies the FullExtent dependency property.

Declaration
public static readonly DependencyProperty FullExtentProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

FullExtentStrokeProperty

Identifies the FullExtentStroke dependency property.

Declaration
public static readonly DependencyProperty FullExtentStrokeProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

IsEndTimePinnedProperty

Identifies the IsEndTimePinned dependency property.

Declaration
public static readonly DependencyProperty IsEndTimePinnedProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

IsPlayingProperty

Identifies the IsPlaying dependency property.

Declaration
public static readonly DependencyProperty IsPlayingProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

IsStartTimePinnedProperty

Identifies the IsStartTimePinned dependency property.

Declaration
public static readonly DependencyProperty IsStartTimePinnedProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

LabelModeProperty

Identifies the LabelMode dependency property.

Declaration
public static readonly DependencyProperty LabelModeProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

LoopModeProperty

Identifies the PlaybackLoopMode dependency property.

Declaration
public static readonly DependencyProperty LoopModeProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

PlaybackButtonsFillProperty

Identifies the PlaybackButtonsFill dependency property.

Declaration
public static readonly DependencyProperty PlaybackButtonsFillProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

PlaybackButtonsStrokeProperty

Identifies the PlaybackButtonsStroke dependency property.

Declaration
public static readonly DependencyProperty PlaybackButtonsStrokeProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

PlaybackDirectionProperty

Identifies the PlaybackDirection dependency property.

Declaration
public static readonly DependencyProperty PlaybackDirectionProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

PlaybackIntervalProperty

Identifies the PlaybackInterval dependency property.

Declaration
public static readonly DependencyProperty PlaybackIntervalProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

ThumbFillProperty

Identifies the ThumbFill dependency property.

Declaration
public static readonly DependencyProperty ThumbFillProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

ThumbStrokeProperty

Identifies the ThumbStroke dependency property.

Declaration
public static readonly DependencyProperty ThumbStrokeProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

TimeStepIntervalLabelColorProperty

Identifies the TimeStepIntervalLabelColor dependency property.

Declaration
public static readonly DependencyProperty TimeStepIntervalLabelColorProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

TimeStepIntervalLabelFormatProperty

Identifies the TimeStepIntervalLabelFormat dependency property.

Declaration
public static readonly DependencyProperty TimeStepIntervalLabelFormatProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

TimeStepIntervalProperty

Identifies the TimeStepInterval dependency property.

Declaration
public static readonly DependencyProperty TimeStepIntervalProperty
Field Value
Type Description
DependencyProperty
| Improve this Doc View Source

TimeStepIntervalTickFillProperty

Identifies the TimeStepIntervalTickFill dependency property.

Declaration
public static readonly DependencyProperty TimeStepIntervalTickFillProperty
Field Value
Type Description
DependencyProperty

Properties

| Improve this Doc View Source

CurrentExtent

Gets or sets the associated with the visual thumbs(s) displayed on the TimeSlider.

Declaration
public TimeExtent? CurrentExtent { get; set; }
Property Value
Type Description
Nullable<TimeExtent>
| Improve this Doc View Source

CurrentExtentFill

Gets or sets the fill color of the area on the slider track that indicates the CurrentExtent.

Declaration
public Brush? CurrentExtentFill { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

CurrentExtentLabelColor

Gets or sets the color of the current extent labels.

Declaration
public Brush? CurrentExtentLabelColor { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

CurrentExtentLabelFormat

Gets or sets the string format to use for displaying the start and end labels for the CurrentExtent.

Declaration
public string CurrentExtentLabelFormat { get; set; }
Property Value
Type Description
String
| Improve this Doc View Source

FullExtent

Gets or sets the that specifies the overall start and end time of the time slider instance.

Declaration
public TimeExtent? FullExtent { get; set; }
Property Value
Type Description
Nullable<TimeExtent>
| Improve this Doc View Source

FullExtentFill

Gets or sets the fill color of the area on the slider track that indicates the FullExtent.

Declaration
public Brush? FullExtentFill { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

FullExtentLabelColor

Gets or sets the color of the full extent labels.

Declaration
public Brush? FullExtentLabelColor { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

FullExtentLabelFormat

Gets or sets the string format to use for displaying the start and end labels for the FullExtent.

Declaration
public string FullExtentLabelFormat { get; set; }
Property Value
Type Description
String
| Improve this Doc View Source

FullExtentStroke

Gets or sets the border color of the area on the slider track that indicates the FullExtent.

Declaration
public Brush? FullExtentStroke { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

IsEndTimePinned

Gets or sets a value indicating whether the end time of the CurrentExtent is locked into place.

Declaration
public bool IsEndTimePinned { get; set; }
Property Value
Type Description
Boolean
| Improve this Doc View Source

IsPlaying

Gets or sets a value indicating whether the time slider is animating playback.

Declaration
public bool IsPlaying { get; set; }
Property Value
Type Description
Boolean
| Improve this Doc View Source

IsStartTimePinned

Gets or sets a value indicating whether the start time of the CurrentExtent is locked into place.

Declaration
public bool IsStartTimePinned { get; set; }
Property Value
Type Description
Boolean
| Improve this Doc View Source

LabelMode

Gets or sets the mode to use for labels along the time slider.

Declaration
public TimeSliderLabelMode LabelMode { get; set; }
Property Value
Type Description
TimeSliderLabelMode
| Improve this Doc View Source

PlaybackButtonsFill

Gets or sets the fill color of the playback buttons.

Declaration
public Brush? PlaybackButtonsFill { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

PlaybackButtonsStroke

Gets or sets the border color of the playback buttons.

Declaration
public Brush? PlaybackButtonsStroke { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

PlaybackDirection

Gets or sets whether the current extent will move to the next or the previous time step during playback.

Declaration
public PlaybackDirection PlaybackDirection { get; set; }
Property Value
Type Description
PlaybackDirection
| Improve this Doc View Source

PlaybackInterval

Gets or sets the interval at which the time slider's current extent will move to the next or previous time step.

Declaration
public TimeSpan PlaybackInterval { get; set; }
Property Value
Type Description
TimeSpan
| Improve this Doc View Source

PlaybackLoopMode

Gets or sets the behavior when the current extent reaches the end of the slider during playback.

Declaration
public LoopMode PlaybackLoopMode { get; set; }
Property Value
Type Description
LoopMode
| Improve this Doc View Source

ThumbFill

Gets or sets the fill color of the thumbs.

Declaration
public Brush? ThumbFill { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

ThumbStroke

Gets or sets the border color of the thumbs.

Declaration
public Brush? ThumbStroke { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

TimeStepInterval

Gets or sets the time step intervals for the time slider. The slider thumbs will snap to and tick marks will be shown at this interval.

Declaration
public TimeValue? TimeStepInterval { get; set; }
Property Value
Type Description
Nullable<TimeValue>
| Improve this Doc View Source

TimeStepIntervalLabelColor

Gets or sets the color of the time step interval labels.

Declaration
public Brush? TimeStepIntervalLabelColor { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

TimeStepIntervalLabelFormat

Gets or sets the string format to use for displaying the labels for the tick marks representing each time step interval.

Declaration
public string TimeStepIntervalLabelFormat { get; set; }
Property Value
Type Description
String
| Improve this Doc View Source

TimeStepIntervalTickFill

Gets or sets the color of the slider's tickmarks.

Declaration
public Brush? TimeStepIntervalTickFill { get; set; }
Property Value
Type Description
Nullable<Brush>
| Improve this Doc View Source

TimeSteps

Gets the time steps that can be used to set the slider instance's current extent.

Declaration
public IReadOnlyList<DateTimeOffset> TimeSteps { get; }
Property Value
Type Description
IReadOnlyList<DateTimeOffset>

Methods

| Improve this Doc View Source

InitializeTimePropertiesAsync(ITimeAware)

Initializes the time slider's temporal properties based on the specified time-aware layer. Specifically, this will initialize FullExtent, TimeStepInterval, and CurrentExtent.

Declaration
public async Task InitializeTimePropertiesAsync(ITimeAware timeAwareLayer)
Parameters
Type Name Description
ITimeAware timeAwareLayer

The layer to use to initialize the time slider.

Returns
Type Description
Task

Task.

| Improve this Doc View Source

InitializeTimePropertiesAsync(Nullable<GeoView>)

Initializes the time slider's temporal properties based on the specified GeoView. Specifically, this will initialize FullExtent, TimeStepInterval, and CurrentExtent.

Declaration
public async Task InitializeTimePropertiesAsync(GeoView? geoView)
Parameters
Type Name Description
Nullable<GeoView> geoView

The GeoView to use to initialize the time-slider's properties.

Returns
Type Description
Task

Task.

| Improve this Doc View Source

InitializeTimeSteps(Int32)

Updates the time slider to have the specified number of time steps.

Declaration
public void InitializeTimeSteps(int count)
Parameters
Type Name Description
Int32 count

The number of time steps.

Remarks

This method divides the TimeSlider instance's FullExtent into the number of steps specified, updating the TimeStepInterval and TimeSteps properties. The method will attempt to set the interval to a TimeValue with the smallest duration and largest time unit that will fit evenly (i.e. without fractional duration values) into the TimeSlider's full extent. If there is no TimeValue that will fit evenly, then the interval will be initialized to the smallest possible fractional duration that is greater than one with a time unit of days or smaller.

Note that, if the TimeSlider instance's FullExtent property is not set, invoking this method will have no effect.

| Improve this Doc View Source

OnApplyTemplate()

When overridden in a derived class, is invoked whenever application code or internal processes (such as a rebuilding layout pass) call Esri.ArcGISRuntime.

Declaration
protected override void OnApplyTemplate()
| Improve this Doc View Source

OnGotFocus(RoutedEventArgs)

Called before the Esri.ArcGISRuntime event occurs.

Declaration
protected override void OnGotFocus(RoutedEventArgs e)
Parameters
Type Name Description
RoutedEventArgs e

The data for the event.

| Improve this Doc View Source

OnKeyDown(KeyRoutedEventArgs)

Called before the Esri.ArcGISRuntime event occurs.

Declaration
protected override void OnKeyDown(KeyRoutedEventArgs e)
Parameters
Type Name Description
KeyRoutedEventArgs e

The data for the event.

| Improve this Doc View Source

OnLostFocus(RoutedEventArgs)

Called before the Esri.ArcGISRuntime event occurs.

Declaration
protected override void OnLostFocus(RoutedEventArgs e)
Parameters
Type Name Description
RoutedEventArgs e

The data for the event.

| Improve this Doc View Source

OnPointerEntered(PointerRoutedEventArgs)

Declaration
protected override void OnPointerEntered(PointerRoutedEventArgs e)
Parameters
Type Name Description
PointerRoutedEventArgs e
| Improve this Doc View Source

OnPointerExited(PointerRoutedEventArgs)

Declaration
protected override void OnPointerExited(PointerRoutedEventArgs e)
Parameters
Type Name Description
PointerRoutedEventArgs e
| Improve this Doc View Source

OnPointerPressed(PointerRoutedEventArgs)

Declaration
protected override void OnPointerPressed(PointerRoutedEventArgs e)
Parameters
Type Name Description
PointerRoutedEventArgs e
| Improve this Doc View Source

StepBack(Int32)

Moves the slider position back by the specified number of time steps.

Declaration
public bool StepBack(int timeSteps = 1)
Parameters
Type Name Description
Int32 timeSteps

The number of steps to advance the slider's position.

Returns
Type Description
Boolean

true if succeeded, false if the position could not be moved as requested.

Remarks

When the current time extent represents a time range and neither the start nor end time are pinned, then the number of time steps between the start and end time will always be preserved. In that case, a value of false will be returned if the extent could not be moved by the specified number of time steps without going beyond the start of the time slider's full extent. If the current time extent is a time instant and either the start or end time are pinned, then the method call will attempt to move the unpinned end of the time extent. In that case, the method will return false if the unpinned end could not be moved by the specified number of steps without going beyond the start of the full extent or the pinned end of the current extent. In all cases, when the method returns false, the time slider's current extent will be unchanged.

| Improve this Doc View Source

StepForward(Int32)

Moves the slider position forward by the specified number of time steps.

Declaration
public bool StepForward(int timeSteps = 1)
Parameters
Type Name Description
Int32 timeSteps

The number of steps to advance the slider's position.

Returns
Type Description
Boolean

true if succeeded, false if the position could not be moved as requested.

Remarks

When the current time extent represents a time range and neither the start nor end time are pinned, then the number of time steps between the start and end time will always be preserved. In that case, a value of false will be returned if the extent could not be moved by the specified number of time steps without going beyond the end of the time slider's full extent. If the current time extent is a time instant and either the start or end time are pinned, then the method call will attempt to move the unpinned end of the time extent. In that case, the method will return false if the unpinned end could not be moved by the specified number of steps without going beyond the end of the full extent or the pinned end of the current extent. In all cases, when the method returns false, the time slider's current extent will be unchanged.

Events

| Improve this Doc View Source

CurrentExtentChanged

Occurs when the selected time extent has changed.

Declaration
public event EventHandler<TimeExtentChangedEventArgs> CurrentExtentChanged
Event Type
Type Description
EventHandler<TimeExtentChangedEventArgs>
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX