Spread Windows Forms 10.0 Product Documentation
PaintBackground(Graphics,Boolean,Boolean,Boolean,Boolean,Rectangle,Int32,Int32,VisualStyles,Boolean,Color) Method


Graphics device interface for painting the cell
Whether to use XP themes
Whether painting to the screen
Whether in a pressed state
Whether the cell has focus
Boundary rectangle
Integer number of resolution (DPI) along the x-axis
Integer number of resolution (DPI) along the y-axis
Whether to turn on visual styles
Whether drawing right to left
Cell background color
Paints the background of the enhanced header cell.
Syntax
'Declaration
 
Protected Overridable Sub PaintBackground( _
   ByVal g As Graphics, _
   ByRef useXpStyles As Boolean, _
   ByVal toscreen As Boolean, _
   ByVal pressed As Boolean, _
   ByVal focus As Boolean, _
   ByVal r As Rectangle, _
   ByVal dpx As Integer, _
   ByVal dpy As Integer, _
   ByVal style As VisualStyles, _
   ByVal rightToLeft As Boolean, _
   ByVal backColor As Color _
) 
'Usage
 
Dim instance As ColumnHeaderRenderer
Dim g As Graphics
Dim useXpStyles As Boolean
Dim toscreen As Boolean
Dim pressed As Boolean
Dim focus As Boolean
Dim r As Rectangle
Dim dpx As Integer
Dim dpy As Integer
Dim style As VisualStyles
Dim rightToLeft As Boolean
Dim backColor As Color
 
instance.PaintBackground(g, useXpStyles, toscreen, pressed, focus, r, dpx, dpy, style, rightToLeft, backColor)
protected virtual void PaintBackground( 
   Graphics g,
   ref bool useXpStyles,
   bool toscreen,
   bool pressed,
   bool focus,
   Rectangle r,
   int dpx,
   int dpy,
   VisualStyles style,
   bool rightToLeft,
   Color backColor
)

Parameters

g
Graphics device interface for painting the cell
useXpStyles
Whether to use XP themes
toscreen
Whether painting to the screen
pressed
Whether in a pressed state
focus
Whether the cell has focus
r
Boundary rectangle
dpx
Integer number of resolution (DPI) along the x-axis
dpy
Integer number of resolution (DPI) along the y-axis
style
Whether to turn on visual styles
rightToLeft
Whether drawing right to left
backColor
Cell background color
Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows Server 2012 R2, Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8, Windows 8.1, Windows 10

See Also

Reference

ColumnHeaderRenderer Class
ColumnHeaderRenderer Members

 

 


Copyright © GrapeCity, inc. All rights reserved.