/// <summary> /// Color property /// </summary> protected void GetChartElementColorProperty() { propertyStroke = new ChartElementColorProperty("Border Stroke Color"); propertyStroke.ValuePresenter.Value = Stroke; propertyStroke.SetChartElementPropertyValue += presenter => { Stroke = (SolidColorBrush)presenter.Value; SetStroke(); }; }
/// <summary> /// Fill Propeerty /// </summary> protected void GetChartElementFillProperty() { if (!(this is IShapeAble)) { return; } IShapeAble shapeAble = (IShapeAble)this; propertyFill = new ChartElementColorProperty("Fill Color"); if (shapeAble.Fill is SolidColorBrush) { propertyFill.ValuePresenter.Value = shapeAble.Fill; } propertyFill.SetChartElementPropertyValue += presenter => { shapeAble.Fill = (SolidColorBrush)presenter.Value; }; }