AnfiniL.SqlExpressProfiler.VisualStyles.VisualStyleUtils.GetColor C# (CSharp) Method

GetColor() public static method

public static GetColor ( System.Windows.Forms.VisualStyles.VisualStyleElement element, ColorProperty colorProperty, Color defaultColor ) : Color
element System.Windows.Forms.VisualStyles.VisualStyleElement
colorProperty ColorProperty
defaultColor Color
return Color
        public static Color GetColor(VisualStyleElement element, ColorProperty colorProperty, Color defaultColor)
        {
            if(VisualStyleRenderer.IsSupported && VisualStyleRenderer.IsElementDefined(element))
            {
                return new VisualStyleRenderer(element).GetColor(colorProperty);
            }
            else
            {
                return defaultColor;
            }
        }
VisualStyleUtils