Windows phone 中的Grid布局

it2022-05-05  159

        <!--ContentPanel - place additional content here-->         <Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">             <Grid.RowDefinitions>                 <RowDefinition Height=".8*"></RowDefinition>                 <RowDefinition Height=".2*"></RowDefinition>             </Grid.RowDefinitions>             <Image Source="Assets/SplashImage.jpg" VerticalAlignment="Center" HorizontalAlignment="Center" Width="471" Height="492"></Image>             <Button Content="Start!" Name="StartButton" Grid.Row="1" VerticalAlignment="Center" HorizontalAlignment="Center"></Button>         </Grid>

 

        <!--ContentPanel - place additional content here-->         <Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0">

            这里是行的定义,.8* .2* 代表一个行占位80%,一个行占位20%             <Grid.RowDefinitions>                 <RowDefinition Height=".8*"></RowDefinition>                 <RowDefinition Height=".2*"></RowDefinition>             </Grid.RowDefinitions>

            这里是内容部分,按照上面的行布局来展示             <Image Source="Assets/SplashImage.jpg" VerticalAlignment="Center" HorizontalAlignment="Center" Width="471" Height="492"></Image>             <Button Content="Start!" Name="StartButton" Grid.Row="1" VerticalAlignment="Center" HorizontalAlignment="Center"></Button>         </Grid>

转载于:https://www.cnblogs.com/binaryworms/archive/2012/06/27/2565539.html

相关资源:各显卡算力对照表!

最新回复(0)