internal SLBarChartOptions Clone() { SLBarChartOptions bco = new SLBarChartOptions(); bco.iGapWidth = this.iGapWidth; bco.iGapDepth = this.iGapDepth; bco.byOverlap = this.byOverlap; return bco; }
internal SLBarChartOptions Clone() { SLBarChartOptions bco = new SLBarChartOptions(); bco.iGapWidth = this.iGapWidth; bco.iGapDepth = this.iGapDepth; bco.byOverlap = this.byOverlap; return(bco); }
internal void MergeOptions(SLBarChartOptions bco) { this.GapWidth = bco.GapWidth; this.GapDepth = bco.GapDepth; this.Overlap = bco.Overlap; }
private void PlotDataSeriesAsBarChart(int DataSeriesIndex, SLChartDataDisplayType DisplayType, SLBarChartOptions Options, bool IsPrimary, bool IsBar) { // the original chart is not combinable if (!this.IsCombinable) return; int index = DataSeriesIndex - 1; // out of bounds if (index < 0 || index >= this.PlotArea.DataSeries.Count) return; // is primary, no primary axes -> set primary axes // is primary, has primary axes -> do nothing // is secondary, no primary axes -> set primary axes, force as primary // is secondary, has primary axes, no secondary axes -> set secondary axes // is secondary, has primary axes, has secondary axes -> do nothing bool bIsPrimary = IsPrimary; if (!this.PlotArea.HasPrimaryAxes) { // no primary axes in the first place, so force primary axes bIsPrimary = true; this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisType = SLAxisType.Category; if (IsBar) { this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; } else { this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Bottom; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Left; } this.PlotArea.PrimaryTextAxis.CrossBetween = C.CrossBetweenValues.Between; this.PlotArea.PrimaryValueAxis.CrossBetween = C.CrossBetweenValues.Between; } else if (!bIsPrimary && this.PlotArea.HasPrimaryAxes && !this.PlotArea.HasSecondaryAxes) { this.PlotArea.HasSecondaryAxes = true; this.PlotArea.SecondaryTextAxis.AxisType = SLAxisType.Category; if (IsBar) { this.PlotArea.SecondaryTextAxis.AxisPosition = this.HasShownSecondaryTextAxis ? C.AxisPositionValues.Right : C.AxisPositionValues.Left; this.PlotArea.SecondaryValueAxis.AxisPosition = C.AxisPositionValues.Top; } else { this.PlotArea.SecondaryTextAxis.AxisPosition = this.HasShownSecondaryTextAxis ? C.AxisPositionValues.Top : C.AxisPositionValues.Bottom; this.PlotArea.SecondaryValueAxis.AxisPosition = C.AxisPositionValues.Right; } this.PlotArea.SecondaryTextAxis.CrossBetween = C.CrossBetweenValues.Between; this.PlotArea.SecondaryValueAxis.CrossBetween = C.CrossBetweenValues.Between; } SLDataSeriesChartType vType = SLDataSeriesChartType.BarChartBarPrimary; if (bIsPrimary) { if (IsBar) vType = SLDataSeriesChartType.BarChartBarPrimary; else vType = SLDataSeriesChartType.BarChartColumnPrimary; } else { if (IsBar) vType = SLDataSeriesChartType.BarChartBarSecondary; else vType = SLDataSeriesChartType.BarChartColumnSecondary; } int iChartType = (int)vType; if (this.PlotArea.UsedChartTypes[iChartType]) { // the chart is already used. if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); } else { this.PlotArea.UsedChartTypes[iChartType] = true; switch (DisplayType) { case SLChartDataDisplayType.Normal: this.PlotArea.UsedChartOptions[iChartType].BarDirection = IsBar ? C.BarDirectionValues.Bar : C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); break; case SLChartDataDisplayType.Stacked: this.PlotArea.UsedChartOptions[iChartType].BarDirection = IsBar ? C.BarDirectionValues.Bar : C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); break; case SLChartDataDisplayType.StackedMax: this.PlotArea.UsedChartOptions[iChartType].BarDirection = IsBar ? C.BarDirectionValues.Bar : C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); break; } this.PlotArea.DataSeries[index].ChartType = vType; } }
/// <summary> /// Plot a specific data series as a bar chart on the secondary axes. If there are no primary axes, it will be plotted on the primary axes instead. WARNING: Only weak checks done on whether the resulting combination chart is valid. Use with caution. /// </summary> /// <param name="DataSeriesIndex">The index of the data series. This is 1-based indexing, so it's 1 for the 1st data series, 2 for the 2nd data series and so on.</param> /// <param name="DisplayType">Chart display type. This corresponds to the 3 typical types in most charts: normal (or clustered), stacked and 100% stacked.</param> /// <param name="Options">Chart customization options.</param> public void PlotDataSeriesAsSecondaryBarChart(int DataSeriesIndex, SLChartDataDisplayType DisplayType, SLBarChartOptions Options) { this.PlotDataSeriesAsBarChart(DataSeriesIndex, DisplayType, Options, false, true); }
/// <summary> /// Plot a specific data series as a column chart on the primary axes. WARNING: Only weak checks done on whether the resulting combination chart is valid. Use with caution. /// </summary> /// <param name="DataSeriesIndex">The index of the data series. This is 1-based indexing, so it's 1 for the 1st data series, 2 for the 2nd data series and so on.</param> /// <param name="DisplayType">Chart display type. This corresponds to the 3 typical types in most charts: normal (or clustered), stacked and 100% stacked.</param> /// <param name="Options">Chart customization options.</param> public void PlotDataSeriesAsPrimaryColumnChart(int DataSeriesIndex, SLChartDataDisplayType DisplayType, SLBarChartOptions Options) { this.PlotDataSeriesAsBarChart(DataSeriesIndex, DisplayType, Options, true, false); }
/// <summary> /// Set a bar chart using one of the built-in bar chart types. /// </summary> /// <param name="ChartType">A built-in bar chart type.</param> /// <param name="Options">Chart customization options.</param> public void SetChartType(SLBarChartType ChartType, SLBarChartOptions Options) { // bar charts have their axis positions different from column charts. this.Is3D = SLChartTool.Is3DChart(ChartType); SLDataSeriesChartType vType; int iChartType; switch (ChartType) { case SLBarChartType.ClusteredBar: vType = SLDataSeriesChartType.BarChartBarPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedBar: vType = SLDataSeriesChartType.BarChartBarPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedBarMax: vType = SLDataSeriesChartType.BarChartBarPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.ClusteredBar3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedBar3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedBarMax3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.ClusteredHorizontalCylinder: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalCylinder: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalCylinderMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.ClusteredHorizontalCone: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalCone: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalConeMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.ClusteredHorizontalPyramid: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalPyramid: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; case SLBarChartType.StackedHorizontalPyramidMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Bar; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.PrimaryTextAxis.AxisPosition = C.AxisPositionValues.Left; this.PlotArea.PrimaryValueAxis.AxisPosition = C.AxisPositionValues.Bottom; break; } }
/// <summary> /// Set a column chart using one of the built-in column chart types. /// </summary> /// <param name="ChartType">A built-in column chart type.</param> /// <param name="Options">Chart customization options.</param> public void SetChartType(SLColumnChartType ChartType, SLBarChartOptions Options) { this.Is3D = SLChartTool.Is3DChart(ChartType); SLDataSeriesChartType vType; int iChartType; switch (ChartType) { case SLColumnChartType.ClusteredColumn: vType = SLDataSeriesChartType.BarChartColumnPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedColumn: vType = SLDataSeriesChartType.BarChartColumnPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedColumnMax: vType = SLDataSeriesChartType.BarChartColumnPrimary; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Overlap = 100; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.ClusteredColumn3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedColumn3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedColumnMax3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.Column3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = false; this.Perspective = 30; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Standard; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Box; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.HasDepthAxis = true; break; case SLColumnChartType.ClusteredCylinder: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedCylinder: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedCylinderMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.Cylinder3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = false; this.Perspective = 30; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Standard; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cylinder; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.HasDepthAxis = true; break; case SLColumnChartType.ClusteredCone: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedCone: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedConeMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.Cone3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = false; this.Perspective = 30; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Standard; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Cone; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.HasDepthAxis = true; break; case SLColumnChartType.ClusteredPyramid: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Clustered; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedPyramid: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Stacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.StackedPyramidMax: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = true; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.PercentStacked; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; break; case SLColumnChartType.Pyramid3D: this.RotateX = 15; this.RotateY = 20; this.RightAngleAxes = false; this.Perspective = 30; vType = SLDataSeriesChartType.Bar3DChart; this.IsCombinable = SLChartTool.IsCombinationChartFriendly(vType); iChartType = (int)vType; this.PlotArea.UsedChartTypes[iChartType] = true; this.PlotArea.UsedChartOptions[iChartType].BarDirection = C.BarDirectionValues.Column; this.PlotArea.UsedChartOptions[iChartType].BarGrouping = C.BarGroupingValues.Standard; this.PlotArea.UsedChartOptions[iChartType].Shape = C.ShapeValues.Pyramid; if (Options != null) this.PlotArea.UsedChartOptions[iChartType].MergeOptions(Options); this.PlotArea.SetDataSeriesChartType(vType); this.PlotArea.HasPrimaryAxes = true; this.PlotArea.HasDepthAxis = true; break; } }