<GridView Width="90" Height="90"> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <Image Source=" ****" Width="30" Height="30" ></Image> <GridView.ItemContainerStyle> <Style TargetType="GridViewItem"> <Setter Property="BorderBrush" Value="Blue"></Setter> <Setter Property="BorderThickness" Value="0.5"></Setter> <Setter Property="Margin" Value="0"></Setter> </Style> </GridView.ItemContainerStyle> </GridView>
要把这九张图全显示出来怎么设置,现在这样设置图片之间有间距.
GridView的Item自带MinWidth和MinHeight属性,修改即可