C# Class ZForge.Controls.XPTable.Renderers.ButtonCellRenderer

A CellRenderer that draws Cell contents as Buttons
Inheritance: CellRenderer
Exibir arquivo Open project: zhuangyy/Motion

Public Methods

Method Description
ButtonCellRenderer ( ) : System

Initializes a new instance of the ButtonCellRenderer class with default settings

OnGotFocus ( CellFocusEventArgs e ) : void

Raises the GotFocus event

OnKeyDown ( CellKeyEventArgs e ) : void

Raises the KeyDown event

OnKeyUp ( CellKeyEventArgs e ) : void

Raises the KeyUp event

OnLostFocus ( CellFocusEventArgs e ) : void

Raises the LostFocus event

OnMouseDown ( CellMouseEventArgs e ) : void

Raises the MouseDown event

OnMouseEnter ( CellMouseEventArgs e ) : void

Raises the MouseEnter event

OnMouseLeave ( CellMouseEventArgs e ) : void

Raises the MouseLeave event

OnMouseMove ( CellMouseEventArgs e ) : void

Raises the MouseMove event

OnMouseUp ( CellMouseEventArgs e ) : void

Raises the MouseUp event

OnPaintCell ( PaintCellEventArgs e ) : void

Raises the PaintCell event

Protected Methods

Method Description
CalcButtonBounds ( ) : Rectangle

Returns a Rectangle that specifies the size and location of the button

CalcImageRect ( Image image, ContentAlignment imageAlignment ) : Rectangle

Returns a Rectangle that specifies the size and location of the buttons Image

DrawImage ( Graphics g, Image image, Rectangle imageRect, bool enabled ) : void

Draws the Image displayed on the button

GetButtonRendererData ( Cell cell ) : ButtonRendererData

Gets the ButtonCellRenderer specific data used by the Renderer from the specified Cell

OnPaint ( PaintCellEventArgs e ) : void

Raises the Paint event

OnPaintBackground ( PaintCellEventArgs e ) : void

Raises the PaintBackground event

Method Details

ButtonCellRenderer() public method

Initializes a new instance of the ButtonCellRenderer class with default settings
public ButtonCellRenderer ( ) : System
return System

CalcButtonBounds() protected method

Returns a Rectangle that specifies the size and location of the button
protected CalcButtonBounds ( ) : Rectangle
return System.Drawing.Rectangle

CalcImageRect() protected method

Returns a Rectangle that specifies the size and location of the buttons Image
protected CalcImageRect ( Image image, ContentAlignment imageAlignment ) : Rectangle
image Image The buttons image
imageAlignment ContentAlignment The alignment of the image
return System.Drawing.Rectangle

DrawImage() protected method

Draws the Image displayed on the button
protected DrawImage ( Graphics g, Image image, Rectangle imageRect, bool enabled ) : void
g System.Drawing.Graphics The Graphics to draw on
image Image The Image to draw
imageRect System.Drawing.Rectangle A Rectangle that specifies the location /// of the Image
enabled bool Specifies whether the Image should be drawn /// in an enabled state
return void

GetButtonRendererData() protected method

Gets the ButtonCellRenderer specific data used by the Renderer from the specified Cell
protected GetButtonRendererData ( Cell cell ) : ButtonRendererData
cell ZForge.Controls.XPTable.Models.Cell The Cell to get the ButtonCellRenderer data for
return ButtonRendererData

OnGotFocus() public method

Raises the GotFocus event
public OnGotFocus ( CellFocusEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellFocusEventArgs A CellFocusEventArgs that contains the event data
return void

OnKeyDown() public method

Raises the KeyDown event
public OnKeyDown ( CellKeyEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellKeyEventArgs A CellKeyEventArgs that contains the event data
return void

OnKeyUp() public method

Raises the KeyUp event
public OnKeyUp ( CellKeyEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellKeyEventArgs A CellKeyEventArgs that contains the event data
return void

OnLostFocus() public method

Raises the LostFocus event
public OnLostFocus ( CellFocusEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellFocusEventArgs A CellFocusEventArgs that contains the event data
return void

OnMouseDown() public method

Raises the MouseDown event
public OnMouseDown ( CellMouseEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellMouseEventArgs A CellMouseEventArgs that contains the event data
return void

OnMouseEnter() public method

Raises the MouseEnter event
public OnMouseEnter ( CellMouseEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellMouseEventArgs A CellMouseEventArgs that contains the event data
return void

OnMouseLeave() public method

Raises the MouseLeave event
public OnMouseLeave ( CellMouseEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellMouseEventArgs A CellMouseEventArgs that contains the event data
return void

OnMouseMove() public method

Raises the MouseMove event
public OnMouseMove ( CellMouseEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellMouseEventArgs A CellMouseEventArgs that contains the event data
return void

OnMouseUp() public method

Raises the MouseUp event
public OnMouseUp ( CellMouseEventArgs e ) : void
e ZForge.Controls.XPTable.Events.CellMouseEventArgs A CellMouseEventArgs that contains the event data
return void

OnPaint() protected method

Raises the Paint event
protected OnPaint ( PaintCellEventArgs e ) : void
e ZForge.Controls.XPTable.Events.PaintCellEventArgs A PaintCellEventArgs that contains the event data
return void

OnPaintBackground() protected method

Raises the PaintBackground event
protected OnPaintBackground ( PaintCellEventArgs e ) : void
e ZForge.Controls.XPTable.Events.PaintCellEventArgs A PaintCellEventArgs that contains the event data
return void

OnPaintCell() public method

Raises the PaintCell event
public OnPaintCell ( PaintCellEventArgs e ) : void
e ZForge.Controls.XPTable.Events.PaintCellEventArgs A PaintCellEventArgs that contains the event data
return void