ComponentFactory.Krypton.Toolkit.PaletteSparkleBase.GetElementColor5 C# (CSharp) Method

GetElementColor5() public method

Gets the fifth element color.
public GetElementColor5 ( PaletteElement element, PaletteState state ) : Color
element PaletteElement Element for which color is required.
state PaletteState Palette value should be applicable to this state.
return Color
        public override Color GetElementColor5(PaletteElement element, PaletteState state)
        {
            switch (element)
            {
                case PaletteElement.TrackBarTick:
                    if (CommonHelper.IsOverrideState(state))
                        return Color.Empty;

                    return _trackBarColors[0];
                case PaletteElement.TrackBarTrack:
                    if (CommonHelper.IsOverrideState(state))
                        return Color.Empty;

                    return _trackBarColors[3];
                case PaletteElement.TrackBarPosition:
                    if (CommonHelper.IsOverrideStateExclude(state, PaletteState.FocusOverride))
                        return Color.Empty;

                    switch (state)
                    {
                        case PaletteState.Disabled:
                            return ControlPaint.LightLight(_sparkleColors[5]);
                        case PaletteState.Normal:
                            return _sparkleColors[22];
                        case PaletteState.Tracking:
                        case PaletteState.FocusOverride:
                            return _sparkleColors[7];
                        case PaletteState.Pressed:
                            return _sparkleColors[9];
                        default:
                            throw new ArgumentOutOfRangeException("state");
                    }
                default:
                    // Should never happen!
                    Debug.Assert(false);
                    break;
            }

            return Color.Red;
        }
PaletteSparkleBase