June 2003
Intermediate to advanced
800 pages
34h 20m
English
You want to create a non-rectangular form.
Create a new Region object that has the shape you want for the form, and assign it to the Form.Region property.
To create a non-rectangular form, you first need to define the shape you want. The easiest approach is to use the System.Drawing.Drawing2D.GraphicsPath object, which can accommodate any combination of ellipses, rectangles, and closed curves. You can add shapes to a GraphicsPath instance using methods such as AddEllipse, AddRectangle, and AddClosedCurve. Once you are finished defining the shape you want, you can create a Region object from this GraphicsPath—just submit the GraphicsPath in the Region class constructor. Finally, you can ...
Read now
Unlock full access