C# Class Smrf.AppLib.ColorGradientPanel

Panel control that displays a color gradient across the width of the control.
When the panel is drawn, it has a gradient from MinimumColor on the left side to MaximumColor on the right side.
Inheritance: System.Windows.Forms.Panel
Show file Open project: 2014-sed-team3/term-project

Protected Properties

Property Type Description
m_oMaximumColor Color
m_oMinimumColor Color

Public Methods

Method Description
ColorGradientPanel ( ) : System

Initializes a new instance of the ColorGradientPanel class.

Protected Methods

Method Description
FillRectangleWithLinearGradient ( Graphics oGraphics, Rectangle oRectangle, Color oLeftColor, Color oRightColor ) : void
OnPaint ( PaintEventArgs e ) : void

Private Methods

Method Description
AssertValid ( ) : void

Method Details

ColorGradientPanel() public method

Initializes a new instance of the ColorGradientPanel class.
public ColorGradientPanel ( ) : System
return System

FillRectangleWithLinearGradient() protected method

protected FillRectangleWithLinearGradient ( Graphics oGraphics, Rectangle oRectangle, Color oLeftColor, Color oRightColor ) : void
oGraphics System.Drawing.Graphics
oRectangle System.Drawing.Rectangle
oLeftColor Color
oRightColor Color
return void

OnPaint() protected method

protected OnPaint ( PaintEventArgs e ) : void
e PaintEventArgs
return void

Property Details

m_oMaximumColor protected property

protected Color m_oMaximumColor
return Color

m_oMinimumColor protected property

protected Color m_oMinimumColor
return Color