1 2 3 4 5 6 7 8 9 10
| Dim rect As Rectangle = New Rectangle(0, 0, Me.ClientRectangle.Width, Me.ClientRectangle.Height)
e.Graphics.FillRectangle(New SolidBrush(Color.Navy), 0, 0, Me.ClientRectangle.Width, 34)
e.Graphics.DrawRectangle(New Pen(Brushes.Black, 2), rect)
Dim fnt As New Font("Times New Roman", 14, FontStyle.Bold)
Dim sf As New StringFormat With {.Alignment = StringAlignment.Center, .LineAlignment = StringAlignment.Center}
Dim textRect As Rectangle = New Rectangle(0, 0, Me.ClientRectangle.Width, 34)
e.Graphics.DrawString("- Download File", fnt, Brushes.White, textRect, sf)
e.Graphics.DrawImage(flagbmp, 215, 0)
fnt.Dispose()
sf.Dispose() |
Partager