次の方法で共有


IXRSkewTransform (Windows Embedded CE 6.0)

1/6/2010

This class represents a two-dimensional skew applied to an object.

Syntax

class IXRSkewTransform : public IXRTransform

Methods

Method Description

IXRSkewTransform::GetAngleX

Retrieves the x-axis skew angle, which is measured in degrees counterclockwise from the y-axis.

IXRSkewTransform::GetAngleY

Retrieves the y-axis skew angle, which is measured in degrees counterclockwise from the x-axis.

IXRSkewTransform::GetCenterX

Retrieves the x-coordinate of the transform center.

IXRSkewTransform::GetCenterY

Retrieves the y-coordinate of the transform center.

IXRSkewTransform::SetAngleX

Sets the x-axis skew angle, which is measured in degrees counterclockwise from the y-axis.

IXRSkewTransform::SetAngleY

Sets the y-axis skew angle, which is measured in degrees counterclockwise from the x-axis.

IXRSkewTransform::SetCenterX

Sets the x-coordinate of the transform center.

IXRSkewTransform::SetCenterY

Sets the y-coordinate of the transform center.

Remarks

A skew transformation is useful for creating the illusion of three-dimensional depth in a two-dimensional object.

Skewing (or shearing) an object is a transformation that distorts an object by a specified angle from an axis. You can also alter the location of the center of that object, in relation to its origin point.

You can offset the local origin point (0,0) for a UI element can be offset on an IXRCanvas container object by setting the attached properties Canvas.Left and Canvas.Top. However, this is not considered a transformation; the UI object keeps its own local origin point for transformation purposes.

You can apply a group of multiple transformations, which can also include an IXRSkewTransform, to a UI object by using an IXRTransformGroup object. You can create custom transformations by using IXRMatrixTransform.

Note

A font can simulate an italic style by shearing, or skewing a glyph. However, a true italic font generally looks better than a simulated italic font. For more information about glyphs in Silverlight for Windows Embedded, see IXRGlyphs.

To apply a skew transformation to a UI object, create an IXRSkewTransform instance and specify the desired offset values in SetAngleX, SetAngleY, SetCenterX, and SetCenterY. Then, apply the transformation to the object by passing it into the inherited method IXRUIElement::SetRenderTransform.

The following illustration shows three skew transformations of a rectangle:

Ee502751.c38ea949-4f03-45a0-a4d6-9b98737f0663(en-US,WinEmbedded.60).jpg

You can also define a skew transformation in Microsoft Silverlight 2 XAML. For information about the differences between XAML in Silverlight for Windows Embedded and Silverlight 2, see Differences Between Silverlight for the Web and Silverlight for Windows Embedded. For more information about how to define this element in the source XAML for your application, see this Microsoft Web site.

Inheritance Hierarchy

IXRDependencyObject

    IXRGeneralTransform

        IXRTransform

            IXRSkewTransform

.NET Framework Equivalent

System.Windows.Media.SkewTransform

Requirements

Header XamlRuntime.h
sysgen SYSGEN_XAML_RUNTIME
Windows Embedded CE Windows Embedded CE 6.0 R3

See Also

Reference

Classes for Visual Appearance and Behavior

Other Resources