Exemplo n.º 1
0
        private static void OnStrokePropertyChanged(object sender, DependencyPropertyChangedEventArgs e)
        {
            MarkerGraph m = sender as MarkerGraph;

            m.StartRenderTask(false);
            foreach (var b in m.batches)
            {
                b.AddChangedProperties(new string[] { "Stroke" });
            }
            m.InvalidateMeasure();
        }
Exemplo n.º 2
0
        private static void OnTooltipTemplatePropertyChanged(object sender, DependencyPropertyChangedEventArgs e)
        {
            MarkerGraph m = sender as MarkerGraph;

            foreach (var b in m.batches)
            {
                b.Panel.Children.Clear();
            }
            m.StartRenderTask(false);
            m.InvalidateBounds();
        }
Exemplo n.º 3
0
        private static void OnSourcesChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            MarkerGraph    me  = (MarkerGraph)d;
            DataCollection col = (DataCollection)e.NewValue;

            if (e.OldValue != null)
            {
                ((DataCollection)e.OldValue).CollectionChanged -= me.OnSourceCollectionChanged;
                ((DataCollection)e.OldValue).DataSeriesUpdated -= me.OnSourceDataUpdated;
            }
            col.CollectionChanged += me.OnSourceCollectionChanged;
            col.DataSeriesUpdated += me.OnSourceDataUpdated;

            // Signal about total change of collection
            me.OnSourceCollectionChanged(me, new NotifyCollectionChangedEventArgs(NotifyCollectionChangedAction.Reset));
        }
Exemplo n.º 4
0
 /// <summary>
 /// Gets template for marker legend with information about Y <see cref="DataSeries"/>,
 /// <see cref="ColorSeries"/> and <see cref="SizeSeries"/>.
 /// </summary>
 /// <param name="mg">Marker graph to get template for.</param>
 /// <returns>A template used for legend of particular marker graph.</returns>
 public abstract DataTemplate GetColorSizeLegendTemplate(MarkerGraph mg);
Exemplo n.º 5
0
 /// <summary>
 /// Gets template for marker legend with information about Y <see cref="DataSeries"/>.
 /// </summary>
 /// <param name="mg">Marker graph to get template for.</param>
 /// <returns>A template used for legend of particular marker graph.</returns>
 public abstract DataTemplate GetYLegendTemplate(MarkerGraph mg);
Exemplo n.º 6
0
 /// <summary>
 /// Gets a template for markers.
 /// </summary>
 /// <param name="mg">Marker graph to get template for.</param>
 /// <returns>A template used for markers of particular marker graph.</returns>
 public abstract DataTemplate GetMarkerTemplate(MarkerGraph mg);