FutureBasic Logo

<<    Index    >> FutureBasic 5

ratio   statement

ratio h,v

This statement affects the width and height of shapes subsequently drawn with the circle statement. By suitably setting the h and v parameters, you can draw ellipses with any aspect ratio.
Each of h and v can range in value from -128 to +127. The h parameter affects the width of the ellipse, and the v parameter affects its height. When you subsequently execute a circle statement with a radius parameter of radius, a circle or ellipse is drawn which has these dimensions:
Shape's width = 2 * radius * (1 + h /128)
Shape's height = 2 * radius * (1 + v /128)
We can notice a few consequences of these formulas:
After you execute a ratio statement, the indicated h and v values remain in effect for all subsequent circle statements (in all windows), until another ratio statement is executed.

See Also: