A.R*_*.R. 5 c# silverlight wpf xaml expression
有没有办法可以使用普通的Rectangle(形状)作为XAML中另一个对象的剪辑的一部分.看起来我应该能够,但解决方案是逃避我..
<Canvas>
<Rectangle Name="ClipRect" RadiusY="10" RadiusX="10" Stroke="Black" StrokeThickness="0" Width="32.4" Height="164"/>
<!-- This is the part that I cant quite figure out.... -->
<Rectangle Width="100" Height="100" Clip={Binding ElementName=ClipRect, Path="??"/>
</Canvas>
Run Code Online (Sandbox Code Playgroud)
我知道我可以使用'RectangleGeometry'类型的方法,但我对上面提到的代码方面的解决方案更感兴趣.
LPL*_*LPL 10
<Rectangle Width="100" Height="100"
Clip="{Binding ElementName=ClipRect, Path=RenderedGeometry}" />
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
7115 次 |
| 最近记录: |