Tooltips detect edge of chart and flip accordingly.