<chart:SfChart.Series>
<chart:SplineAreaSeries StrokeWidth="3" StrokeColor="#FF0080DF" ItemsSource="{Binding Data}" XBindingPath="XValue" YBindingPath="YValue">
<chart:SplineAreaSeries.ColorModel>
<chart:ChartColorModel Palette="Custom">
<chart:ChartColorModel.CustomGradientColors>
<chart:ChartGradientColor StartPoint="0.5,1" EndPoint="0.5,0">
<chart:ChartGradientColor.GradientStops>
<chart:ChartGradientStop Color="White" Offset= "0"/>
<chart:ChartGradientStop Color="#FF0080DF" Offset= "1"/>
</chart:ChartGradientColor.GradientStops>
</chart:ChartGradientColor>
</chart:ChartColorModel.CustomGradientColors>
</chart:ChartColorModel>
</chart:SplineAreaSeries.ColorModel>
</chart:SplineAreaSeries>
</chart:SfChart.Series>
|
<chart:SplineAreaSeries StrokeWidth="3" StrokeColor="#FF0080DF" EnableTooltip="True" ItemsSource="{Binding Data}" XBindingPath="XValue" YBindingPath="YValue">
</chart:SplineAreaSeries>
|
<chart:SplineAreaSeries StrokeWidth="3" StrokeColor="#FF0080DF" EnableTooltip="True" ItemsSource="{Binding Data}" XBindingPath="XValue" YBindingPath="YValue">
</chart:SplineAreaSeries>
|
chart.ColorModel.Palette = ChartColorPalette.Custom;
ChartGradientColor gradientColor = new ChartGradientColor() { StartPoint = new Point(0.5, 1), EndPoint = new Point(0.5, 0) };
ChartGradientStop stop1 = new ChartGradientStop() { Color = Color.White, Offset = 0 };
ChartGradientStop stop2 = new ChartGradientStop() { Color = Color.DarkGreen, Offset = 1 };
gradientColor.GradientStops.Add(stop1);
gradientColor.GradientStops.Add(stop2);
chart.ColorModel.CustomGradientColors.Add(gradientColor);
|