Sdílet prostřednictvím


DataGridViewCheckBoxCell.GetPreferredSize Metoda

Definice

Vypočítá upřednostňovanou velikost buňky v pixelech.

protected:
 override System::Drawing::Size GetPreferredSize(System::Drawing::Graphics ^ graphics, System::Windows::Forms::DataGridViewCellStyle ^ cellStyle, int rowIndex, System::Drawing::Size constraintSize);
protected override System.Drawing.Size GetPreferredSize (System.Drawing.Graphics graphics, System.Windows.Forms.DataGridViewCellStyle cellStyle, int rowIndex, System.Drawing.Size constraintSize);
override this.GetPreferredSize : System.Drawing.Graphics * System.Windows.Forms.DataGridViewCellStyle * int * System.Drawing.Size -> System.Drawing.Size
Protected Overrides Function GetPreferredSize (graphics As Graphics, cellStyle As DataGridViewCellStyle, rowIndex As Integer, constraintSize As Size) As Size

Parametry

graphics
Graphics

Použitá Graphics k nakreslení buňky.

cellStyle
DataGridViewCellStyle

A DataGridViewCellStyle , který představuje styl buňky.

rowIndex
Int32

Index řádku založeného na nule buňky.

constraintSize
Size

Maximální povolená velikost buňky.

Návraty

Size

A Size , která představuje upřednostňovanou velikost buňky v pixelech.

Platí pro

Viz také