This is a migrated thread and some comments may be shown as answers.

Tooltip goes offscreen when window resizes

1 Answer 303 Views
ToolTip
This is a migrated thread and some comments may be shown as answers.
Michael
Top achievements
Rank 1
Michael asked on 05 Dec 2012, 02:58 PM
I have a RadTooltip that is placed inside of a RadGrid's header that is being displayed inside of a RadWindowManager.  When the RadWindow gets resized to a smaller area, the grid and it's columns resize appropriately however the expanded tooltip's position stays the same; which causes it to be hidden outside the bounds of the RadWindow because the RadWindow's dimensions are smaller.  I have the tooltip configured to be placed relative to the element that makes it display but it doesn't seem to stay relative to that element in the case of the radwindow shrinking in size.  It looks to be absolutely positioned once popped out.

Is there a solution to this issue?

1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 07 Dec 2012, 01:12 PM
Hi Michael,

The RadToolTip is actually positioned absolutely. You can confirm this by inspecting its popup with your developer tools of choice. This means that resizing the browser would, generally, not affect its position even though it can affect elements with static position.

What you can do is to call the updateLocation() method of the currently active tooltip when the window resize is done. How to get a reference to the currently shown tooltip is shown here (see the getCurrent static method) and this SO thread may be useful on handing the window.resize event.

I also advise that you examine the Common Issues help article and make sure your tooltips cover the guidelines there - they have Width, Height, RelativeTo set. I also advise that you set their RenderInPageRoot property to true.

I am attaching here a simple page that shows this in action together with a video that shows the behavior.

Regards,
Marin Bratanov
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
ToolTip
Asked by
Michael
Top achievements
Rank 1
Answers by
Marin Bratanov
Telerik team
Share this question
or