Class WaterfallSeries
WaterfallSeries displays its positive and negative data points using a set of bars.
Inheritance
Inherited Members
Namespace: Syncfusion.UI.Xaml.Charts
Assembly: Syncfusion.SfChart.WPF.dll
Syntax
public class WaterfallSeries : XyDataSeries, ICloneable, ISupportAxes2D, ISupportAxes, ISegmentSelectable, ISegmentSpacing
Examples
<syncfusion:WaterfallSeries ItemsSource="{Binding Data}" XBindingPath="Year" YBindingPath="Value">
</syncfusion:WaterfallSeries>
WaterfallSeries series1 = new WaterfallSeries();
series1.ItemsSource = viewmodel.Data;
series1.XBindingPath = "Year";
series1.YBindingPath = "Value";
chart.Series.Add(series1);
Constructors
WaterfallSeries()
Declaration
public WaterfallSeries()
Fields
AllowAutoSumProperty
Using a DependencyProperty as the backing store for AllowAutoSum. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty AllowAutoSumProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ConnectorLineStyleProperty
Using a DependencyProperty as the backing store for ConnectorLineStyle. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ConnectorLineStyleProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
NegativeSegmentBrushProperty
Using a DependencyProperty as the backing store for NegativeSegmentBrush. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty NegativeSegmentBrushProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SegmentSelectionBrushProperty
The DependencyProperty for SegmentSelectionBrush property.
Declaration
public static readonly DependencyProperty SegmentSelectionBrushProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SegmentSpacingProperty
The DependencyProperty for SegmentSpacing property.
Declaration
public static readonly DependencyProperty SegmentSpacingProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SelectedIndexProperty
The DependencyProperty for SelectedIndex property.
Declaration
public static readonly DependencyProperty SelectedIndexProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
ShowConnectorProperty
Using a DependencyProperty as the backing store for ShowConnector. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty ShowConnectorProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SummaryBindingPathProperty
Using a DependencyProperty as the backing store for SummaryBindingPath. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SummaryBindingPathProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
SummarySegmentBrushProperty
Using a DependencyProperty as the backing store for SummarySegmentBrush. This enables animation, styling, binding, etc...
Declaration
public static readonly DependencyProperty SummarySegmentBrushProperty
Field Value
Type |
---|
System.Windows.DependencyProperty |
Properties
AllowAutoSum
Gets or sets a value indicating whether to auto sum.
Declaration
public bool AllowAutoSum { get; set; }
Property Value
Type |
---|
System.Boolean |
ConnectorLineStyle
Gets or sets the style value that indicates the segments connector line visual representation.
Declaration
public Style ConnectorLineStyle { get; set; }
Property Value
Type |
---|
System.Windows.Style |
IsSideBySide
Gets a value indicating whether this series is placed side by side.
Declaration
protected override bool IsSideBySide { get; }
Property Value
Type | Description |
---|---|
System.Boolean | It returns |
Overrides
NegativeSegmentBrush
Gets or sets the brush value that indicates the interior color of negative segment.
Declaration
public Brush NegativeSegmentBrush { get; set; }
Property Value
Type |
---|
System.Windows.Media.Brush |
SegmentSelectionBrush
Gets or sets the interior (brush) for the selected segment(s).
Declaration
public Brush SegmentSelectionBrush { get; set; }
Property Value
Type | Description |
---|---|
System.Windows.Media.Brush | The System.Windows.Media.Brush value. |
SegmentSpacing
Gets or sets the spacing between the segments across the series in cluster mode.
Declaration
public double SegmentSpacing { get; set; }
Property Value
Type | Description |
---|---|
System.Double | The value ranges from 0 to 1. |
SelectedIndex
Gets or sets the index of the selected segment.
Declaration
public int SelectedIndex { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
|
ShowConnector
Gets or sets a value indicating whether the segments connector line is visible.
Declaration
public bool ShowConnector { get; set; }
Property Value
Type |
---|
System.Boolean |
SummaryBindingPath
Gets or sets string that indicates sum segment of series.
Declaration
public string SummaryBindingPath { get; set; }
Property Value
Type |
---|
System.String |
SummarySegmentBrush
Gets or sets the brush value that indicates the consolidated segment's interior.
Declaration
public Brush SummarySegmentBrush { get; set; }
Property Value
Type |
---|
System.Windows.Media.Brush |
Methods
CalculateSegmentSpacing(Double, Double, Double)
Method used to calculate the segment spacing.
Declaration
protected double CalculateSegmentSpacing(double spacing, double Right, double Left)
Parameters
Type | Name | Description |
---|---|---|
System.Double | spacing | Spacing |
System.Double | Right | Right |
System.Double | Left | Left |
Returns
Type |
---|
System.Double |
CloneSeries(DependencyObject)
Returns the instance of WaterfallSeries series.
Declaration
protected override DependencyObject CloneSeries(DependencyObject obj)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyObject | obj | object |
Returns
Type |
---|
System.Windows.DependencyObject |
Overrides
CreateSegment()
Creates an instance of series segment.
Declaration
protected override ChartSegment CreateSegment()
Returns
Type | Description |
---|---|
ChartSegment | Returns the instance of corresponding series segment. |
Overrides
Remarks
This customization is not supported for fast type series and technical indicators.
Examples
This sample shows how to call the CreateSegment() method to customize the line series segments.
public class LineSeriesExt : LineSeries
{
protected override ChartSegment CreateSegment()
{
return new LineSegmentExt();
}
}
public class LineSegmentExt : LineSegment
{
public override UIElement CreateVisual(Size size)
{
// Write your customization code here.
}
public override void Update(IChartTransformer transformer)
{
// Write your customization code here.
}
}
CreateSegments()
Creates the segments of WaterfallSeries.
Declaration
public override void CreateSegments()
Overrides
GeneratePoints()
Method for Generate Points for XYDataSeries.
Declaration
protected override void GeneratePoints()
Overrides
OnBindingPathChanged(DependencyPropertyChangedEventArgs)
Declaration
protected override void OnBindingPathChanged(DependencyPropertyChangedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
System.Windows.DependencyPropertyChangedEventArgs | args |
Overrides
OnDataSourceChanged(IEnumerable, IEnumerable)
Called when ItemsSource property changed.
Declaration
protected override void OnDataSourceChanged(IEnumerable oldValue, IEnumerable newValue)
Parameters
Type | Name | Description |
---|---|---|
System.Collections.IEnumerable | oldValue | old value |
System.Collections.IEnumerable | newValue | new value |
Overrides
OnSegmentCreated(WaterfallSegmentCreatedEventArgs)
Occurs when segment created for waterfall series.
Declaration
protected virtual void OnSegmentCreated(WaterfallSegmentCreatedEventArgs args)
Parameters
Type | Name | Description |
---|---|---|
WaterfallSegmentCreatedEventArgs | args | WaterfallSegmentCreatedEventArgs |
SetIndividualPoint(Int32, Object, Boolean)
Method implementation for set points to given index.
Declaration
protected override void SetIndividualPoint(int index, object obj, bool replace)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | index |
System.Object | obj | object |
System.Boolean | replace | bool |
Overrides
Events
SegmentCreated
Event raised while the segment have created.
Declaration
public event EventHandler<WaterfallSegmentCreatedEventArgs> SegmentCreated
Event Type
Type |
---|
System.EventHandler<WaterfallSegmentCreatedEventArgs> |
Explicit Interface Implementations
ISegmentSpacing.CalculateSegmentSpacing(Double, Double, Double)
Declaration
double ISegmentSpacing.CalculateSegmentSpacing(double spacing, double Right, double Left)
Parameters
Type | Name | Description |
---|---|---|
System.Double | spacing | |
System.Double | Right | |
System.Double | Left |
Returns
Type |
---|
System.Double |