C# Class Microsoft.Silverlight.Testing.Client.LayoutTransformer

Inheritance: System.Windows.Controls.ContentControl
Mostra file Open project: garyjohnson/wpnest

Public Properties

Property Type Description
LayoutTransformProperty System.Windows.DependencyProperty

Private Properties

Property Type Description
ComputeLargestTransformedSize System.Windows.Size
DiagnosticWriteLine void
GetTransformMatrix Matrix
IsSizeSmaller bool
LayoutTransformChanged void
MatrixHasInverse bool
MatrixMultiply Matrix
ProcessTransform void
RectTransform System.Windows.Rect
RoundMatrix Matrix

Public Methods

Method Description
ApplyLayoutTransform ( ) : void

Applies the layout transform on the LayoutTransformer control content.

Only used in advanced scenarios (like animating the LayoutTransform). Should be used to notify the LayoutTransformer control that some aspect of its Transform property has changed.

LayoutTransformer ( ) : System

Initializes a new instance of the LayoutTransformer class.

OnApplyTemplate ( ) : void

Builds the visual tree for the LayoutTransformer control when a new template is applied.

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.

Private Methods

Method Description
ComputeLargestTransformedSize ( Size arrangeBounds ) : Size
DiagnosticWriteLine ( string message ) : void
GetTransformMatrix ( Transform transform ) : Matrix

Walks the Transform(Group) and returns the corresponding Matrix.

IsSizeSmaller ( Size a, Size b ) : bool

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

LayoutTransformChanged ( DependencyObject o, System.Windows.DependencyPropertyChangedEventArgs e ) : void

Handles changes to the Transform DependencyProperty.

MatrixHasInverse ( Matrix matrix ) : bool

Implements WPF's Matrix.HasInverse on Silverlight.

MatrixMultiply ( Matrix matrix1, Matrix matrix2 ) : Matrix

Implements WPF's Matrix.Multiply on Silverlight.

ProcessTransform ( Transform transform ) : void

Processes the Transform to determine the corresponding Matrix.

RectTransform ( Rect rect, Matrix matrix ) : Rect

Implements WPF's Rect.Transform on Silverlight.

RoundMatrix ( Matrix matrix, int decimals ) : Matrix

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

Method Details

ApplyLayoutTransform() public method

Applies the layout transform on the LayoutTransformer control content.
Only used in advanced scenarios (like animating the LayoutTransform). Should be used to notify the LayoutTransformer control that some aspect of its Transform property has changed.
public ApplyLayoutTransform ( ) : void
return void

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 System.Windows.Size The final area within the parent that this element should use to arrange itself and its children.
return System.Windows.Size

LayoutTransformer() public method

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

MeasureOverride() protected method

Provides the behavior for the "Measure" pass of layout.
protected MeasureOverride ( Size availableSize ) : Size
availableSize System.Windows.Size The available size that this element can give to child elements.
return System.Windows.Size

OnApplyTemplate() public method

Builds the visual tree for the LayoutTransformer control when a new template is applied.
public OnApplyTemplate ( ) : void
return void

Property Details

LayoutTransformProperty public_oe static_oe property

Identifies the LayoutTransform DependencyProperty.
public static DependencyProperty,System.Windows LayoutTransformProperty
return System.Windows.DependencyProperty