Exemplo n.º 1
0
		public static NewLegendItem BuildDefaultLegendItem(IPlotterElement chart)
		{
			DependencyObject dependencyChart = (DependencyObject)chart;

			NewLegendItem result = new NewLegendItem();
			SetCommonBindings(result, chart);
			return result;
		}
Exemplo n.º 2
0
        public static NewLegendItem BuildDefaultLegendItem(IPlotterElement chart)
        {
            DependencyObject dependencyChart = (DependencyObject)chart;

            NewLegendItem result = new NewLegendItem();

            SetCommonBindings(result, chart);
            return(result);
        }
Exemplo n.º 3
0
 public static void SetCommonBindings(NewLegendItem legendItem, object chart)
 {
     legendItem.DataContext = chart;
     legendItem.SetBinding(NewLegend.VisualContentProperty, new Binding {
         Path = new PropertyPath("(0)", NewLegend.VisualContentProperty)
     });
     legendItem.SetBinding(NewLegend.DescriptionProperty, new Binding {
         Path = new PropertyPath("(0)", NewLegend.DescriptionProperty)
     });
 }
Exemplo n.º 4
0
		public static void SetCommonBindings(NewLegendItem legendItem, object chart)
		{
			legendItem.DataContext = chart;
			legendItem.SetBinding(NewLegend.VisualContentProperty, new Binding { Path = new PropertyPath("(0)", NewLegend.VisualContentProperty) });
			legendItem.SetBinding(NewLegend.DescriptionProperty, new Binding { Path = new PropertyPath("(0)", NewLegend.DescriptionProperty) });
		}