fix position on the right side of a scaled SVG path

Currently, if tooltip is positioned on the left side of a scaled SVG path it is okay, but on the right side it isn't because it doesn't scale width or height.