C# Class WinRTXamlToolkit.Controls.LayoutTransformControl

Inheritance: Windows.UI.Xaml.Controls.Control
Mostrar archivo Open project: xyzzer/WinRTXamlToolkit

Public Properties

Property Type Description
ChildProperty Windows.UI.Xaml.DependencyProperty
TransformProperty Windows.UI.Xaml.DependencyProperty

Public Methods

Method Description
LayoutTransformControl ( ) : System

Initializes a new instance of the LayoutTransformControl class.

TransformUpdated ( ) : void

Notifies the LayoutTransformControl that some aspect of its Transform property has changed.

Call this to update the LayoutTransform in cases where LayoutTransformControl wouldn't otherwise know to do so.

Protected Methods

Method Description
ArrangeOverride ( Size finalSize ) : Size

Provides the behavior for the "Arrange" pass of layout.

Using the WPF paramater name finalSize instead of Silverlight's finalSize for clarity.

MeasureOverride ( Size availableSize ) : Size

Provides the behavior for the "Measure" pass of layout.

OnApplyTemplate ( ) : void

Called whenever the control's template changes.

Private Methods

Method Description
ChildChanged ( DependencyObject o, DependencyPropertyChangedEventArgs e ) : void

Handle changes to the child dependency property.

ComputeLargestTransformedSize ( Size arrangeBounds ) : Size
GetTransformMatrix ( Transform transform ) : Matrix

Walks the Transform and returns the corresponding matrix.

IsSizeSmaller ( Size a, Size b ) : bool

Return true if Size a is smaller than Size b in either dimension.

MatrixHasInverse ( Matrix matrix ) : bool

Implements Windows Presentation Foundation's Matrix.HasInverse on Silverlight.

MatrixMultiply ( Matrix matrix1, Matrix matrix2 ) : Matrix

Implements Windows Presentation Foundation's Matrix.Multiply on Silverlight.

OnChildChanged ( FrameworkElement newContent ) : void

Updates content when the child property is changed.

OnTransformChanged ( Transform oldValue, Transform newValue ) : void

Processes the transform when the transform is changed.

OnTransformPropertyChanged ( object sender, double e ) : void

Called when a property of a Transform changes.

ProcessTransform ( ) : void

Processes the current transform to determine the corresponding matrix.

RectTransform ( Rect rectangle, Matrix matrix ) : Rect

Implement Windows Presentation Foundation's Rect.Transform on Silverlight.

RoundMatrix ( Matrix matrix, int decimalsAfterRound ) : Matrix

Rounds the non-offset elements of a matrix to avoid issues due to floating point imprecision.

SubscribeToTransformPropertyChanges ( Transform transform ) : void
TransformChanged ( DependencyObject o, DependencyPropertyChangedEventArgs e ) : void

Handles changes to the Transform DependencyProperty.

UnsubscribeFromTransformPropertyChanges ( Transform transform ) : void

Method Details

ArrangeOverride() protected method

Provides the behavior for the "Arrange" pass of layout.
Using the WPF paramater name finalSize instead of Silverlight's finalSize for clarity.
protected ArrangeOverride ( Size finalSize ) : Size
finalSize Windows.Foundation.Size The final area within the parent that this /// element should use to arrange itself and its children.
return Windows.Foundation.Size

LayoutTransformControl() public method

Initializes a new instance of the LayoutTransformControl class.
public LayoutTransformControl ( ) : System
return System

MeasureOverride() protected method

Provides the behavior for the "Measure" pass of layout.
protected MeasureOverride ( Size availableSize ) : Size
availableSize Windows.Foundation.Size The available size that this element can /// give to child elements. Infinity can be specified as a value to /// indicate that the element will size to whatever content is /// available.
return Windows.Foundation.Size

OnApplyTemplate() protected method

Called whenever the control's template changes.
protected OnApplyTemplate ( ) : void
return void

TransformUpdated() public method

Notifies the LayoutTransformControl that some aspect of its Transform property has changed.
Call this to update the LayoutTransform in cases where LayoutTransformControl wouldn't otherwise know to do so.
public TransformUpdated ( ) : void
return void

Property Details

ChildProperty public_oe static_oe property

Identifies the ChildProperty.
public static DependencyProperty,Windows.UI.Xaml ChildProperty
return Windows.UI.Xaml.DependencyProperty

TransformProperty public_oe static_oe property

Identifies the TransformProperty dependency property.
public static DependencyProperty,Windows.UI.Xaml TransformProperty
return Windows.UI.Xaml.DependencyProperty