当前位置: 首页>>代码示例>>C#>>正文


C# SLThemeColorIndexValues类代码示例

本文整理汇总了C#中SLThemeColorIndexValues的典型用法代码示例。如果您正苦于以下问题:C# SLThemeColorIndexValues类的具体用法?C# SLThemeColorIndexValues怎么用?C# SLThemeColorIndexValues使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


SLThemeColorIndexValues类属于命名空间,在下文中一共展示了SLThemeColorIndexValues类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: SetPatternFill

 /// <summary>
 /// Set a pattern fill with a preset pattern, foreground color and background color.
 /// </summary>
 /// <param name="PresetPattern">A preset fill pattern.</param>
 /// <param name="ForegroundColorTheme">The theme color to be used for the foreground.</param>
 /// <param name="BackgroundColor">The color to be used for the background.</param>
 public void SetPatternFill(A.PresetPatternValues PresetPattern, SLThemeColorIndexValues ForegroundColorTheme, System.Drawing.Color BackgroundColor)
 {
     this.Type = SLFillType.PatternFill;
     this.PatternPreset = PresetPattern;
     this.PatternForegroundColor.SetColor(ForegroundColorTheme, 0, 0);
     this.PatternBackgroundColor.SetColor(BackgroundColor, 0);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:13,代码来源:SLFill.cs

示例2: SetGradient

 /// <summary>
 /// Set a gradient fill given the shading style and 2 colors.
 /// </summary>
 /// <param name="ShadingStyle">The gradient shading style.</param>
 /// <param name="Color1Theme">The first color as one of the theme colors.</param>
 /// <param name="Color1Tint">The tint applied to the first theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 /// <param name="Color2Theme">The second color as one of the theme colors.</param>
 /// <param name="Color2Tint">The tint applied to the second theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 public void SetGradient(SLGradientShadingStyleValues ShadingStyle, SLThemeColorIndexValues Color1Theme, double Color1Tint, SLThemeColorIndexValues Color2Theme, double Color2Tint)
 {
     HasBeenAssignedValues = true;
     UsePatternFill = false;
     this.gfReal.SetGradientFill(ShadingStyle, Color1Theme, Color1Tint, Color2Theme, Color2Tint);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:14,代码来源:SLFill.cs

示例3: SetForegroundThemeColor

 /// <summary>
 /// Set the foreground color with a theme color.
 /// </summary>
 /// <param name="ThemeColorIndex">The theme color to be used.</param>
 public void SetForegroundThemeColor(SLThemeColorIndexValues ThemeColorIndex)
 {
     this.clrForegroundColor.SetThemeColor(ThemeColorIndex);
     HasForegroundColor = (clrForegroundColor.Color.IsEmpty) ? false : true;
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:9,代码来源:SLFill.cs

示例4: SetPattern

 /// <summary>
 /// Set the pattern type, foreground color and background color of the fill pattern.
 /// </summary>
 /// <param name="PatternType">The pattern type. Default value is None.</param>
 /// <param name="ForegroundColor">The color to be used for the foreground.</param>
 /// <param name="BackgroundColorTheme">The theme color to be used for the background.</param>
 /// <param name="BackgroundColorTint">The tint applied to the background theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 public void SetPattern(PatternValues PatternType, System.Drawing.Color ForegroundColor, SLThemeColorIndexValues BackgroundColorTheme, double BackgroundColorTint)
 {
     HasBeenAssignedValues = true;
     UsePatternFill = true;
     pfReal.PatternType = PatternType;
     pfReal.ForegroundColor = ForegroundColor;
     pfReal.SetBackgroundThemeColor(BackgroundColorTheme, BackgroundColorTint);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:15,代码来源:SLFill.cs

示例5: SetGradientFill

        /// <summary>
        /// Set a gradient fill given the shading style and 2 colors.
        /// </summary>
        /// <param name="ShadingStyle">The gradient shading style.</param>
        /// <param name="Color1Theme">The first color as one of the theme colors.</param>
        /// <param name="Color1Tint">The tint applied to the first theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        /// <param name="Color2Theme">The second color as one of the theme colors.</param>
        /// <param name="Color2Tint">The tint applied to the second theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        public void SetGradientFill(SLGradientShadingStyleValues ShadingStyle, SLThemeColorIndexValues Color1Theme, double Color1Tint, SLThemeColorIndexValues Color2Theme, double Color2Tint)
        {
            SLColor clr1 = new SLColor(this.listThemeColors, this.listIndexedColors);
            SLColor clr2 = new SLColor(this.listThemeColors, this.listIndexedColors);

            clr1.SetThemeColor(Color1Theme, Color1Tint);
            clr2.SetThemeColor(Color2Theme, Color2Tint);

            SetGradientFill(ShadingStyle, clr1, clr2);
        }
开发者ID:mousetwentytwo,项目名称:test,代码行数:18,代码来源:SLFill.cs

示例6: SetPatternForegroundColor

 /// <summary>
 /// Set the foreground color with one of the theme colors.
 /// </summary>
 /// <param name="ColorTheme">The theme color to be used.</param>
 public void SetPatternForegroundColor(SLThemeColorIndexValues ColorTheme)
 {
     HasBeenAssignedValues = true;
     UsePatternFill = true;
     pfReal.SetForegroundThemeColor(ColorTheme);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:10,代码来源:SLFill.cs

示例7: SetThemeColor

 /// <summary>
 /// Set a color using a theme color.
 /// </summary>
 /// <param name="ThemeColorIndex">The theme color to be used.</param>
 public void SetThemeColor(SLThemeColorIndexValues ThemeColorIndex)
 {
     int index = (int)ThemeColorIndex;
     if (index >= 0 && index < this.listThemeColors.Count)
     {
         this.clrDisplay = this.listThemeColors[index];
     }
     this.Auto = null;
     this.Indexed = null;
     this.Rgb = null;
     this.Theme = (uint)ThemeColorIndex;
     this.Tint = null;
 }
开发者ID:rahmatsyaparudin,项目名称:KP_Raport,代码行数:17,代码来源:SLColor.cs

示例8: SetColor

        /// <summary>
        /// 
        /// </summary>
        /// <param name="Color">The theme color used.</param>
        /// <param name="Tint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        /// <param name="Transparency"></param>
        internal void SetColor(SLThemeColorIndexValues Color, double Tint, decimal Transparency)
        {
            this.IsRgbColorModelHex = false;
            switch (Color)
            {
                case SLThemeColorIndexValues.Dark1Color:
                    this.SchemeColor = A.SchemeColorValues.Dark1;
                    break;
                case SLThemeColorIndexValues.Light1Color:
                    this.SchemeColor = A.SchemeColorValues.Light1;
                    break;
                case SLThemeColorIndexValues.Dark2Color:
                    this.SchemeColor = A.SchemeColorValues.Dark2;
                    break;
                case SLThemeColorIndexValues.Light2Color:
                    this.SchemeColor = A.SchemeColorValues.Light2;
                    break;
                case SLThemeColorIndexValues.Accent1Color:
                    this.SchemeColor = A.SchemeColorValues.Accent1;
                    break;
                case SLThemeColorIndexValues.Accent2Color:
                    this.SchemeColor = A.SchemeColorValues.Accent2;
                    break;
                case SLThemeColorIndexValues.Accent3Color:
                    this.SchemeColor = A.SchemeColorValues.Accent3;
                    break;
                case SLThemeColorIndexValues.Accent4Color:
                    this.SchemeColor = A.SchemeColorValues.Accent4;
                    break;
                case SLThemeColorIndexValues.Accent5Color:
                    this.SchemeColor = A.SchemeColorValues.Accent5;
                    break;
                case SLThemeColorIndexValues.Accent6Color:
                    this.SchemeColor = A.SchemeColorValues.Accent6;
                    break;
                case SLThemeColorIndexValues.Hyperlink:
                    this.SchemeColor = A.SchemeColorValues.Hyperlink;
                    break;
                case SLThemeColorIndexValues.FollowedHyperlinkColor:
                    this.SchemeColor = A.SchemeColorValues.FollowedHyperlink;
                    break;
            }
            this.Tint = (decimal)Tint;
            this.Transparency = Transparency;

            int index = (int)Color;
            if (index >= 0 && index < this.listThemeColors.Count)
            {
                this.clrDisplayColor = System.Drawing.Color.FromArgb(255, this.listThemeColors[index]);
                if (this.Tint != 0)
                {
                    this.clrDisplayColor = SLTool.ToColor(this.clrDisplayColor, Tint);
                }
            }
        }
开发者ID:mousetwentytwo,项目名称:test,代码行数:61,代码来源:SLColorTransform.cs

示例9: SetTabColor

 /// <summary>
 /// Sets the tab color of the sheet.
 /// </summary>
 /// <param name="TabColor">The theme color to be used.</param>
 /// <param name="Tint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 public void SetTabColor(SLThemeColorIndexValues TabColor, double Tint)
 {
     this.SheetProperties.clrTabColor.SetThemeColor(TabColor, Tint);
     this.SheetProperties.HasTabColor = (this.SheetProperties.clrTabColor.Color.IsEmpty) ? false : true;
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:10,代码来源:SLPageSettings.cs

示例10: AppendGradientStop

 /// <summary>
 /// Append a gradient stop given a color, the color's transparency and the position of gradient stop.
 /// </summary>
 /// <param name="Color">The theme color to be used.</param>
 /// <param name="Tint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 /// <param name="Transparency">Transparency of the color ranging from 0% to 100%. Accurate to 1/1000 of a percent.</param>
 /// <param name="Position">The position in percentage ranging from 0% to 100%. Accurate to 1/1000 of a percent.</param>
 public void AppendGradientStop(SLThemeColorIndexValues Color, double Tint, decimal Transparency, decimal Position)
 {
     this.GradientColor.AppendGradientStop(Color, Tint, Transparency, Position);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:11,代码来源:SLLinePropertiesType.cs

示例11: SetSolidLine

 /// <summary>
 /// Set a solid line given a color for the line and the transparency of the color.
 /// </summary>
 /// <param name="Color">The theme color to be used.</param>
 /// <param name="Tint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 /// <param name="Transparency">Transparency of the color ranging from 0% to 100%. Accurate to 1/1000 of a percent.</param>
 public void SetSolidLine(SLThemeColorIndexValues Color, double Tint, decimal Transparency)
 {
     this.UseSolidLine = true;
     this.SolidColor.SetColor(Color, Tint, Transparency);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:11,代码来源:SLLinePropertiesType.cs

示例12: SetExtrusionColor

 /// <summary>
 /// Set the extrusion (or depth) color.
 /// </summary>
 /// <param name="Color">The theme color to be used.</param>
 /// <param name="Tint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 public void SetExtrusionColor(SLThemeColorIndexValues Color, double Tint)
 {
     this.clrExtrusionColor.SetColor(Color, Tint, 0);
     this.HasExtrusionColor = true;
 }
开发者ID:rahmatsyaparudin,项目名称:KP_Raport,代码行数:10,代码来源:SLFormat3D.cs

示例13: SetCustom2ColorScale

        /// <summary>
        /// Set a custom 2-color scale.
        /// </summary>
        /// <param name="MinType">The conditional format type for the minimum.</param>
        /// <param name="MinValue">The value for the minimum. If <paramref name="MinType"/> is Value, you can just set this to "0".</param>
        /// <param name="MinColor">The theme color for the minimum.</param>
        /// <param name="MinColorTint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        /// <param name="MaxType">The conditional format type for the maximum.</param>
        /// <param name="MaxValue">The value for the maximum. If <paramref name="MaxType"/> is Value, you can just set this to "0".</param>
        /// <param name="MaxColor">The color for the maximum.</param>
        public void SetCustom2ColorScale(SLConditionalFormatMinMaxValues MinType, string MinValue, SLThemeColorIndexValues MinColor, double MinColorTint,
            SLConditionalFormatMinMaxValues MaxType, string MaxValue, System.Drawing.Color MaxColor)
        {
            List<System.Drawing.Color> listempty = new List<System.Drawing.Color>();
            SLColor minclr = new SLColor(listempty, listempty);
            if (MinColorTint == 0) minclr.SetThemeColor(MinColor);
            else minclr.SetThemeColor(MinColor, MinColorTint);
            SLColor maxclr = new SLColor(listempty, listempty);
            maxclr.Color = MaxColor;

            SLColor midclr = new SLColor(listempty, listempty);
            this.SetCustomColorScale(MinType, MinValue, minclr, false, SLConditionalFormatRangeValues.Percentile, "", midclr, MaxType, MaxValue, maxclr);
        }
开发者ID:rahmatsyaparudin,项目名称:KP_Raport,代码行数:23,代码来源:SLConditionalFormatting.cs

示例14: SetCustom3ColorScale

        /// <summary>
        /// Set a custom 3-color scale.
        /// </summary>
        /// <param name="MinType">The conditional format type for the minimum.</param>
        /// <param name="MinValue">The value for the minimum. If <paramref name="MinType"/> is Value, you can just set this to "0".</param>
        /// <param name="MinColor">The theme color for the minimum.</param>
        /// <param name="MinColorTint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        /// <param name="MidPointType">The conditional format type for the midpoint.</param>
        /// <param name="MidPointValue">The value for the midpoint.</param>
        /// <param name="MidPointColor">The theme color for the midpoint.</param>
        /// <param name="MidPointColorTint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        /// <param name="MaxType">The conditional format type for the maximum.</param>
        /// <param name="MaxValue">The value for the maximum. If <paramref name="MaxType"/> is Value, you can just set this to "0".</param>
        /// <param name="MaxColor">The theme color for the maximum.</param>
        /// <param name="MaxColorTint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
        public void SetCustom3ColorScale(SLConditionalFormatMinMaxValues MinType, string MinValue, SLThemeColorIndexValues MinColor, double MinColorTint,
            SLConditionalFormatRangeValues MidPointType, string MidPointValue, SLThemeColorIndexValues MidPointColor, double MidPointColorTint,
            SLConditionalFormatMinMaxValues MaxType, string MaxValue, SLThemeColorIndexValues MaxColor, double MaxColorTint)
        {
            List<System.Drawing.Color> listempty = new List<System.Drawing.Color>();
            SLColor minclr = new SLColor(listempty, listempty);
            if (MinColorTint == 0) minclr.SetThemeColor(MinColor);
            else minclr.SetThemeColor(MinColor, MinColorTint);
            SLColor maxclr = new SLColor(listempty, listempty);
            if (MaxColorTint == 0) maxclr.SetThemeColor(MaxColor);
            else maxclr.SetThemeColor(MaxColor, MaxColorTint);

            SLColor midclr = new SLColor(listempty, listempty);
            if (MidPointColorTint == 0) midclr.SetThemeColor(MidPointColor);
            else midclr.SetThemeColor(MidPointColor, MidPointColorTint);
            this.SetCustomColorScale(MinType, MinValue, minclr, true, MidPointType, MidPointValue, midclr, MaxType, MaxValue, maxclr);
        }
开发者ID:rahmatsyaparudin,项目名称:KP_Raport,代码行数:32,代码来源:SLConditionalFormatting.cs

示例15: AppendGradientStop

 /// <summary>
 /// Set a gradient stop given a position and a color. Used in conjunction with SetCustomGradient().
 /// </summary>
 /// <param name="Position">Specifies position of the color, ranging from 0.0 to 1.0.</param>
 /// <param name="ColorTheme">The theme color to be used.</param>
 /// <param name="ColorTint">The tint applied to the theme color, ranging from -1.0 to 1.0. Negative tints darken the theme color and positive tints lighten the theme color.</param>
 public void AppendGradientStop(double Position, SLThemeColorIndexValues ColorTheme, double ColorTint)
 {
     SLColor clr = new SLColor(this.listThemeColors, this.listIndexedColors);
     clr.SetThemeColor(ColorTheme, ColorTint);
     GradientStop gs = new GradientStop();
     gs.Position = Position;
     gs.Color = clr.ToSpreadsheetColor();
     listGradientStops.Add(gs);
 }
开发者ID:mousetwentytwo,项目名称:test,代码行数:15,代码来源:SLFill.cs


注:本文中的SLThemeColorIndexValues类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。