Class TimeRulerViewModel
A ViewModel class for the TimeRuler. Contains properties and methods which define the TimeRuler.
Inherited Members
Namespace: Telerik.Windows.Controls
Assembly: Telerik.Windows.Controls.ScheduleView.dll
Syntax
public class TimeRulerViewModel : ViewModelBase, INotifyPropertyChanged, IDisposable
Constructors
TimeRulerViewModel(IDateSpan, ITickProvider, ITickProvider, ITickProvider, TimeSpan)
Initializes a new instance of the TimeRulerViewModel class.
Declaration
public TimeRulerViewModel(IDateSpan dateSpan, ITickProvider minorTickLengthProvider, ITickProvider majorTickLengthProvider, ITickProvider groupTickLengthProvider, TimeSpan pixelLength)
Parameters
IDateSpan
dateSpan
The date span of the TimeRuler. |
ITickProvider
minorTickLengthProvider
The MinorTickLengthProvider. |
ITickProvider
majorTickLengthProvider
The MajorTickLengthProvider. |
ITickProvider
groupTickLengthProvider
The GroupTickLengthProvider. |
System.TimeSpan
pixelLength
The pixel length of the TimeRuler. |
Properties
Dates
Gets the Dates included in the TimeRuler.
Declaration
public IList<DateData> Dates { get; }
Property Value
System.Collections.Generic.IList<DateData>
|
DateSpan
Gets the DateSpan of TimeRuler.
Declaration
public IDateSpan DateSpan { get; }
Property Value
IDateSpan
|
LargeScaleMode
Gets the LargeScaleMode of the TimeRuler.
Declaration
public LargeScaleMode LargeScaleMode { get; }
Property Value
LargeScaleMode
|
MajorTickLength
Gets the MajorTickLength of the TimeRuler.
Declaration
public TimeSpan MajorTickLength { get; }
Property Value
System.TimeSpan
|
MinorTickLength
Gets the MinorTickLength of the TimeRuler.
Declaration
public TimeSpan MinorTickLength { get; }
Property Value
System.TimeSpan
|
PixelLength
The "zoom" level. Changing this will occasionally regenerate the ticks.
Declaration
public TimeSpan PixelLength { get; set; }
Property Value
System.TimeSpan
|
Methods
GenerateDates()
Generates the dates included in the TimeRuler.
Declaration
public void GenerateDates()
NextDate(DateTime)
Gets the next date of the TimeRuler based on the LargeScaleMode.
Declaration
public DateTime NextDate(DateTime date)
Parameters
System.DateTime
date
The date from which to start the calculation. |
Returns
System.DateTime
Returns the next date of the TimeRuler. |