-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Tooltip is clipped from other Usercontrols #229
Comments
#230 should fix this i think |
This answer is out of date, please if you are using 0.9.2 or greater see the next comment
<Canvas Name="CanvasContainer">
<!--
the tooltip requires a canvas to move properly,
so lets wrap our view where you need a shared tooltip
with a Canvas container
-->
<lvc:DefaultTooltip Name="CurrentTooltip" Visibility="Hidden"
Panel.ZIndex="100"
Canvas.Left="0" Canvas.Top="0"
IsWrapped="True">
<!--
it needs to:
1. Have an initial position
2. Be hidden on startup
3. to be wrapped in a Canvas, and say it with IsWrapped = true
-->
</lvc:DefaultTooltip>
<Grid Height="{Binding ActualHeight, ElementName=CanvasContainer}"
Width="{Binding ActualWidth, ElementName=CanvasContainer}">
<Grid.ColumnDefinitions>
<ColumnDefinition Width="*"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
<ColumnDefinition Width="*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<lvc:CartesianChart Grid.Column="0" Background="White"
DataTooltip="{Binding ElementName=CurrentTooltip}">
<lvc:CartesianChart.Series>
<lvc:LineSeries Values="1,2,3,4,5" LabelPoint="{Binding LabelPoint}"></lvc:LineSeries>
</lvc:CartesianChart.Series>
</lvc:CartesianChart>
<lvc:CartesianChart Grid.Column="1" Background="White"
DataTooltip="{Binding ElementName=CurrentTooltip}">
<lvc:CartesianChart.Series>
<lvc:LineSeries Values="1,2,3,4,5" LabelPoint="{Binding LabelPoint}"></lvc:LineSeries>
</lvc:CartesianChart.Series>
</lvc:CartesianChart>
<lvc:CartesianChart Grid.Column="2" Background="White"
DataTooltip="{Binding ElementName=CurrentTooltip}">
<lvc:CartesianChart.Series>
<lvc:LineSeries Values="1,2,3,4,5" LabelPoint="{Binding LabelPoint}" ></lvc:LineSeries>
</lvc:CartesianChart.Series>
</lvc:CartesianChart>
</Grid>
</Canvas>
|
From 0.9.2 and above this scenario is automatically handled with 8e31b12, there is no need to wrap the tooltip in a container as it was in the previous versions, if you already did this in your code, your wrapping will be ignored but you code should compile correctly, there is no need to change your code, but I recommend you to do so just because it is now cleaner and this step is not necessary |
Is it maybe possible to give the Tooltip an Zindex of 100 maybe?
So it wouldnt be clipped from other Usercontrols.
I cant find the right place in the code.
The text was updated successfully, but these errors were encountered: