or
private
void
drawTitle(GridViewCellPaintEventArgs e)
{
var groupText = grid.Rows[e.Cell.RowIndex].Cells[0].Tag
as
string
;
var font =
new
Font(SystemFonts.MessageBoxFont, FontStyle.Regular | FontStyle.Underline);
//region to draw is the entire row
e.Graphics.Clip =
new
System.Drawing.Region(e.Cell.RowElement.Bounds);
e.Graphics.Clear(Color.PeachPuff);
e.Graphics.DrawString(groupText, font, Brushes.Blue, Point.Empty);
e.Cell.RowElement.DrawBorder =
false
;
e.Cell.RowElement.BorderWidth = 0;
e.Cell.DisableHTMLRendering =
true
;
e.Cell.CanFocus =
false
;
}