Example #1
0
        internal SLTextAxis Clone()
        {
            var ta = new SLTextAxis(ShapeProperties.listThemeColors, Date1904);

            ta.Rotation     = Rotation;
            ta.Vertical     = Vertical;
            ta.Anchor       = Anchor;
            ta.AnchorCenter = AnchorCenter;
            ta.AxisId       = AxisId;
            ta.fLogBase     = fLogBase;
            ta.Orientation  = Orientation;
            ta.MaxAxisValue = MaxAxisValue;
            ta.MinAxisValue = MinAxisValue;
            ta.OtherAxisIsInReverseOrder = OtherAxisIsInReverseOrder;
            ta.OtherAxisCrossedAtMaximum = OtherAxisCrossedAtMaximum;
            ta.Delete             = Delete;
            ta.ForceAxisPosition  = ForceAxisPosition;
            ta.AxisPosition       = AxisPosition;
            ta.ShowMajorGridlines = ShowMajorGridlines;
            ta.MajorGridlines     = MajorGridlines.Clone();
            ta.ShowMinorGridlines = ShowMinorGridlines;
            ta.MinorGridlines     = MinorGridlines.Clone();
            ta.ShowTitle          = ShowTitle;
            ta.Title = Title.Clone();
            ta.HasNumberingFormat = HasNumberingFormat;
            ta.sFormatCode        = sFormatCode;
            ta.bSourceLinked      = bSourceLinked;
            ta.MajorTickMark      = MajorTickMark;
            ta.MinorTickMark      = MinorTickMark;
            ta.TickLabelPosition  = TickLabelPosition;
            ta.ShapeProperties    = ShapeProperties.Clone();
            ta.CrossingAxis       = CrossingAxis;
            ta.IsCrosses          = IsCrosses;
            ta.Crosses            = Crosses;
            ta.CrossesAt          = CrossesAt;
            ta.OtherAxisIsCrosses = OtherAxisIsCrosses;
            ta.OtherAxisCrosses   = OtherAxisCrosses;
            ta.OtherAxisCrossesAt = OtherAxisCrossesAt;

            ta.Date1904              = Date1904;
            ta.AxisType              = AxisType;
            ta.AutoLabeled           = AutoLabeled;
            ta.iTickLabelSkip        = iTickLabelSkip;
            ta.iTickMarkSkip         = iTickMarkSkip;
            ta.LabelAlignment        = LabelAlignment;
            ta.iLabelOffset          = iLabelOffset;
            ta.ValueMajorUnit        = ValueMajorUnit;
            ta.ValueMinorUnit        = ValueMinorUnit;
            ta.BuiltInUnitValues     = BuiltInUnitValues;
            ta.ShowDisplayUnitsLabel = ShowDisplayUnitsLabel;
            ta.BaseUnit              = BaseUnit;
            ta.iMajorUnit            = iMajorUnit;
            ta.vMajorTimeUnit        = vMajorTimeUnit;
            ta.iMinorUnit            = iMinorUnit;
            ta.vMinorTimeUnit        = vMinorTimeUnit;
            ta.CrossBetween          = CrossBetween;
            ta.NoMultiLevelLabels    = NoMultiLevelLabels;

            return(ta);
        }
        internal SLPlotArea(List <Color> ThemeColors, bool Date1904, bool IsStylish = false)
        {
            InternalChartType = SLInternalChartType.Bar;

            var NumberOfChartTypes = Enum.GetNames(typeof(SLDataSeriesChartType)).Length;

            UsedChartTypes   = new bool[NumberOfChartTypes];
            UsedChartOptions = new SLChartOptions[NumberOfChartTypes];
            for (var i = 0; i < NumberOfChartTypes; ++i)
            {
                UsedChartTypes[i]   = false;
                UsedChartOptions[i] = new SLChartOptions(ThemeColors);
            }
            DataSeries = new List <SLDataSeries>();

            Layout = new SLLayout();

            PrimaryTextAxis    = new SLTextAxis(ThemeColors, Date1904, IsStylish);
            PrimaryValueAxis   = new SLValueAxis(ThemeColors, IsStylish);
            DepthAxis          = new SLSeriesAxis(ThemeColors, IsStylish);
            SecondaryTextAxis  = new SLTextAxis(ThemeColors, Date1904, IsStylish);
            SecondaryValueAxis = new SLValueAxis(ThemeColors, IsStylish);

            HasPrimaryAxes   = false;
            HasDepthAxis     = false;
            HasSecondaryAxes = false;

            ShowDataTable = false;
            DataTable     = new SLDataTable(ThemeColors, IsStylish);

            ShapeProperties = new SLShapeProperties(ThemeColors);
            if (IsStylish)
            {
                ShapeProperties.Fill.SetNoFill();
                ShapeProperties.Outline.SetNoLine();
            }
        }