I have a window with a button. When you click the button popup appears. How can I darken the full screen when open popup?
问问题
1190 次
3 回答
0
You should write your own shader in order to darken, lighten, engraying, moting blurring and doing other cool graphics stuff.
Of course, if you don't want it to do in a right way, you could just create an Rectangle
with IsHitTestVisible = false
property and black color and some 0.5f
opacity all over your form, but...
于 2013-03-30T08:12:46.620 回答
0
One easy way to do this is to create a new UserControl like this:
<UserControl ...
<Grid Background="#AA000000"> <!-- control the overlay color here -->
<Border Background="White" BorderBrush="Black" BorderThickness="1" HorizontalAlignment="Center" VerticalAlignment="Center" Padding="10">
<TextBlock Text="content"/>
</Border>
</Grid>
</UserControl>
Than just add it to the top grid of your window.
于 2013-03-30T08:24:51.977 回答