Mega Code Archive

 
Categories / VB.Net Tutorial / WPF
 

None Stretch ImageBrush

<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"     x:Class="Microsoft.Samples.Graphics.RectangleExample"     WindowTitle="Example">   <Canvas>       <Rectangle Canvas.Left="10" Canvas.Top="10"  Width="271" Height="100" Stroke="Black">         <Rectangle.Fill>           <ImageBrush ImageSource="c:\image.gif" Stretch="None"></ImageBrush>         </Rectangle.Fill>       </Rectangle>   </Canvas> </Page>