Using a RadialGradientBrush : RadialGradientBrush « Windows Presentation Foundation « VB.Net






Using a RadialGradientBrush

Using a RadialGradientBrush
     

<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
      xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
      HorizontalAlignment="Center" VerticalAlignment="Center">

    <Rectangle Width="200" Height="150">
      <Rectangle.Fill>
        <RadialGradientBrush Center="0.45,0.5" RadiusX="0.3" RadiusY="0.5" GradientOrigin="0.25,0.4">
          <GradientStop Color="White" Offset="0" />
          <GradientStop Color="Red" Offset="0.5" />
          <GradientStop Color="DarkBlue" Offset="1" />
        </RadialGradientBrush>
      </Rectangle.Fill>
    </Rectangle>

</Page>

   
    
    
    
    
  








Related examples in the same category

1.RadialGradientBrush ExamplesRadialGradientBrush Examples
2.Fill with offset RadialGradientBrushFill with offset RadialGradientBrush
3.Using RadialGradientBrush to fill a RectangleUsing RadialGradientBrush to fill a Rectangle
4.RadialGradientBrush.RelativeTransformRadialGradientBrush.RelativeTransform
5.Use OpacityMask and RadialGradientBrushUse OpacityMask and RadialGradientBrush
6.RotateTransform RadialGradientBrush.TransformRotateTransform RadialGradientBrush.Transform
7.RadialGradientBrush and GradientStopRadialGradientBrush and GradientStop
8.Centered RadialGradientBrush static resourceCentered RadialGradientBrush static resource