Private Sub Form1_Load(ByVal sender As Object, ByVal e As _
System.EventArgs) Handles MyBase.Load
Dim text_path As GraphicsPath
Dim text_region As Region
' Create the text path.
text_path = New System.Drawing.Drawing2D.GraphicsPath( _
Drawing.Drawing2D.FillMode.Alternate)
text_path.AddString("Flowers", _
New FontFamily("Times New Roman"), _
FontStyle.Bold, 200, _
New Point(10, 10), _
StringFormat.GenericDefault)
' Create a Region from the path.
text_region = New Region(text_path)
' Constrain the form to the region.
Me.Region = text_region
End Sub
|