Gets the logical origin of this
AnnObjectBase.
Syntax
Visual Basic (Declaration) | |
---|
Public Overridable ReadOnly Property Origin As Point |
Visual Basic (Usage) | Copy Code |
---|
Dim instance As AnnObjectBase
Dim value As Point
value = instance.Origin
|
C# | |
---|
public virtual Point Origin {get;} |
C++/CLI | |
---|
public:
virtual property Point Origin {
Point get();
} |
XAML Syntax | |
---|
You cannot use this property in XAML. |
XAML Syntax | |
---|
You cannot use this property in XAML. |
Return Value
The logical origin of this
AnnObjectBase.
Example
Visual Basic | Copy Code |
---|
Private Sub AnnObject_RenderTransform(ByVal obj As AnnObjectBase)
ShowMatrix(obj.RenderTransform.Value)
obj.Translate(2, 3)
ShowMatrix(obj.RenderTransform.Value)
obj.Scale(1.5F, 1.5F, obj.Origin)
ShowMatrix(obj.RenderTransform.Value)
obj.Rotate(45, obj.Origin)
ShowMatrix(obj.RenderTransform.Value)
obj.ResetTransform()
ShowMatrix(obj.RenderTransform.Value)
End Sub
Private Sub ShowMatrix(ByVal mat As Matrix)
Console.Write("{0}, ", mat.M11)
Console.Write("{0}, ", mat.M12)
Console.Write("{0}, ", mat.M21)
Console.Write("{0}, ", mat.M22)
Console.Write("{0}, ", mat.OffsetX)
Console.Write("{0}, ", mat.OffsetY)
End Sub |
C# | Copy Code |
---|
private void AnnObject_RenderTransform(AnnObjectBase obj) { // show the matrix ShowMatrix(obj.RenderTransform.Value); obj.Translate(2, 3); ShowMatrix(obj.RenderTransform.Value); obj.Scale(1.5F, 1.5F, obj.Origin); ShowMatrix(obj.RenderTransform.Value); obj.Rotate(45, obj.Origin); ShowMatrix(obj.RenderTransform.Value); obj.ResetTransform(); ShowMatrix(obj.RenderTransform.Value); } private void ShowMatrix(Matrix mat) { Console.Write("{0}, ", mat.M11); Console.Write("{0}, ", mat.M12); Console.Write("{0}, ", mat.M21); Console.Write("{0}, ", mat.M22); Console.Write("{0}, ", mat.OffsetX); Console.Write("{0}, ", mat.OffsetY); } |
Remarks
Requirements
Target Platforms: Microsoft .NET Framework 3.0, Windows XP, Windows Vista, and Windows Server 2003 family
See Also