user1423316
user1423316

Reputation:

WPF: Stretched Image Bigger than grid does not render fully

Hi my image in xaml is as such

<Image Name="bgImg" Width="2000" Stretch="UniformToFill" Height="auto"     VerticalAlignment="Stretch" HorizontalAlignment="Stretch"     Source="./Images/TemasekGrandMap(Kumar).png">

Set in a grid. But when i load the page i see a big image, which is correct, but when i scroll to the right of the browser the image that was off-screen is gone, not rendered. How do i solve this?

Upvotes: 0

Views: 468

Answers (1)

GameAlchemist
GameAlchemist

Reputation: 19294

Since you have a Stretch="UniformToFill" in your image, it may be that the maximum height that your image within its Panel is not big enough, or because of your intial source image aspect ratio. Try a very high grid and with an image having 'right' aspect ratio to verify, then you'll have to think about the size/stretch constaints you want to set on your image.

Upvotes: 1

Related Questions