語言

DrawToolTipEventArgs 建構函式

定義

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

public:
 DrawToolTipEventArgs(System::Drawing::Graphics ^ graphics, System::Windows::Forms::IWin32Window ^ associatedWindow, System::Windows::Forms::Control ^ associatedControl, System::Drawing::Rectangle bounds, System::String ^ toolTipText, System::Drawing::Color backColor, System::Drawing::Color foreColor, System::Drawing::Font ^ font);
public DrawToolTipEventArgs(System.Drawing.Graphics graphics, System.Windows.Forms.IWin32Window associatedWindow, System.Windows.Forms.Control associatedControl, System.Drawing.Rectangle bounds, string toolTipText, System.Drawing.Color backColor, System.Drawing.Color foreColor, System.Drawing.Font font);
public DrawToolTipEventArgs(System.Drawing.Graphics graphics, System.Windows.Forms.IWin32Window? associatedWindow, System.Windows.Forms.Control? associatedControl, System.Drawing.Rectangle bounds, string? toolTipText, System.Drawing.Color backColor, System.Drawing.Color foreColor, System.Drawing.Font? font);
new System.Windows.Forms.DrawToolTipEventArgs : System.Drawing.Graphics * System.Windows.Forms.IWin32Window * System.Windows.Forms.Control * System.Drawing.Rectangle * string * System.Drawing.Color * System.Drawing.Color * System.Drawing.Font -> System.Windows.Forms.DrawToolTipEventArgs
Public Sub New (graphics As Graphics, associatedWindow As IWin32Window, associatedControl As Control, bounds As Rectangle, toolTipText As String, backColor As Color, foreColor As Color, font As Font)

參數

graphics
Graphics

Graphics繪製工具提示時所使用的上下文。

associatedWindow
IWin32Window

那是 IWin32Window 工具提示必然會被綁定的。

associatedControl
Control

也就是 Control 這個工具提示被建立的目的。

bounds
Rectangle

Rectangle A 標示工具提示要顯示的區域。

toolTipText
String

A String 包含工具提示的文字。

backColor
Color

Color關於工具提示的背景。

foreColor
Color

工具 Color 提示文字。

font
Font

它們 Font 用來繪製工具提示文字。

備註

DrawToolTipEventArgs建構子使用 graphics、 associatedControl、 associatedWindow、 bounds和 fonttoolTipText 參數來初始化它們對應且名稱相似的屬性。 backColor和foreColor參數分別被 DrawBackground 和 DrawText 方法使用。

適用於

另請參閱