DataGridViewRowHeaderCell.Paint 方法

定義

繪製當前的 DataGridViewRowHeaderCell

protected:
 override void Paint(System::Drawing::Graphics ^ graphics, System::Drawing::Rectangle clipBounds, System::Drawing::Rectangle cellBounds, int rowIndex, System::Windows::Forms::DataGridViewElementStates cellState, System::Object ^ value, System::Object ^ formattedValue, System::String ^ errorText, System::Windows::Forms::DataGridViewCellStyle ^ cellStyle, System::Windows::Forms::DataGridViewAdvancedBorderStyle ^ advancedBorderStyle, System::Windows::Forms::DataGridViewPaintParts paintParts);
protected override void Paint(System.Drawing.Graphics graphics, System.Drawing.Rectangle clipBounds, System.Drawing.Rectangle cellBounds, int rowIndex, System.Windows.Forms.DataGridViewElementStates cellState, object value, object formattedValue, string errorText, System.Windows.Forms.DataGridViewCellStyle cellStyle, System.Windows.Forms.DataGridViewAdvancedBorderStyle advancedBorderStyle, System.Windows.Forms.DataGridViewPaintParts paintParts);
protected override void Paint(System.Drawing.Graphics graphics, System.Drawing.Rectangle clipBounds, System.Drawing.Rectangle cellBounds, int rowIndex, System.Windows.Forms.DataGridViewElementStates cellState, object? value, object? formattedValue, string? errorText, System.Windows.Forms.DataGridViewCellStyle cellStyle, System.Windows.Forms.DataGridViewAdvancedBorderStyle advancedBorderStyle, System.Windows.Forms.DataGridViewPaintParts paintParts);
override this.Paint : System.Drawing.Graphics * System.Drawing.Rectangle * System.Drawing.Rectangle * int * System.Windows.Forms.DataGridViewElementStates * obj * obj * string * System.Windows.Forms.DataGridViewCellStyle * System.Windows.Forms.DataGridViewAdvancedBorderStyle * System.Windows.Forms.DataGridViewPaintParts -> unit
Protected Overrides Sub Paint (graphics As Graphics, clipBounds As Rectangle, cellBounds As Rectangle, rowIndex As Integer, cellState As DataGridViewElementStates, value As Object, formattedValue As Object, errorText As String, cellStyle As DataGridViewCellStyle, advancedBorderStyle As DataGridViewAdvancedBorderStyle, paintParts As DataGridViewPaintParts)

參數

graphics
Graphics

他們Graphics過去用來上色。DataGridViewCell

clipBounds
Rectangle

Rectangle A代表需要重新粉刷的區域DataGridView

cellBounds
Rectangle

Rectangle A 包含了所繪製的 的界限DataGridViewCell

rowIndex
Int32

就是被繪製的格子的列索引。

cellState
DataGridViewElementStates

一個位元組合 DataGridViewElementStates 的值,指定儲存格的狀態。

value
Object

DataGridViewCell正在繪製的數據。

formattedValue
Object

正在繪製的格式化資料 DataGridViewCell

errorText
String

一個與該小區相關的錯誤訊息。

cellStyle
DataGridViewCellStyle

DataGridViewCellStyle包含儲存格的格式與樣式資訊。

advancedBorderStyle
DataGridViewAdvancedBorderStyle

DataGridViewAdvancedBorderStyle A 包含被繪製格子的邊框樣式。

paintParts
DataGridViewPaintParts

以位元組合 DataGridViewPaintParts 的數值,指定需要繪製儲存格的哪些部分。

適用於