DataGridViewRow.PaintCells Méthode
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Peint les cellules de la ligne active.
protected public:
virtual void PaintCells(System::Drawing::Graphics ^ graphics, System::Drawing::Rectangle clipBounds, System::Drawing::Rectangle rowBounds, int rowIndex, System::Windows::Forms::DataGridViewElementStates rowState, bool isFirstDisplayedRow, bool isLastVisibleRow, System::Windows::Forms::DataGridViewPaintParts paintParts);
protected internal virtual void PaintCells(System.Drawing.Graphics graphics, System.Drawing.Rectangle clipBounds, System.Drawing.Rectangle rowBounds, int rowIndex, System.Windows.Forms.DataGridViewElementStates rowState, bool isFirstDisplayedRow, bool isLastVisibleRow, System.Windows.Forms.DataGridViewPaintParts paintParts);
abstract member PaintCells : System.Drawing.Graphics * System.Drawing.Rectangle * System.Drawing.Rectangle * int * System.Windows.Forms.DataGridViewElementStates * bool * bool * System.Windows.Forms.DataGridViewPaintParts -> unit
override this.PaintCells : System.Drawing.Graphics * System.Drawing.Rectangle * System.Drawing.Rectangle * int * System.Windows.Forms.DataGridViewElementStates * bool * bool * System.Windows.Forms.DataGridViewPaintParts -> unit
Protected Friend Overridable Sub PaintCells (graphics As Graphics, clipBounds As Rectangle, rowBounds As Rectangle, rowIndex As Integer, rowState As DataGridViewElementStates, isFirstDisplayedRow As Boolean, isLastVisibleRow As Boolean, paintParts As DataGridViewPaintParts)
Paramètres
- graphics
- Graphics
Utilisé Graphics pour peindre le DataGridViewRow.
- clipBounds
- Rectangle
Qui Rectangle représente la zone de celle DataGridView qui doit être peinte.
- rowBounds
- Rectangle
Qui Rectangle contient les limites de la DataGridViewRow peinture.
- rowIndex
- Int32
Index de ligne de la cellule en cours de peinture.
- rowState
- DataGridViewElementStates
Combinaison de valeurs au niveau du DataGridViewElementStates bit qui spécifie l’état de la ligne.
- isFirstDisplayedRow
- Boolean
true pour indiquer si la ligne actuelle est la première ligne affichée dans le DataGridView; sinon, false.
- isLastVisibleRow
- Boolean
true pour indiquer si la ligne actuelle est la dernière ligne de la DataGridViewVisible propriété définie truesur ; sinon, false.
- paintParts
- DataGridViewPaintParts
Combinaison de valeurs au niveau du DataGridViewPaintParts bit indiquant les parties des cellules à peindre.
Exceptions
La ligne n’a pas été ajoutée à un DataGridView contrôle.
paintParts dans une combinaison de valeurs non valide au niveau du DataGridViewPaintParts bit.
Remarques
Le DataGridView contrôle appelle cette méthode pour peindre les cellules de la ligne, sauf lorsqu’un gestionnaire pour l’événement DataGridView.RowPrePaint définit la HandledEventArgs.Handled propriété truesur . Pour plus d’informations, consultez Paint.