DrawItemEventArgs 建構函式

定義

初始化 DrawItemEventArgs 類別的新執行個體。

多載

DrawItemEventArgs(Graphics, Font, Rectangle, Int32, DrawItemState)

為具有指定字型、狀態、要繪製的介面和界線的指定控制項,初始化 DrawItemEventArgs 類別的新執行個體。

DrawItemEventArgs(Graphics, Font, Rectangle, Int32, DrawItemState, Color, Color)

為具有指定字型、狀態、前景色彩、背景色彩、要繪製的介面和界線的指定控制項,初始化 DrawItemEventArgs 類別的新執行個體。

DrawItemEventArgs(Graphics, Font, Rectangle, Int32, DrawItemState)

為具有指定字型、狀態、要繪製的介面和界線的指定控制項,初始化 DrawItemEventArgs 類別的新執行個體。

public:
 DrawItemEventArgs(System::Drawing::Graphics ^ graphics, System::Drawing::Font ^ font, System::Drawing::Rectangle rect, int index, System::Windows::Forms::DrawItemState state);
public DrawItemEventArgs (System.Drawing.Graphics graphics, System.Drawing.Font font, System.Drawing.Rectangle rect, int index, System.Windows.Forms.DrawItemState state);
public DrawItemEventArgs (System.Drawing.Graphics graphics, System.Drawing.Font? font, System.Drawing.Rectangle rect, int index, System.Windows.Forms.DrawItemState state);
new System.Windows.Forms.DrawItemEventArgs : System.Drawing.Graphics * System.Drawing.Font * System.Drawing.Rectangle * int * System.Windows.Forms.DrawItemState -> System.Windows.Forms.DrawItemEventArgs
Public Sub New (graphics As Graphics, font As Font, rect As Rectangle, index As Integer, state As DrawItemState)

參數

graphics
Graphics

要繪製的 Graphics 表層。

font
Font

要使用的 Font,通常是父控制項的 Font 屬性。

rect
Rectangle

要其中繪製的 Rectangle 範圍。

index
Int32

繪製的項目的 Control.ControlCollection 索引值。

state
DrawItemState

控制項的 DrawItemState 資訊。

適用於

DrawItemEventArgs(Graphics, Font, Rectangle, Int32, DrawItemState, Color, Color)

為具有指定字型、狀態、前景色彩、背景色彩、要繪製的介面和界線的指定控制項,初始化 DrawItemEventArgs 類別的新執行個體。

public:
 DrawItemEventArgs(System::Drawing::Graphics ^ graphics, System::Drawing::Font ^ font, System::Drawing::Rectangle rect, int index, System::Windows::Forms::DrawItemState state, System::Drawing::Color foreColor, System::Drawing::Color backColor);
public DrawItemEventArgs (System.Drawing.Graphics graphics, System.Drawing.Font font, System.Drawing.Rectangle rect, int index, System.Windows.Forms.DrawItemState state, System.Drawing.Color foreColor, System.Drawing.Color backColor);
public DrawItemEventArgs (System.Drawing.Graphics graphics, System.Drawing.Font? font, System.Drawing.Rectangle rect, int index, System.Windows.Forms.DrawItemState state, System.Drawing.Color foreColor, System.Drawing.Color backColor);
new System.Windows.Forms.DrawItemEventArgs : System.Drawing.Graphics * System.Drawing.Font * System.Drawing.Rectangle * int * System.Windows.Forms.DrawItemState * System.Drawing.Color * System.Drawing.Color -> System.Windows.Forms.DrawItemEventArgs
Public Sub New (graphics As Graphics, font As Font, rect As Rectangle, index As Integer, state As DrawItemState, foreColor As Color, backColor As Color)

參數

graphics
Graphics

要繪製的 Graphics 表層。

font
Font

要使用的 Font,通常是父控制項的 Font 屬性。

rect
Rectangle

要其中繪製的 Rectangle 範圍。

index
Int32

繪製的項目的 Control.ControlCollection 索引值。

state
DrawItemState

控制項的 DrawItemState 資訊。

foreColor
Color

要用來繪製控制項的前景 Color

backColor
Color

要用來繪製控制項的背景 Color

適用於