【发布时间】:2019-08-07 11:41:04
【问题描述】:
无论我的View 的大小和分辨率如何,我都希望我的Popup 始终出现在特定的角落(例如右下角)。
我尝试使用HorizontalAlignment 和VerticalAlignment,但它并没有真正起作用。
这是我的代码:
<Grid x:Name="Output" HorizontalAlignment="Right" VerticalAlignment="Bottom" Grid.Row="1">
<Popup x:Name="StandardPopup">
<Border BorderBrush="{StaticResource ApplicationForegroundThemeBrush}"
Background="{StaticResource ApplicationPageBackgroundThemeBrush}"
BorderThickness="2" Width="500" Height="500">
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center">
<WebView x:Name="WebView1" Source="https://www.bing.com/" Width="490" Height="490" HorizontalAlignment="Center"/>
</StackPanel>
</Border>
</Popup>
</Grid>
【问题讨论】:
标签: c# xaml user-interface uwp popup