C# Class WinHtmlEditor.ToolStripColorPicker

Inheritance: System.Windows.Forms.ToolStripSplitButton
显示文件 Open project: tewuapple/WinHtmlEditor

Private Properties

Property Type Description
GetOpenPoint Point
HandleSelectedColorChanged void
InitControl void
PaintUnderLine void
PaintUnderLineImage System.Drawing.Size
PaintUnderLineText void
Refresh void
UpdateDisplayStyle void

Public Methods

Method Description
OnButtonPortionClicked ( EventArgs e ) : void

Fires the ButtonPortionClicked event.

OnSelectedColorChanged ( EventArgs e ) : void

Fires the SelectedColorChanged event.

ToolStripColorPicker ( ) : System

Initializes a new instance of the ToolStripColorPicker that holds OfficeColorPicker control inside a ToolStripItem to add to ToolStrip containers.

ToolStripColorPicker ( Color startingColor ) : System

Initializes a new instance of the ToolStripColorPicker that holds OfficeColorPicker control inside a ToolStripItem to add to ToolStrip containers.

Protected Methods

Method Description
Dispose ( bool disposing ) : void

Clean up any resources being used.

OnButtonClick ( EventArgs e ) : void
OnDropDownOpened ( EventArgs e ) : void
OnPaint ( PaintEventArgs e ) : void

Overrides, Paint the image in the specified scale and the color line if defined.

Private Methods

Method Description
GetOpenPoint ( ) : Point

Gets the button position by the parent ToolStrip

HandleSelectedColorChanged ( object sender, EventArgs e ) : void

Repaint the button with the new color

InitControl ( ) : void

Set starting properties for the control and register the needed events.

PaintUnderLine ( Graphics g ) : void

Paints the underline rectangle.

PaintUnderLineImage ( Graphics g ) : Size

Paints the under line image

PaintUnderLineText ( Graphics g, Size imageSize ) : void

Paints the underline text

Refresh ( ) : void

Repaint the parent tool strip and the button tool tip

UpdateDisplayStyle ( ) : void

Set the painting properties by the _buttonDisplayStyle property.

Method Details

Dispose() protected method

Clean up any resources being used.
protected Dispose ( bool disposing ) : void
disposing bool true if managed resources should be disposed; otherwise, false.
return void

OnButtonClick() protected method

protected OnButtonClick ( EventArgs e ) : void
e System.EventArgs
return void

OnButtonPortionClicked() public method

Fires the ButtonPortionClicked event.
public OnButtonPortionClicked ( EventArgs e ) : void
e System.EventArgs
return void

OnDropDownOpened() protected method

protected OnDropDownOpened ( EventArgs e ) : void
e System.EventArgs
return void

OnPaint() protected method

Overrides, Paint the image in the specified scale and the color line if defined.
protected OnPaint ( PaintEventArgs e ) : void
e PaintEventArgs
return void

OnSelectedColorChanged() public method

Fires the SelectedColorChanged event.
public OnSelectedColorChanged ( EventArgs e ) : void
e System.EventArgs
return void

ToolStripColorPicker() public method

Initializes a new instance of the ToolStripColorPicker that holds OfficeColorPicker control inside a ToolStripItem to add to ToolStrip containers.
public ToolStripColorPicker ( ) : System
return System

ToolStripColorPicker() public method

Initializes a new instance of the ToolStripColorPicker that holds OfficeColorPicker control inside a ToolStripItem to add to ToolStrip containers.
public ToolStripColorPicker ( Color startingColor ) : System
startingColor Color The color to assign to the color picker control
return System