Fix tooltip positioning with regards to viewports

The getPosition function was simplified with a new function,
getViewportBounds, was added to specifically
tackle the cases where we’re looking for the viewport bounds.

‘absolute’ and ‘fixed’ tooltips are now matched against the screen
where other ones are made to fit inside the viewport element.
@cvrebert @hnrch02 thanks for your feedback guys, I really didn't like calling it twice, but coming from C++ I was hoping the call could get cached / optimized away?  I guess it's not the case in JS?