Mega Code Archive

 
Categories / C# / WPF
 

Empirical Tilted Text Shadow

<Canvas xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"         xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">     <Canvas.Resources>         <Style TargetType="{x:Type TextBlock}">             <Setter Property="FontFamily" Value="Times New Roman" />             <Setter Property="FontSize" Value="144" />             <Setter Property="Text" Value="Shadow" />             <Setter Property="Canvas.Left" Value="96" />             <Setter Property="Canvas.Top" Value="192" />         </Style>     </Canvas.Resources>     <!-- Shadow Text. -->     <TextBlock Foreground="DarkGray">         <TextBlock.RenderTransform>             <TransformGroup>                 <ScaleTransform ScaleY="3" CenterY="100" />                 <SkewTransform AngleX="-45" CenterY="100" />             </TransformGroup>         </TextBlock.RenderTransform>     </TextBlock>     <!-- Foreground Text. -->     <TextBlock /> </Canvas>