Lingo Dictionary > G-K > inflate |  |

inflate

Syntax

    rectangle.Inflate(widthChange , heightChange)
    inflate (rectangle, widthChange, heightChange)

Description

Command; changes the dimensions of the rectangle specified by `rectangle` relative to the center of the rectangle, either horizontally (`widthChange``)` or vertically`` `(``heightChange``)`.

The total change in each direction is twice the number you specify. For example, replacing `widthChange` with 15 increases the rectangle's width by 30 pixels. A value less than 0 for the horizontal or vertical dimension reduces the rectangle's size.

Example

This statement increases the rectangle's width by 4 pixels and the height by 2 pixels:

    rect(10, 10, 20, 20).inflate(2, 1)
    -- rect (8, 9, 22, 21)

Example

This statement decreases the rectangle's height and width by 20 pixels:

    inflate (rect(0, 0, 100, 100), -10, -10)
    -- rect (10, 10, 90, 90)