DataGridViewRowHeaderCell.Paint 方法
定义
重要
一些信息与预发行产品相关,相应产品在发行之前可能会进行重大修改。 对于此处提供的信息,Microsoft 不作任何明示或暗示的担保。
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的 ADataGridView。
- cellBounds
- Rectangle
一个 Rectangle 包含所绘制的 DataGridViewCell 边界的边界。
- rowIndex
- Int32
要绘制的单元格的行索引。
- cellState
- DataGridViewElementStates
指定单元格状态的值的 DataGridViewElementStates 按位组合。
- value
- Object
正在绘制的数据 DataGridViewCell 。
- formattedValue
- Object
正在绘制的 DataGridViewCell 格式化数据。
- errorText
- String
与单元格关联的错误消息。
- cellStyle
- DataGridViewCellStyle
包含有关单元格的格式和样式信息的 A DataGridViewCellStyle 。
- advancedBorderStyle
- DataGridViewAdvancedBorderStyle
一个 DataGridViewAdvancedBorderStyle 包含正在绘制的单元格的边框样式。
- paintParts
- DataGridViewPaintParts
值的按位组合 DataGridViewPaintParts ,指定需要绘制单元格的各个部分。