RectangleGeometry : WPF Shapes « WPF « ASP.Net






RectangleGeometry

<Canvas Width="300" Height="300"
   xmlns="http://schemas.microsoft.com/client/2007"
   xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">

  <Ellipse Height="200" Width="200" 
       Canvas.Left="30" Canvas.Top="30" Canvas.ZIndex="2"
       Stroke="Black" StrokeThickness="10" Fill="Blue">
    <Ellipse.Clip>
      <RectangleGeometry Rect="0, 0, 100, 100"/>
    </Ellipse.Clip>
  </Ellipse>


  <Ellipse Height="200" Width="200" Canvas.Left="30" Canvas.Top="30"
     Stroke="Black" StrokeThickness="10" Fill="Blue" Opacity="0.3">
  </Ellipse>
</Canvas>

 








Related examples in the same category

1.TextBlock
2.LinearGradientBrush
3.Ellipse
4.Polyline
5.Ellipse.OpacityMask
6.Rectangle.RenderTransform
7.Nested Canvas