Intersoft ClientUI Documentation
ExpandableContentPresenter Class
Members 



Provides a lightweight expandable content presenter.
Object Model
ExpandableContentPresenter ClassISFramework Class
Syntax
<TemplatePartAttribute(Name="ContentSite", Type=System.Windows.Controls.ContentPresenter)>
<DescriptionAttribute("Provides a lightweight expandable content presenter.")>
Public Class ExpandableContentPresenter 
   Inherits Intersoft.Client.Framework.ISContentControl
   Implements Intersoft.Client.Framework.IControlIntersoft.Client.Framework.IFramework, Intersoft.Client.Framework.ILicensing 
Dim instance As ExpandableContentPresenter
[TemplatePartAttribute(Name="ContentSite", Type=System.Windows.Controls.ContentPresenter)]
[DescriptionAttribute("Provides a lightweight expandable content presenter.")]
public class ExpandableContentPresenter : Intersoft.Client.Framework.ISContentControl, Intersoft.Client.Framework.IControlIntersoft.Client.Framework.IFramework, Intersoft.Client.Framework.ILicensing  
[TemplatePartAttribute(Name="ContentSite", Type=System.Windows.Controls.ContentPresenter)]
[DescriptionAttribute("Provides a lightweight expandable content presenter.")]
public ref class ExpandableContentPresenter : public Intersoft.Client.Framework.ISContentControl, Intersoft.Client.Framework.IControlIntersoft.Client.Framework.IFramework, Intersoft.Client.Framework.ILicensing  
Remarks

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

The content of ExpandableContentPresenter must be a UIElement with fixed Height and/or Width, which is used as reference for the expand and collapse animation.

To expand and collapse the content, simply set the IsExpanded property to true and false respectively. Alternatively, you can use your own animation or storyboard to animate the Percentage property. The Percentage property indicates the area that is currently expanded, which allows you to easily animate this value, from 0 (Collapsed) to 1 (Fully Expanded).

The following example shows how to use the ExpandableContentPresenter control.

XAML
Copy Code
<Intersoft:ExpandableContentPresenter x:Name="ExpandableContainer" VerticalAlignment="Top" FontSize="32">
    <Grid Height="100">
        <Grid.Background>
            <LinearGradientBrush EndPoint="0.5,1" StartPoint="0.5,0">
                <GradientStop Color="#FFFF8027" Offset="0.004"/>
                <GradientStop Color="#FF8F3B00" Offset="1"/>
            </LinearGradientBrush>
        </Grid.Background>
        <ContentPresenter Content="Content Presenter" HorizontalAlignment="Center" VerticalAlignment="Center"/>
    </Grid>
</Intersoft:ExpandableContentPresenter>
<Intersoft:UXCheckBox Content="Expand / Collapsed" HorizontalAlignment="Center" VerticalAlignment="Center" 
                      CheckedState="{Binding IsExpanded, ElementName=ExpandableContainer, Mode=TwoWay}" />    
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.ExpandableContentPresenter

Requirements

Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

See Also

Reference

ExpandableContentPresenter Members
Intersoft.Client.UI.Controls Namespace

Concepts

ExpandableContentPresenter

Send Feedback