Tooltip container

Share RGraph:   To help my Google visibility (it can't get much worse!), if you like and use RGraph I'd appreciate it if you could link to me

« Back to message list

Enter your email address to get email updates on this topic. You can stop receiving updates by clicking the link in the update email messages.

Posted by Ben on 28th February 2014
I have a pie chart inside a modal dialog. The modal is scrollable leaving the page background fixed. When scrolling the modal the tooltips stay fixed in position and don't move with the modal. Is there anyway to have the tooltips render in a different container other than the document body.
Posted by Richard on 28th February 2014
Hi there,

They're fixed so that when you show a canvas and it is or one of its parents is fixed the likelihood is that the tooltip is needed to be fixed.

In your case though it sounds like a mix between fixed and not-fixed positioning. You could use the ontooltip function to adjust the position. For a fixed container thats scrollable it might get a trifle involved when it comes to working out the coodinates.

myChart.ontooltip = function (obj)
{
     // Reposition the tooltip here
}






Richard, RGraph Support
www.rgraph.net
If RGraph has helped you - please share the website - thanks!
Posted by Richard on 28th February 2014
Hi there,

Also - the option toolstips.coords.page may help:

obj.Set('toolips.coords.page', true);





Richard, RGraph Support
www.rgraph.net
If RGraph has helped you - please share the website - thanks!
Posted by Ben on 28th February 2014
I need them to be fixed with in a scrollable DIV and get their positioning from that container, not the body of the page. Is that possible?
Posted by Richard on 28th February 2014
Hi there,

Probably - but you'll need to code it in the ontooltip event like I suggested



Richard, RGraph Support
www.rgraph.net
If RGraph has helped you - please share the website - thanks!

Add a reply




« Back to message list