
以下の画像は XamFinancialChart で財務オーバーレイの使用を表示します。オーバーレイには、BollingerBands および PriceChannel の 2 種類があります。
以下のコードは OverlayTypes を設定する方法を紹介します。
XAML の場合:
<ig:XamFinancialChart ItemsSource="{Binding}"
OverlayTypes="BollingerBands"
OverlayBrushes="Red"
OverlayOutlines="Green"
OverlayThickness="2" />
Visual Basic の場合:
Dim chart as New XamFinancialChart()
chart.OverlayTypes = New FinancialOverlayTypeCollection()
chart.OverlayTypes.Add(Infragistics.Controls.Charts.FinancialOverlayType.BollingerBands)
chart.OverlayBrushes = New Infragistics.BrushCollection()
Dim brush As SolidColorBrush = New SolidColorBrush()
brush.Color = Colors.Red;
chart.OverlayBrushes.Add(brush)
chart.OverlayOutlines = new Infragistics.BrushCollection()
Dim brush2 As SolidColorBrush = New SolidColorBrush()
brush2.Color = Colors.Green
chart.OverlayOutlines.Add(brush2)
chart.OverlayThickness = 2
C# の場合:
var chart = new XamFinancialChart();
chart.OverlayTypes = new FinancialOverlayTypeCollection();
chart.OverlayTypes.Add(Infragistics.Controls.Charts.FinancialOverlayType.BollingerBands);
chart.OverlayBrushes = new Infragistics.BrushCollection();
SolidColorBrush brush = new SolidColorBrush();
brush.Color = Colors.Red;
chart.OverlayBrushes.Add(brush);
chart.OverlayOutlines = new Infragistics.BrushCollection();
SolidColorBrush brush2 = new SolidColorBrush();
brush2.Color = Colors.Green;
chart.OverlayOutlines.Add(brush2);
chart.OverlayThickness = 2;