Applies a RotateTransform to the brush's Transform property : Transform « Windows Presentation Foundation « VB.Net






Applies a RotateTransform to the brush's Transform property

Applies a RotateTransform to the brush's Transform property
     
<Window x:Class="Workspace.DockExample"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="Workspace" Width="640" Height="480">
    <Window.Resources>
    <GradientStopCollection x:Key="myGradientStops">
      <GradientStop Offset="0.0" Color="Blue" />
      <GradientStop Offset="0.4" Color="Black" />
      <GradientStop Offset="0.5" Color="White" />
      <GradientStop Offset="0.6" Color="Black" />
      <GradientStop Offset="0.7" Color="Blue" />
    </GradientStopCollection>
    
    </Window.Resources>
    <Rectangle Width="175" Height="90" Stroke="Black">
      <Rectangle.Fill>
        <RadialGradientBrush GradientStops="{StaticResource myGradientStops}">
          <RadialGradientBrush.Transform>
            <RotateTransform CenterX="87.5" CenterY="45" Angle="45" />
          </RadialGradientBrush.Transform>
        </RadialGradientBrush>
      </Rectangle.Fill>
    </Rectangle>


</Window>

   
    
    
    
    
  








Related examples in the same category

1.RenderTransform sectionRenderTransform section
2.LayoutTransform sectionLayoutTransform section
3.Transformed Buttons with TranslateTransform X/YTransformed Buttons with TranslateTransform X/Y
4.Transformed Buttons with ScaleTransform and ScaleYTransformed Buttons with ScaleTransform and ScaleY
5.Transformed Buttons with SkewTransform and AngleYTransformed Buttons with SkewTransform and AngleY
6.Transformed Buttons with RotateTransform And AngleTransformed Buttons with RotateTransform And Angle
7.Animate Button RenderTransformAnimate Button RenderTransform
8.Animate Button LayoutTransformAnimate Button LayoutTransform
9.Translate TransformTranslate Transform
10.ScaleTransformScaleTransform
11.SkewTransform appliedSkewTransform applied
12.TranslateTransform : LayoutTransform SampleTranslateTransform : LayoutTransform Sample
13.MatrixTransform SampleMatrixTransform Sample
14.Rotate Button Along the center and AngleRotate Button Along the center and Angle
15.Render Tranform
16.Rotate a ButtonRotate a Button
17.Rotate in a circle, then flip, when clickedRotate in a circle, then flip, when clicked
18.RotateTransform AppliedRotateTransform Applied
19.Rotation of content by using RotateTransformRotation of content by using RotateTransform
20.Object Transforms in WPFObject Transforms in WPF