开发者

Raphael Rectangle Tooltip

I am drawing series of rectangle using the following code in a loop

paper.rect(((x) * cellSize), ((y) * cellSize), cellSize, cellSiz开发者_如何学Ce).attr({ fill: rgbx, stroke: rgbx });

Is there a way show tooltip on those rectangle? Is there a library that can show ballon tooltip (fadding)

I found similar question but not sure it can be done?


Here's a simple Raphael plugin for tooltips: http://www.strathausen.eu/en/2010/04/25/raphael-svg-tooltip/

Although it mentiones SVG explicitly, it should work just fine on IE (VML backend) as well.


Try the title attribute.

element.attr({title: 'The tooltip to be displayed on mouse hover'});

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜