LineAnnotationWithLabelsBase
Provides a base class for HorizontalLineAnnotation, VerticalLineAnnotation
Inherits: LineAnnotation
Constructors
protected LineAnnotationWithLabelsBase()
lineAnnotationWithLabelsBase = LineAnnotationWithLabelsBase()
Initializes a new instance of the LineAnnotationWithLabelsBase class.
Properties
public ObservableCollection<AnnotationLabel> AnnotationLabels { get; set; }
value = lineAnnotationWithLabelsBase.AnnotationLabels
lineAnnotationWithLabelsBase.AnnotationLabels = value
Gets or sets a collection of annotation labels
protected IComparable DefaultLabelValue { get; }
value = lineAnnotationWithLabelsBase.DefaultLabelValue
Gets or sets value which labels will be bound to
protected string DefaultTextFormatting { get; }
value = lineAnnotationWithLabelsBase.DefaultTextFormatting
Gets the default text formatting value
protected string FormattedLabel { get; }
value = lineAnnotationWithLabelsBase.FormattedLabel
Gets the formatted label value
public LabelPlacement LabelPlacement { get; set; }
value = lineAnnotationWithLabelsBase.LabelPlacement
lineAnnotationWithLabelsBase.LabelPlacement = value
Gets or sets placement for the default label
public string LabelTextFormatting { get; set; }
value = lineAnnotationWithLabelsBase.LabelTextFormatting
lineAnnotationWithLabelsBase.LabelTextFormatting = value
Gets or sets formatting string which is applied to all annotation labels
public IComparable LabelValue { get; set; }
value = lineAnnotationWithLabelsBase.LabelValue
lineAnnotationWithLabelsBase.LabelValue = value
Gets or sets a value for the default label
public bool ShowLabel { get; set; }
value = lineAnnotationWithLabelsBase.ShowLabel
lineAnnotationWithLabelsBase.ShowLabel = value
Gets or sets value, indicating whether show the default label or not
Methods
public AnnotationLabel AddLabel()
result = lineAnnotationWithLabelsBase.AddLabel()
Adds new label to AnnotationLabels
Returns: Label which has been created
protected virtual void ApplyPlacement(AnnotationLabel label, LabelPlacement placement)
lineAnnotationWithLabelsBase.ApplyPlacement(label, placement)
Positions the AnnotationLabel using the value of the LabelPlacement enum
- label
- The label to place
- placement
- Placement arguments
protected virtual void Attach(AnnotationLabel label)
lineAnnotationWithLabelsBase.Attach(label)
Called internally to attach an AnnotationLabel to the current instance
- label
- The AnnotationLabel to attach
protected void AttachLabels(IEnumerable<AnnotationLabel> labels)
lineAnnotationWithLabelsBase.AttachLabels(labels)
Adds a collection of AnnotationLabel instances to the LineAnnotationWithLabelsBase
- labels
- The collection of labels to add
protected virtual void Detach(AnnotationLabel label)
lineAnnotationWithLabelsBase.Detach(label)
Detaches the AnnotationLabel from the current LineAnnotationWithLabelsBase
- label
- The label to detach
protected void DetachLabels(IEnumerable<AnnotationLabel> labels)
lineAnnotationWithLabelsBase.DetachLabels(labels)
Removes a collection of AnnotationLabel instances to the LineAnnotationWithLabelsBase
- labels
- The collection of labels to remove
protected override Cursor GetSelectedCursor()
result = lineAnnotationWithLabelsBase.GetSelectedCursor()
Gets the Cursor to use for the annotation when selected
public abstract IAxis GetUsedAxis()
result = lineAnnotationWithLabelsBase.GetUsedAxis()
Returns axis, which current annotation shows data value for
public void InvalidateLabel(AnnotationLabel annotationLabel)
lineAnnotationWithLabelsBase.InvalidateLabel(annotationLabel)
Invalidates annotation label
- annotationLabel
- Label to invalidate
public override bool IsPointWithinBounds(Point point)
result = lineAnnotationWithLabelsBase.IsPointWithinBounds(point)
Returns true if the Point is within the bounds of the current IHitTestable element
- point
- The point to test
Returns: true if the Point is within the bounds
protected override void MakeInvisible()
lineAnnotationWithLabelsBase.MakeInvisible()
Hides current instance of LineAnnotationWithLabelsBase
protected override void MakeVisible(AnnotationCoordinates coordinates)
lineAnnotationWithLabelsBase.MakeVisible(coordinates)
Hides current instance of LineAnnotationWithLabelsBase
public override void OnApplyTemplate()
lineAnnotationWithLabelsBase.OnApplyTemplate()
When overridden in a derived class, is invoked whenever application code or internal processes call ApplyTemplate.
public override void OnAttached()
lineAnnotationWithLabelsBase.OnAttached()
Called when the Annotation is attached to parent surface
protected override void OnAxisAlignmentChanged(IAxis axis, AxisAlignment oldAlignment)
lineAnnotationWithLabelsBase.OnAxisAlignmentChanged(axis, oldAlignment)
Virtual method to override if you wish to be notified that the AxisAlignment has changed
- axis
- oldAlignment
protected override void OnXAxesCollectionChanged(object sender, NotifyCollectionChangedEventArgs args)
lineAnnotationWithLabelsBase.OnXAxesCollectionChanged(sender, args)
Virtual method to override if you wish to be notified that the parent XAxes has changed
protected override void OnXAxisIdChanged()
lineAnnotationWithLabelsBase.OnXAxisIdChanged()
Virtual method to override if you wish to be notified that the XAxisId has changed
protected override void OnYAxesCollectionChanged(object sender, NotifyCollectionChangedEventArgs args)
lineAnnotationWithLabelsBase.OnYAxesCollectionChanged(sender, args)
Virtual method to override if you wish to be notified that the parent YAxes has changed
protected override void OnYAxisIdChanged()
lineAnnotationWithLabelsBase.OnYAxisIdChanged()
Virtual method to override if you wish to be notified that the YAxisId has changed
protected virtual void PlaceAxisLabel(IAxis axis, AnnotationLabel axisLabel, Point offset)
lineAnnotationWithLabelsBase.PlaceAxisLabel(axis, axisLabel, offset)
Place on ModifierAxisCanvas of appropriate axis at position.
protected void TryPlaceAxisLabels(Point offset)
lineAnnotationWithLabelsBase.TryPlaceAxisLabels(offset)
Try to place all annotation labels on ModifierAxisCanvas of appropriate axis at position.
Fields
public static readonly DependencyProperty AnnotationLabelsProperty
value = LineAnnotationWithLabelsBase.AnnotationLabelsProperty
Defines the AnnotationLabels Property
protected internal static readonly DependencyProperty DefaultLabelValueProperty
value = LineAnnotationWithLabelsBase.DefaultLabelValueProperty
Defines the DefaultLabelValue Property
protected static readonly DependencyProperty DefaultTextFormattingProperty
value = LineAnnotationWithLabelsBase.DefaultTextFormattingProperty
Defines the DefaultTextFormatting Property
public static readonly DependencyProperty FormattedLabelProperty
value = LineAnnotationWithLabelsBase.FormattedLabelProperty
Defines the FormattedLabel Property
public static readonly DependencyProperty LabelPlacementProperty
value = LineAnnotationWithLabelsBase.LabelPlacementProperty
Defines the LabelPlacement Property
public static readonly DependencyProperty LabelTextFormattingProperty
value = LineAnnotationWithLabelsBase.LabelTextFormattingProperty
Defines the LabelTextFormatting Property
public static readonly DependencyProperty LabelValueProperty
value = LineAnnotationWithLabelsBase.LabelValueProperty
Defines the LabelValue Property
public static readonly DependencyProperty ShowLabelProperty
value = LineAnnotationWithLabelsBase.ShowLabelProperty
Defines the ShowLabel Property