BCGControlBar Library for .NET
DrawColumnHeader Method




The Graphics object.
Column header bounds.
Column name.
Column image.
Header visual style.
Specifies whether to display "marked" state. It uses HeaderVisualStyle.MarkBackColor.
Specifies whether to display selected state. It uses HeaderVisualStyle.SelectionBackColor.
Specifies whether the column header is highlighted.
Specifies if the header is for the left most column in the visible grid area.
Specifies IMAGES_IDS of sort marker.
Specifies whether this function needs to calculate the size of header content only.
Column whose header is about to be drawn.
Specifies whether the header is displayed in the Group By box.
Called by painting code to draw column header.
Syntax
'Declaration
 
Public Function DrawColumnHeader( _
   ByVal grph As Graphics, _
   ByVal bounds As Rectangle, _
   ByVal text As String, _
   ByVal image As Image, _
   ByVal style As GridCellVisualStyle, _
   ByVal markSelection As Boolean, _
   ByVal showSelectedState As Boolean, _
   ByVal highlighted As Boolean, _
   ByVal firstVisibleColumn As Boolean, _
   ByVal sortMarker As IMAGES_IDS, _
   ByVal calcOnly As Boolean, _
   ByVal column As GridColumn, _
   ByVal isGroupArea As Boolean _
) As Size
'Usage
 
Dim instance As GridControl
Dim grph As Graphics
Dim bounds As Rectangle
Dim text As String
Dim image As Image
Dim style As GridCellVisualStyle
Dim markSelection As Boolean
Dim showSelectedState As Boolean
Dim highlighted As Boolean
Dim firstVisibleColumn As Boolean
Dim sortMarker As IMAGES_IDS
Dim calcOnly As Boolean
Dim column As GridColumn
Dim isGroupArea As Boolean
Dim value As Size
 
value = instance.DrawColumnHeader(grph, bounds, text, image, style, markSelection, showSelectedState, highlighted, firstVisibleColumn, sortMarker, calcOnly, column, isGroupArea)
public Size DrawColumnHeader( 
   Graphics grph,
   Rectangle bounds,
   string text,
   Image image,
   GridCellVisualStyle style,
   bool markSelection,
   bool showSelectedState,
   bool highlighted,
   bool firstVisibleColumn,
   IMAGES_IDS sortMarker,
   bool calcOnly,
   GridColumn column,
   bool isGroupArea
)
public: Size DrawColumnHeader( 
   Graphics* grph,
   Rectangle bounds,
   string* text,
   Image* image,
   GridCellVisualStyle* style,
   bool markSelection,
   bool showSelectedState,
   bool highlighted,
   bool firstVisibleColumn,
   IMAGES_IDS sortMarker,
   bool calcOnly,
   GridColumn* column,
   bool isGroupArea
) 
public:
Size DrawColumnHeader( 
   Graphics^ grph,
   Rectangle bounds,
   String^ text,
   Image^ image,
   GridCellVisualStyle^ style,
   bool markSelection,
   bool showSelectedState,
   bool highlighted,
   bool firstVisibleColumn,
   IMAGES_IDS sortMarker,
   bool calcOnly,
   GridColumn^ column,
   bool isGroupArea
) 

Parameters

grph
The Graphics object.
bounds
Column header bounds.
text
Column name.
image
Column image.
style
Header visual style.
markSelection
Specifies whether to display "marked" state. It uses HeaderVisualStyle.MarkBackColor.
showSelectedState
Specifies whether to display selected state. It uses HeaderVisualStyle.SelectionBackColor.
highlighted
Specifies whether the column header is highlighted.
firstVisibleColumn
Specifies if the header is for the left most column in the visible grid area.
sortMarker
Specifies IMAGES_IDS of sort marker.
calcOnly
Specifies whether this function needs to calculate the size of header content only.
column
Column whose header is about to be drawn.
isGroupArea
Specifies whether the header is displayed in the Group By box.
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

GridControl Class
GridControl Members

Send Feedback