Quantcast
Viewing all articles
Browse latest Browse all 18858

I set Stretch of Grid.Background to None, but it doesn't work.

My code below:

<Grid Name="MainGrid" Width="700" Height="400">
        <Grid.Background>
            <ImageBrush ImageSource="/Memoryer;component/Images/BackGround.png" Stretch="None" TileMode="None" />
        </Grid.Background>
</Grid>

the BackGround.png is 700x400,  the image should be just fit to the Grid, but it cant works,

the image looks become very big, and the Grid only shows a part of BackGround.png.


Viewing all articles
Browse latest Browse all 18858

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>