AnnotationCreationModifier

StockSharp.Xaml.Charting.ChartModifiers

A custom ChartModifierBase to be used in conjunction with the AnnotationCollection. The AnnotationCreationModifier allows creation of annotations on mouse-click and drag. See the example of use CreateAnnotationsDynamically in the examples-suite

Inherits: ChartModifierBase

Properties

Annotation
public IAnnotation Annotation { get; }
value = annotationCreationModifier.Annotation

Gets the newly created IAnnotation

AnnotationStyle
public Style AnnotationStyle { get; set; }
value = annotationCreationModifier.AnnotationStyle
annotationCreationModifier.AnnotationStyle = value

Gets or sets a Style to apply to the annotation being created

AnnotationType
public Type AnnotationType { get; set; }
value = annotationCreationModifier.AnnotationType
annotationCreationModifier.AnnotationType = value

Gets or sets the type of the annotation to create

XAxisId
public string XAxisId { get; set; }
value = annotationCreationModifier.XAxisId
annotationCreationModifier.XAxisId = value

Gets or sets the ID of the X-Axis which this Annotation is measured against

YAxisId
public string YAxisId { get; set; }
value = annotationCreationModifier.YAxisId
annotationCreationModifier.YAxisId = value

Gets or sets the ID of the Y-Axis which this Annotation is measured against

Methods

CreateAnnotation
protected virtual AnnotationBase CreateAnnotation(Type annotationType, Style annotationStyle)
result = annotationCreationModifier.CreateAnnotation(annotationType, annotationStyle)

Creates an annotation of the specified Type and applies the style to it

annotationType
The Type of annotation to create
annotationStyle
The style to apply to the annotation

Returns: The annotation instance

OnAnnotationCreated
protected void OnAnnotationCreated()
annotationCreationModifier.OnAnnotationCreated()

Called when [annotation created].

OnIsEnabledChanged
protected override void OnIsEnabledChanged()
annotationCreationModifier.OnIsEnabledChanged()

Called when the IsEnabled property changes on this ChartModifierBase instance

OnModifierMouseMove
public override void OnModifierMouseMove(ModifierMouseArgs mouseEventArgs)
annotationCreationModifier.OnModifierMouseMove(mouseEventArgs)

Called when the Mouse is moved on the parent UltrachartSurface

mouseEventArgs
Arguments detailing the mouse move operation
OnModifierMouseUp
public override void OnModifierMouseUp(ModifierMouseArgs mouseButtonEventArgs)
annotationCreationModifier.OnModifierMouseUp(mouseButtonEventArgs)

Called when a Mouse Button is released on the parent UltrachartSurface

mouseButtonEventArgs
Arguments detailing the mouse button operation

Events

AnnotationCreated
public event EventHandler AnnotationCreated
annotationCreationModifier.AnnotationCreated += handler

Event raised when an annotation is created

Fields

XAxisIdProperty
public static readonly DependencyProperty XAxisIdProperty
value = AnnotationCreationModifier.XAxisIdProperty

Defines the XAxisId DependencyProperty

YAxisIdProperty
public static readonly DependencyProperty YAxisIdProperty
value = AnnotationCreationModifier.YAxisIdProperty

Defines the YAxisId DependencyProperty