Silverlight provides a powerful set of transforms to apply to the visual object. The following is a full set of 2D transforms:
TranslateTransform
: This shifts an object in a 2D plane.ScaleTransform
: This scales (or resizes) the object by theScaleX
factor along the X-axis and theScaleY
factor along the Y-axis.SkewTransform
: Skewing along the X-axis turns every vector orthogonal to the X-axis by the same angle defined byAngleX
, and expands its length so that its Y coordinate stays the same. TheAngleY
parameter of the transform is in charge of skewing along the Y-axis.RotateTransform
: This rotates an object by theAngle
parameter.MatrixTransform
: This is a generic transform that can represent any linear transformation and translation within a 2D plane.
We previously used RotateTransform
to rotate the rectangle.
There is also the PlaneProjection
transform imitating the moving of an object in a 3D space. We will describe this transform in detail later in the book.