Transform 類別
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
定義可在 2-D 平面轉換的功能。 轉換包含旋轉 (RotateTransform)、縮放 (ScaleTransform)、扭曲 (SkewTransform) 和平移 (TranslateTransform)。 此類別階層與 Matrix 結構的差別在於其為類別,而且支援動畫和列舉語意。
public ref class Transform abstract : System::Windows::Media::GeneralTransform
[System.ComponentModel.TypeConverter(typeof(System.Windows.Media.TransformConverter))]
[System.Windows.Localizability(System.Windows.LocalizationCategory.None, Readability=System.Windows.Readability.Unreadable)]
public abstract class Transform : System.Windows.Media.GeneralTransform
[<System.ComponentModel.TypeConverter(typeof(System.Windows.Media.TransformConverter))>]
[<System.Windows.Localizability(System.Windows.LocalizationCategory.None, Readability=System.Windows.Readability.Unreadable)>]
type Transform = class
inherit GeneralTransform
interface DUCE.IResource
[<System.ComponentModel.TypeConverter(typeof(System.Windows.Media.TransformConverter))>]
[<System.Windows.Localizability(System.Windows.LocalizationCategory.None, Readability=System.Windows.Readability.Unreadable)>]
type Transform = class
inherit GeneralTransform
Public MustInherit Class Transform
Inherits GeneralTransform
- 繼承
- 衍生
- 屬性
MatrixTransform使用 類別來建立 、 ScaleTransform 、 SkewTransform 和 TranslateTransform 類別未提供的 RotateTransform 自訂轉換。
2D x-y 平面會使用 3x3 矩陣進行轉換。 您可以將斜線轉換矩陣乘以形成線性轉換,例如旋轉和扭曲 (旋轉) ,後面接著轉譯。
affine 轉換矩陣的最終資料行等於 (0, 0, 1) ;因此,您只需要在前兩個數據行中指定成員。
Windows Presentation Foundation (WPF) Matrix 具有下列結構:
最後一個資料列 OffsetX 和 OffsetY 中的成員代表翻譯值。
方法和屬性通常會將轉換矩陣指定為只有六個成員的向量;如下所示:
(M11, M12, M21, M22, OffsetX, OffsetY)
Can |
取得值,指出是否可以將物件設為不可修改。 (繼承來源 Freezable) |
Dependency |
取得包裝 DependencyObjectType 這個實例 CLR 型別的 。 (繼承來源 DependencyObject) |
Dispatcher |
取得與這個 Dispatcher 關聯的 DispatcherObject。 (繼承來源 DispatcherObject) |
Has |
取得值,這個值表示是否有一個或多個 AnimationClock 物件與這個物件的任何一個相依性屬性相關聯。 (繼承來源 Animatable) |
Identity |
取得識別 (Identity) 轉換。 |
Inverse |
取得這個轉換的反向 (如果有的話)。 |
Is |
取得值,該值表示物件目前是否可修改。 (繼承來源 Freezable) |
Is |
取得值,這個值表示此執行個體目前是否已密封 (唯讀)。 (繼承來源 DependencyObject) |
Value |
取得目前轉換做為 Matrix 物件。 |
IFormattable. |
使用指定的格式,格式化目前執行個體的值。 (繼承來源 GeneralTransform) |
產品 | 版本 |
---|---|
.NET Framework | 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1 |
Windows Desktop | 3.0, 3.1, 5, 6, 7, 8, 9 |