Xceed Toolkit Plus for WPF v5.0 Documentation
Xceed.Wpf.Toolkit Assembly / Xceed.Wpf.Toolkit.Panels Namespace / WrapPanel Class
Members Example


In This Topic
    WrapPanel Class
    In This Topic
    A Panel that wraps its children's content.
    Syntax
    'Declaration
     
    <LocalizabilityAttribute(LocalizationCategory.Ignore)>
    <ContentPropertyAttribute("Children")>
    <StyleTypedPropertyAttribute(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)>
    <XmlLangPropertyAttribute("Language")>
    <UsableDuringInitializationAttribute(True)>
    <RuntimeNamePropertyAttribute("Name")>
    <UidPropertyAttribute("Uid")>
    <TypeDescriptionProviderAttribute(MS.Internal.ComponentModel.DependencyObjectProvider)>
    <NameScopePropertyAttribute("NameScope", System.Windows.NameScope)>
    Public Class WrapPanel 
       Inherits AnimationPanel
    'Usage
     
    Dim instance As WrapPanel
    [Localizability(LocalizationCategory.Ignore)]
    [ContentProperty("Children")]
    [StyleTypedProperty(Property="FocusVisualStyle", StyleTargetType=System.Windows.Controls.Control)]
    [XmlLangProperty("Language")]
    [UsableDuringInitialization(true)]
    [RuntimeNameProperty("Name")]
    [UidProperty("Uid")]
    [TypeDescriptionProvider(MS.Internal.ComponentModel.DependencyObjectProvider)]
    [NameScopeProperty("NameScope", System.Windows.NameScope)]
    public class WrapPanel : AnimationPanel 
    Example
    <Window x:Class="WrapPanelSample.MainWindow"
            xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
            xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
            xmlns:xctk="http://schemas.xceed.com/wpf/xaml/toolkit"
            Title="WrapPanelSample">
     <Grid>
        <xctk:WrapPanel  ItemWidth="100"
                        ItemHeight="100">
          <Rectangle Margin="2, 2, 2, 2" Fill="Red"/>
          <Rectangle Margin="2, 2, 2, 2" Fill="Blue"/>
          <Rectangle Margin="2, 2, 2, 2" Fill="Green"/>
          <Rectangle Margin="2, 2, 2, 2" Fill="Orange"/>
          <Rectangle Margin="2, 2, 2, 2" Fill="Purple"/>
          <Rectangle Margin="2, 2, 2, 2" Fill="Yellow"/>
        </xctk:WrapPanel>
      </Grid>
    </Window>
    Inheritance Hierarchy

    System.Object
       System.Windows.Threading.DispatcherObject
          System.Windows.DependencyObject
             System.Windows.Media.Visual
                System.Windows.UIElement
                   System.Windows.FrameworkElement
                      System.Windows.Controls.Panel
                         Xceed.Wpf.Toolkit.Panels.PanelBase
                            Xceed.Wpf.Toolkit.Panels.AnimationPanel
                               Xceed.Wpf.Toolkit.Panels.WrapPanel

    Requirements

    Target Platforms: Windows 11, Windows 10, 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