■ ScaleTransform 엘리먼트를 사용하는 방법을 보여준다.
▶ 예제 1 (XAML)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
<Rectangle Width="100" Height="100" Fill="Blue"> <Rectangle.RenderTransform> <ScaleTransform CenterX="50" CenterY="50" ScaleX="0.5" ScaleY="0.5" /> </Rectangle.RenderTransform> </Rectangle> |
▶ 예제 2 (XAML)
1 2 3 4 5 6 7 8 9 10 11 12 13 |
<Rectangle Width="100" Height="100" Fill="Blue" RenderTransformOrigin="0.5 0.5"> <Rectangle.RenderTransform> <ScaleTransform ScaleX="0.5" ScaleY="0.5" /> </Rectangle.RenderTransform> </Rectangle> |