Java Reference
In-Depth Information
You could draw such a flag using three rectangles. But if the middle rectangle is
white, as it is, for example, in the flag of Italy (green, white, red), it is easier and
looks better to draw a line on the top and bottom of the middle portion:
Step 2 Find the coordinates for the shapes.
You now need to find the exact positions for the geometric shapes.
117
118
ȗ For rectangles, you need the x- and y-position of the top-left corner, the
width, and the height.
ȗ For ellipses, you need the top-left corner, width, and height of the bounding
rectangle.
ȗ For lines, you need the x- and y-positions of the starting point and the end
point.
ȗ For text, you need the x- and y-positions of the basepoint.
Search WWH ::




Custom Search