【发布时间】:2016-05-03 09:47:11
【问题描述】:
我有一个带有细线作为标记的图表,用户可以将鼠标悬停在上面以获取它们的值。
我想让工具提示激活的区域更大,但保持实际线的大小相同,因为用户实际将鼠标悬停在上面是相当困难的。
我还有一条用户可以拖动的线,很难找到精确的点来点击和拖动。
这是我的标记模板,但我不知道如何实现这个目标,谁能指出我正确的方向?
<Geometry x:Key="LineGeometry">M 0,0 L 5,0 L 5,15 L 0,15 Z</Geometry>
<DataTemplate>
<!-- Define the template for the actual markers -->
<Path Width="10"
Height="10"
HorizontalAlignment="Stretch"
VerticalAlignment="Stretch"
Data="{StaticResource LineGeometry}"
Stretch="Fill"
Stroke="{StaticResource BlackBrush}"
StrokeThickness="0.5">
<Path.ToolTip>
<!-- Lots of tooltip definition stuff -->
</Path.ToolTip>
</Path>
</DataTemplate>
- Visual Studio 2015
- WPF
- C#
- 基础设施 XamDataChart
【问题讨论】:
标签: c# wpf tooltip infragistics xamdatachart