Intersoft ClientUI Documentation
ContentTransformer Class
Members  See Also  Send Feedback
Intersoft.Client.UI.Controls Namespace : ContentTransformer Class






Represents a control that applies transformations to its Content.

Object Model

ContentTransformer Class

Syntax

Visual Basic (Declaration) 
<TemplatePartAttribute(Name="TransformRoot", Type=System.Windows.Controls.Grid)>
<TemplatePartAttribute(Name="Presenter", Type=System.Windows.Controls.ContentPresenter)>
<DescriptionAttribute("Represents a control that applies transformations to its Content.")>
Public NotInheritable Class ContentTransformer 
   Inherits Intersoft.Client.Framework.ISContentControl
   Implements IControlIFramework, ILicensing 
Visual Basic (Usage)Copy Code
Dim instance As ContentTransformer
C# 
[TemplatePartAttribute(Name="TransformRoot", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="Presenter", Type=System.Windows.Controls.ContentPresenter)]
[DescriptionAttribute("Represents a control that applies transformations to its Content.")]
public sealed class ContentTransformer : Intersoft.Client.Framework.ISContentControl, IControlIFramework, ILicensing  
Delphi 
public class ContentTransformer = class(Intersoft.Client.Framework.ISContentControl, IControl, IFramework, ILicensing)sealed; 
JScript 
TemplatePartAttribute(Name="TransformRoot", Type=System.Windows.Controls.Grid)
TemplatePartAttribute(Name="Presenter", Type=System.Windows.Controls.ContentPresenter)
DescriptionAttribute("Represents a control that applies transformations to its Content.")
public sealed class ContentTransformer extends Intersoft.Client.Framework.ISContentControl implements IControlIFramework, ILicensing 
Managed Extensions for C++ 
[TemplatePartAttribute(Name="TransformRoot", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="Presenter", Type=System.Windows.Controls.ContentPresenter)]
[DescriptionAttribute("Represents a control that applies transformations to its Content.")]
public __gc __sealed class ContentTransformer : public Intersoft.Client.Framework.ISContentControl, IControlIFramework, ILicensing  
C++/CLI 
[TemplatePartAttribute(Name="TransformRoot", Type=System.Windows.Controls.Grid)]
[TemplatePartAttribute(Name="Presenter", Type=System.Windows.Controls.ContentPresenter)]
[DescriptionAttribute("Represents a control that applies transformations to its Content.")]
public ref class ContentTransformer sealed : public Intersoft.Client.Framework.ISContentControl, IControlIFramework, ILicensing  

Remarks

ContentTransfomer is inherited from ISContentControl, which means it can contain a single object of any type (such as a string, an image, or a panel). For more information about this content model, see Content Model Overview.

At the core of ContentTransfomer is the Transform property which applies transformation effects such as ScaleTransform and RotateTransform to its content. The transformation of ContentTransfomer works differently compared to the standard RenderTransform provided in the built-in Silverlight elements.

The ContentTransfomer transforms its content with respect to the dimension and boundary of the main container, while Silverlight's RenderTransform applies the transformation using relative points. 

The following illustration compares the transformation results of ContentTransfomer and RenderTransform.

 

As shown in the above illustration, the ContentTransfomer applies the RotationTransform to the menu bar while properly aligning the menu bar to the boundary of the main container. This behavior is useful in a number of scenarios where you want to apply the transformation effects on a content that can be easily arranged and layouted.

The following example shows how to use ContentTransfomer to apply RotationTransform to its content.

XAML Copy Code
<Intersoft:ContentTransformer VerticalAlignment="Top">
    <Intersoft:ContentTransformer.Transform>
        <CompositeTransform Rotation="-90"/>
    </Intersoft:ContentTransformer.Transform>

    <Intersoft:UXMenuBar VerticalAlignment="Top">
        <Intersoft:UXMenuItem Header="File">
            <Intersoft:UXMenuItem Header="New"/>
        </Intersoft:UXMenuItem>
        <Intersoft:UXMenuItem Header="Edit"/>
            <Intersoft:UXMenuItem Header="Cut"/>
        </Intersoft:UXMenuItem>
    </Intersoft:UXMenuBar>

</Intersoft:ContentTransformer>

Inheritance Hierarchy

System.Object
   System.Windows.DependencyObject
      System.Windows.UIElement
         System.Windows.FrameworkElement
            System.Windows.Controls.Control
               System.Windows.Controls.ContentControl
                  Intersoft.Client.Framework.ISContentControl
                     Intersoft.Client.UI.Controls.ContentTransformer

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2012 All Rights Reserved.