【发布时间】:2015-07-27 07:40:30
【问题描述】:
亲爱的朋友们! 我的资源字典中有无缝矢量图像作为画布
<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Canvas x:Key="SeamlessBackground"
...
</Canvas>
我想用它作为我的 MainWindow 背景。我使用了 VisualBrash:
<Window.Background>
<VisualBrush Stretch="None" Visual="{StaticResource SeamlessBackground}" TileMode="Tile" >
<VisualBrush.Transform>
<TransformGroup>
<ScaleTransform ScaleX="0.2" ScaleY="0.2"/>
<SkewTransform/>
<RotateTransform/>
<TranslateTransform/>
</TransformGroup>
</VisualBrush.Transform>
</VisualBrush>
</Window.Background>
但我得到的不是大的无缝背景,而是几个分离的图像,它们之间有巨大的接缝。当我伸展我的身体时,这些接缝就是增长。我预计当我拉伸表格时,新图像会被淹没以填补这些接缝。 请帮忙)))
【问题讨论】:
标签: wpf vector background tile