Add new arguments and better heuristics to $.fn.positionToSide.

positionToSide had trouble matching an element when positioned, say, to
either above/below another element, when the left or right of the
element would be scrolled off-screen. The "best guess" logic failed,
since it took into account both positions. Now it only computes the
position for the side it's checking, and leaves computing the other axis
until after it finds the best side.

There's some new options for controlling positioning as well. Instead of
just 'distance', there's now 'xDistance' and 'yDistance'. These both
fall back to using 'distance' if not specified.

'xOffset' and 'yOffset' control offseting the element in the direction
not matched up to a side. That's useful when you want to push the
element by a few pixels in one direction relative to the side.

Last, but not least, fitOnScreen now anchors things going off the top or
left of the scroll position as well, instead of just the bottom or
right.