views:

212

answers:

1

I have an image control in a resizable window with its stretch property set to UniformToFill.

<Image Name="some_image" Stretch="UniformToFill" Margin="0,0,0,0" />

The clipping window is pegged to the top left of the image; resizing chops off the right and bottom of the image.

I want the image to be clipped equally on all sides. Am i being dense and overlooking an obvious solution?

How do i control how the image gets clipped?

(Unrelated: This is my first post to stackoverflow. I just wanted to start off saying, thanks, this site has been amazing resource for me)

A: 

The HorizontalAlignment and VerticalAlignment property determine this behavior with an image control.

 <Image Name="some_image" Stretch="UniformToFill" Margin="0,0,0,0" HorizontalAlignment="Center" VerticalAlignment="Center" />

Guess i was being dense!

JohnU