Example #1
0
        //------------------------------------------------------
        private void AppliqueLegend(CLegendArea f, Legend ms)
        {
            ms.Alignment = CConvertisseurChartEnumToMSEnum.GetMSStringAlignment(f.Alignment);
            CChartLegendStyle sf = f.LegendStyle;

            ms.AutoFitMinFontSize = sf.AutoFitMinFontSize;
            ms.BackColor          = sf.BackColor;
            ms.BackGradientStyle  = CConvertisseurChartEnumToMSEnum.GetMSGradientStyle(sf.BackGradientStyle);
            ms.BackHatchStyle     = CConvertisseurChartEnumToMSEnum.GetMSChartHatchStyle(sf.HatchStyle);
            //ms.BackImage = sf.BackImage;
            ms.BackImageAlignment        = CConvertisseurChartEnumToMSEnum.GetMSChartImageAlignmentStyle(sf.BackImageAlignment);
            ms.BackImageTransparentColor = sf.BackImageTransparentColor;
            ms.BackImageWrapMode         = CConvertisseurChartEnumToMSEnum.GetMSChartImageWrapMode(sf.BackImageWrapMode);
            ms.BackSecondaryColor        = sf.BackSecondaryColor;
            ms.BorderColor       = sf.BorderColor;
            ms.BorderDashStyle   = CConvertisseurChartEnumToMSEnum.GetMSChartDashStyle(sf.BorderDashStyle);
            ms.BorderWidth       = sf.BorderWidth;
            ms.DockedToChartArea = f.DockedArea;
            ms.Docking           = CConvertisseurChartEnumToMSEnum.GetMSDocking(f.Docking);
            ms.Enabled           = sf.Enabled;
            if (sf.Font != null)
            {
                ms.Font = sf.Font;
            }
            ms.ForeColor               = sf.ForeColor;
            ms.InterlacedRows          = sf.InterlacedRows;
            ms.InterlacedRowsColor     = sf.InterlacedRowsColor;
            ms.IsDockedInsideChartArea = f.IsDockedInsideChartArea;
            ms.IsEquallySpacedItems    = sf.IsEquallySpacedItems;
            ms.IsTextAutoFit           = sf.IsTextAutoFit;
            ms.LegendItemOrder         = CConvertisseurChartEnumToMSEnum.GetMSLegendItemOrder(sf.LegendItemOrder);
            ms.LegendStyle             = CConvertisseurChartEnumToMSEnum.GetMSLegendStyle(sf.LegendStyle);
            ms.MaximumAutoSize         = f.MaximumAutoSize;
            ms.Name = f.LegendId;
            AppliquePosition(sf.Position, ms.Position);
            ms.ShadowColor       = sf.ShadowColor;
            ms.ShadowOffset      = sf.ShadowOffset;
            ms.TableStyle        = CConvertisseurChartEnumToMSEnum.GetMSLegendTableStyle(sf.TableStyle);
            ms.TextWrapThreshold = sf.TextWrapThreshold;
            ms.Title             = f.Title;
            ms.TitleAlignment    = CConvertisseurChartEnumToMSEnum.GetMSStringAlignment(f.TitleAlignment);
            ms.TitleBackColor    = f.TitleBackColor;
            if (f.TitleFont != null)
            {
                ms.TitleFont = f.TitleFont;
            }
            ms.TitleForeColor      = f.TitleForeColor;
            ms.TitleSeparator      = CConvertisseurChartEnumToMSEnum.GetMSLegendSeparatorStyle(f.TitleSeparator);
            ms.TitleSeparatorColor = f.TitleSeparatorColor;
        }
Example #2
0
        //------------------------------------------------------
        private void AppliqueAxe(CChartAxis f, Axis ms)
        {
            CChartAxisStyle sf = f.Style;

            ms.ArrowStyle              = CConvertisseurChartEnumToMSEnum.GetMSAxisArrowStyle(sf.ArrowStyle);
            ms.Enabled                 = CConvertisseurChartEnumToMSEnum.GetMSAxisEnabled(f.Enabled);
            ms.InterlacedColor         = sf.InterlacedColor;
            ms.Interval                = f.Interval;
            ms.IntervalAutoMode        = CConvertisseurChartEnumToMSEnum.GetMSIntervalAutoMode(f.IntervalAutoMode);
            ms.IntervalOffset          = f.IntervalOffset;
            ms.IntervalOffsetType      = CConvertisseurChartEnumToMSEnum.GetMSDateTimeIntervalType(f.IntervalOffsetType);
            ms.IntervalType            = CConvertisseurChartEnumToMSEnum.GetMSDateTimeIntervalType(f.IntervalType);
            ms.IsInterlaced            = sf.IsInterlaced;
            ms.IsLabelAutoFit          = f.IsLabelAutoFit;
            ms.IsLogarithmic           = f.IsLogarithmic;
            ms.IsMarginVisible         = f.IsMarginVisible;
            ms.IsMarksNextToAxis       = sf.IsMarksNextToAxis;
            ms.IsReversed              = f.IsReversed;
            ms.IsStartedFromZero       = f.IsStartedFromZero;
            ms.LabelAutoFitMaxFontSize = f.LabelAutoFitMaxFontSize;
            ms.LabelAutoFitMinFontSize = f.LabelAutoFitMinFontSize;
            ms.LabelAutoFitStyle       = CConvertisseurChartEnumToMSEnum.GetMSLabelAutoFitStyles(f.LabelAutoFitStyle);
            AppliqueLabelStyle(f.LabelStyle, ms.LabelStyle);
            ms.LineColor     = sf.LineColor;
            ms.LineDashStyle = CConvertisseurChartEnumToMSEnum.GetMSChartDashStyle(sf.LineDashStyle);
            ms.LineWidth     = sf.LineWidth;
            ms.LogarithmBase = f.LogarithmBase;
            AppliqueGridStyle(f.MajorGridStyle, ms.MajorGrid);
            AppliqueTickMarkerStyle(f.MajorTickMark, ms.MajorTickMark);
            AppliqueGridStyle(f.MinorGridStyle, ms.MinorGrid);
            AppliqueTickMarkerStyle(f.MinorTickMark, ms.MinorTickMark);
            ms.TextOrientation = CConvertisseurChartEnumToMSEnum.GetMSTextOrientation(f.TitleOrientation);
            ms.Title           = f.Title;
            ms.TitleAlignment  = CConvertisseurChartEnumToMSEnum.GetMSStringAlignment(f.TitleAlignment);
            if (f.TitleFont != null)
            {
                ms.TitleFont = f.TitleFont;
            }
            ms.TitleForeColor = f.TitleForeColor;
            AppliqueScrollBar(f.ScrollBar, ms.ScrollBar);
        }