GrapeCity MultiRow Windows Forms Documentation
PreferredSize Property (Cell)


Gets the size of a rectangular area into which the cell can fit.
Syntax
<BrowsableAttribute(False)>
<SuppressMessageAttribute(Category="Microsoft.Naming", 
   CheckId="CA1721:PropertyNamesShouldNotMatchGetMethods", 
   Scope="", 
   Target="", 
   MessageId="", 
   Justification="")>
Public ReadOnly Property PreferredSize As Size
Dim instance As Cell
Dim value As Size
 
value = instance.PreferredSize
[Browsable(false)]
[SuppressMessage(Category="Microsoft.Naming", 
   CheckId="CA1721:PropertyNamesShouldNotMatchGetMethods", 
   Scope="", 
   Target="", 
   MessageId="", 
   Justification="")]
public Size PreferredSize {get;}

Property Value

A System.Drawing.Size value that represents the size of a rectangular area into which the cell can fit.
Remarks

Generally, each cell's preferred size should be the minimum size that contains the cell's DisplayText, CellStyle.Image, CellStyle.Padding, CellStyle.Border, and ErrorIcon. But for some special type cells which have DropDownButton, SideButton, FlatAppearance border, and so on, these visual elements should also be contained in the preferred size.

If GcMultiRow is zoomed, the preferred size is the size after zooming.

You can customize the cell's preferred size by overriding the cell's GetPreferredSize method.

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

Cell Class
Cell Members

 

 


Copyright © GrapeCity, inc. All rights reserved.