Drawing Filled Areas
The next step up from drawing lines is filling enclosed areas. Windows’ seven functions for drawing filled areas with borders are listed in the table below.
Function | Figure |
---|---|
Rectangle | Rectangle with square corners |
Ellipse | Ellipse |
RoundRect | Rectangle with rounded corners |
Chord | Arc on the circumference of an ellipse with endpoints connected by a chord |
Pie | Pie wedge defined by the circumference of an ellipse |
Polygon | Multisided figure |
PolyPolygon | Multiple multisided figures |
Windows draws the outline of the figure with the current pen selected in the device context. The current background mode, background color, and drawing mode are all used for this outline, just as if Windows were drawing a line. Everything we learned about lines also ...
Get Programming Windows®, Fifth Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.