修改GridView模板时查看完整网格项

修改GridView模板时查看完整网格项,gridview,windows-8,microsoft-metro,datatemplate,Gridview,Windows 8,Microsoft Metro,Datatemplate,我有这个xaml代码: <local:MyGridView x:Name="topDeal" ItemsSource="{Binding}" Margin="60,0,0,0" Grid.Row="1"> <GridView.ItemTemplate> <DataTemplate> &

我有这个xaml代码:

                <local:MyGridView x:Name="topDeal" ItemsSource="{Binding}" Margin="60,0,0,0" Grid.Row="1">
                    <GridView.ItemTemplate> 
                        <DataTemplate>
                            <Grid Margin="0">
                                <Grid.Background>
                                    <ImageBrush ImageSource="{Binding image1}"/>
                                </Grid.Background>

                                <StackPanel VerticalAlignment="Bottom" Background="#0072B0" Opacity="0.6">
                                    <Border BorderBrush="LightGray" BorderThickness="0,0,0,1"/>
                                    <TextBlock Text="{Binding name}" Foreground="white"/>
                                </StackPanel>
                            </Grid>
                        </DataTemplate>
                    </GridView.ItemTemplate>
                    <GridView.ItemsPanel>
                        <ItemsPanelTemplate>
                            <VariableSizedWrapGrid ItemHeight="180" ItemWidth="180" Orientation="Horizontal" MaximumRowsOrColumns="4"/>
                        </ItemsPanelTemplate>
                    </GridView.ItemsPanel>
                </local:MyGridView>
我想让第一个项目显示在一个背景图像的其他项目的两倍大小。结果是这样的。背景图像仅为填充文本块


在您的数据模板中,您可以尝试这种方法,如果我没有错的话,它应该适合您:

`<Border Background="{StaticResource ListViewItemPlaceholderBackgroundThemeBrush}" Margin="0,0,0,80"><Image Source="{Binding Image}" AutomationProperties.Name="{Binding Title}" Stretch="UniformToFill" Height="Auto" Width="Auto"/></Border>`
``

谢谢,我找到了另一个解决方案。我使用而不是和
`<Border Background="{StaticResource ListViewItemPlaceholderBackgroundThemeBrush}" Margin="0,0,0,80"><Image Source="{Binding Image}" AutomationProperties.Name="{Binding Title}" Stretch="UniformToFill" Height="Auto" Width="Auto"/></Border>`