Silverlight Grid 边界线处理
时间:2010-12-25 来源:duicky
Demo:
<Border Height="480" Width="640" BorderBrush="#FFFF0000" BorderThickness="2,2,2,2">
    <Grid x:Name="LayoutRoot">
    <Grid.ColumnDefinitions>
    <ColumnDefinition Width="1*"/>
    <ColumnDefinition Width="1*"/>
    </Grid.ColumnDefinitions>
    <Grid.RowDefinitions>
    <RowDefinition Height="1*"/>
    <RowDefinition Height="1*"/>
    </Grid.RowDefinitions>
    <Rectangle HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" Stroke="#FF008BFF"/>
    <Rectangle HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" Stroke="#FF008BFF" Grid.Column="1"/>
    <Rectangle HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" Stroke="#FF008BFF" Grid.Row="1"/>
    <Rectangle HorizontalAlignment="Stretch" Margin="0,0,0,0" VerticalAlignment="Stretch" Stroke="#FF008BFF" Grid.Row="1" Grid.Column="1"/>
      </Grid>
    </Border>










