Go to the first, previous, next, last section, table of contents.

### Rectangle interface

```
data Rectangle = Rect Int Int Int Int

{- The empty rectangle -}
emptyRect :: Rectangle

{- Create a rectangle given lower lefthand corner and size -}
rect      :: Coord -> Size  -> Rectangle
{- Create rectangle using extremes as boundary points -}
absRect   :: Coord -> Coord -> Rectangle

{- Return the smallest rectangle that encompasses both rects -}
unionRects      :: Rectangle -> Rectangle   -> Rectangle

{- Move the rectangle along -}
translateRect   :: Translation -> Rectangle -> Rectangle

{- Apply transform to rectangle -}
transformRect   :: Transform -> Rectangle   -> Rectangle

{- a weaker form of transexampleion -}
scaleRotateRect :: Transform -> Rectangle   -> Rectangle

{- do the two rects intersect? -}
intersectRects  :: Rectangle -> Rectangle   -> Maybe Rectangle

{- point on the inside? -}
pointInRect     :: Coord -> Rectangle -> Bool

{- augment rectangle so that it also includes point -}
addRectCoord    :: Coord -> Rectangle -> Rectangle
{-
resizes the rectangle, using the direction value
to indicate the origin for the scaling operation.
-}
resizeRect :: CompassDirection -> Size -> Rectangle -> Rectangle

{- return 'da size -}
rectSize :: Rectangle -> Size
{- Lower left and upper right hand corners -}
rectLL   :: Rectangle -> Coord
rectUR   :: Rectangle -> Coord

{- return the coord that is spot in the middle -}
middlePoint :: Rectangle -> Coord

{- return the point that corres. to one of the directions
(modulo rounding errors, o.c.) -}
dirCoord    :: CompassDirection -> Rectangle -> Coord

{- convert coordinate from the rectangles c. system to global -}
localToGlobal :: Rectangle  -> Coord -> Coord
{- other way around -}
globalToLocal :: Rectangle  -> Coord -> Coord

```

Go to the first, previous, next, last section, table of contents.