GroupItem styles and templates

[ This article is for Windows 8.x and Windows Phone 8.x developers writing Windows Runtime apps. If you’re developing for Windows 10, see the latest documentation ]

This topic describes the styles and templates for the GroupItem control. You can modify these resources and the default ControlTemplate to give the control a unique appearance.

Visual states

The GroupItem default style doesn't define any visual states.

Theme resources

The GroupItem default style doesn't use any theme resources.

For more info on theme resources, including the values that are used for the HighContrast theme, see XAML theme resources reference.

Default style

<!-- Default style for Windows.UI.Xaml.Controls.GroupItem -->
<Style TargetType="GroupItem">
    <Setter Property="IsTabStop" Value="False" />
    <Setter Property="Template">
            <ControlTemplate TargetType="GroupItem">
                <Border Background="{TemplateBinding Background}"
                        BorderBrush="{TemplateBinding BorderBrush}"
                        BorderThickness="{TemplateBinding BorderThickness}">
                            <RowDefinition Height="Auto" />
                            <RowDefinition Height="*" />
                        <ContentControl x:Name="HeaderContent"
                                        Content="{TemplateBinding Content}"
                                        ContentTransitions="{TemplateBinding ContentTransitions}"
                                        ContentTemplate="{TemplateBinding ContentTemplate}"
                                        ContentTemplateSelector="{TemplateBinding ContentTemplateSelector}"
                                        Margin="{TemplateBinding Padding}"
                                        IsTabStop="False" />
                        <ItemsControl x:Name="ItemsControl"
                                      ItemsSource="{Binding GroupItems}"
                                      TabIndex="1" >
                                    <AddDeleteThemeTransition />
                                    <ContentThemeTransition />
                                    <ReorderThemeTransition />
                                    <EntranceThemeTransition IsStaggeringEnabled="False" />