WPF,这个图形该怎么画?
两个问题:
1:下面这段代码,为什么看不到直线?
<Grid HorizontalAlignment="Left" Height="557" VerticalAlignment="Top" Width="907">
<Viewbox Margin="203,78,504,321">
<Grid>
<Path Data="M326,105 L326,199" Fill="#FFF4F4F5" />
</Grid>
</Viewbox>
</Grid>
2:下面的代码,用微语言如何在Grid的上边缘的1/3处到下边缘的1/3处画一条垂直的直线呢?(可以修改下面的代码)
<Viewbox Margin="203,78,504,321">
<Grid>
<Path Data=....... />
</Grid>
</Viewbox>
------解决方案-------------------- <Path Data="M11,10 L326,199" Fill="#FFF4F4F5" StrokeThickness="2" Stroke="Red" />
------解决方案--------------------直线直接用 <Canvas Height="2" Background="AliceBlue"></Canvas>