我想在Grid
内展开Viewbox
。我有上帝的代码不能正常工作。任何线索?
<Viewbox HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Grid HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="Auto"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Grid.RowDefinitions>
<RowDefinition Height="*"></RowDefinition>
<RowDefinition Height="Auto"></RowDefinition>
</Grid.RowDefinitions>
</Grid>
</Viewbox>
答案 0 :(得分:4)
答案 1 :(得分:1)
将Viewbox的strech属性更改为Fill,如下所示。
&LT; Viewbox Stretch =&#34;填充&#34; &GT;