Rating Class
Represents a rating control that allows the user to set or view a rating of an entity.
public class Rating : ItemsControl, IOrientedElement
- Inheritance:
- object Visual UIElement FrameworkElement Control ItemsControl object
- Implements:
- IOrientedElement
Constructors
Rating()
Initializes an instance of the class.
public Rating()
Properties
AverageValue
The average rating value currently presented by the control.
ClearValueCommand
The ICommand that can clear the value.
ItemCount
The number of items to display in the rating.
Orientation
The orientation of the element.
public Orientation Orientation { get; set; }
Property Value
- Orientation:
The default value is
Horizontal.
Value
The rating value currently presented by the control, if any.
Methods
OnCreateAutomationPeer()
Returns class-specific AutomationPeer implementations for the Windows Presentation Foundation (WPF) infrastructure.
protected override AutomationPeer OnCreateAutomationPeer()
Returns
- AutomationPeer:
The type-specific AutomationPeer implementation.
OnItemsChanged(NotifyCollectionChangedEventArgs)
Invoked when the Items property changes.
protected override void OnItemsChanged(NotifyCollectionChangedEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | NotifyCollectionChangedEventArgs | Information about the change. |
OnKeyDown(KeyEventArgs)
Invoked when the KeyDown event is received.
protected override void OnKeyDown(KeyEventArgs e)
| Parameter | Type | Description |
|---|---|---|
| e | KeyEventArgs | Information about the event. |
Events
ValueChanged
Occurs after the Value property value changes.
Fields
AverageValueProperty
Defines the AverageValue property.
public static readonly DependencyProperty AverageValueProperty
ItemCountProperty
Defines the ItemCount property.
public static readonly DependencyProperty ItemCountProperty
OrientationProperty
Defines the Orientation property.
public static readonly DependencyProperty OrientationProperty
ValueProperty
Defines the Value property.
public static readonly DependencyProperty ValueProperty