3.5 The Transformations Used by CLIM

These generic functions are implemented for all classes of transformations. Furthermore, all subclasses of **region** and **ink** implement methods for **transform-region** and **untransform-region**. That is, methods for the following generic functions will typically specialize both the *transformation* and *region* arguments.

**transform-region ** [Generic Function]

- Arguments:
*transformation region*

- Summary:
- Applies
*transformation*to the region*region*, and returns the transformed region.

- Arguments:
*transformation region*

- Summary:
- This is exactly equivalent to
**:**

(transform-region (invert-transformationtransformation)region)

- CLIM provides a default method for
**untransform-region**on the**transformation**protocol class that does exactly this.

- Arguments:
*transformation x y*

- Summary:
- Applies the transformation
*transformation*to the point whose coordinates are the real numbers*x*and*y*, and returns two values, the transformed*x*coordinate and the transformed*y*coordinate. **transform-position**is the spread version of**transform-region**in the case where the region is a point.

- Arguments:
*transformation x y*

- Summary:
- This is exactly equivalent to:

(transform-position (invert-transformationtransformation)x)y

- CLIM provides a default method for
**untransform-position**on the**transformation**protocol class that does exactly this.

- Arguments:
*transformation dx dy*

- Summary:
- Applies the transformation
*transformation*to the distance represented by the real numbers*dx*and*dy*, and returns two values, the transformed*dx*and the transformed*dy*. - A distance represents the difference between two points. It does
*not*transform like a point.

- Arguments:
*transformation dx dy*

- Summary:
- This is exactly equivalent to:

(transform-distance (invert-transformationtransformation)dx)dy

- CLIM provides a default method for
**untransform-distance**on the**transformation**protocol class that does exactly this.

- Arguments:
*transformation x1 y1 x2 y2*

- Summary:
- Applies the transformation
*transformation t*o the rectangle specified by the four coordinate arguments, which are real numbers. The arguments*x1*,*y1*,*x2*, and*y*2 are canonicalized in the same way as for**make-bounding-rectangle**. Returns four values that specify the minimum and maximum points of the transformed rectangle in the order*min-x*,*min-y*,*max-x*, and*max-y*. - It is an error if
*transformation*does not satisfy**rectilinear-transformation-p**. **transform-rectangle***is the spread version of**transform-region**in the case where the transformation is rectilinear and the region is a rectangle.

- Arguments:
*transformation x1 y1 x2 y2*

- Summary:
- This is exactly equivalent to:

(transform-rectangle* (invert-transformationtransformation)x1y1x2y2)

- CLIM provides a default method for
**untransform-rectangle***on the**transformation**protocol class that does exactly this.

CLIM 2.0 User's Guide - OCT 1998

Generated with Harlequin WebMaker