ErrorProvider.GetIconPadding(Control) 方法

定義

傳回錯誤圖示旁邊留下的額外空間數量。

public:
 int GetIconPadding(System::Windows::Forms::Control ^ control);
public int GetIconPadding (System.Windows.Forms.Control control);
member this.GetIconPadding : System.Windows.Forms.Control -> int
Public Function GetIconPadding (control As Control) As Integer

參數

control
Control

要為其取得填補的控制項。

傳回

Int32

圖示和控制項之間留下的像素數。

例外狀況

controlnull

備註

許多圖示通常會在其中央影像周圍有額外的空間,因此只有在需要額外的空間時,才需要填補值。 填補值可以是正數或負數。 負值會導致圖示與控制項的邊緣重迭。 預設圖示填補為 0。

適用於

另請參閱