<Stackpanel>

<!--변형(Transform)-->

<Button Margin="0" Width="50" Height="50">버튼</Button>

<!--RenderTransformOrigin="1,1" - 우측하단기준점설정(05.,05 버튼 중심)-->

<Button Margin="0" Width="50" Height="50" RenderTransformOrigin="0.5,0.5">

<Button.RenderTransform> <!-- <Button.LayoutTransform> 컨트롤이 서로 겹치지 않게 변형되게 해준다-->

<RotateTransform Angle="45"/> <!--회전변형을 위한 Element 디폴트 기준축은 좌측상단(0,0)-->

</Button.RenderTransform>

<Button.Content>

버튼1

</Button.Content>

</Button>

 

<Button Margin="0" Width="50" Height="50" RenderTransformOrigin="0.5,0.5">

<Button.RenderTransform>

<RotateTransform Angle="45"/>

</Button.RenderTransform>

<Button.Content>

버튼2

</Button.Content>

</Button>

 

<Button Margin="0" Width="50" Height="50" RenderTransformOrigin="0.5,0.5">

<Button.RenderTransform>

<ScaleTransform ScaleX="2" ScaleY="2"/><!--확대하고싶은 배율(0.5 반으로 줄어듬) 모든 변형을 기준점이 있음-->

</Button.RenderTransform>

<Button.Content>

버튼3

</Button.Content>

</Button>

 

<Button Margin="0" Width="50" Height="50" RenderTransformOrigin="0.5,0.5">

<Button.RenderTransform>

<SkewTransform AngleX="30" AngleY="30"/><!--비트는 변형-->

</Button.RenderTransform>

<Button.Content>

버튼4

</Button.Content>

</Button>

</StackPanel>


 

 

by 피요히코~ 2009. 2. 25. 12:53
| 1 |