Page 1 of 1

ToolTip

Posted: Thu Dec 17, 2020 12:43 pm
by 17789313
Hi,

Is there a way of making the tooltip popup for only one series?

Thanks

Re: ToolTip

Posted: Mon Dec 21, 2020 10:50 am
by yeray
Hello,

You could modify the ToolTip refresh function as follows:

Code: Select all

      for (i = 0; i < 3; i++) {
        Chart1.addSeries(s = new Tee.Line().addRandom(15));
      }

      var tooltip = new Tee.ToolTip(Chart1);
      Chart1.tools.add(tooltip);
      
      tooltip.old_refresh=tooltip.refresh;
      
      tooltip.refresh = function(series,index) {
        if (series == Chart1.series.items[1]) {  // this will only show the tooltip for the series index 1
          tooltip.old_refresh(series,index);
        }
      }

Re: ToolTip

Posted: Tue Dec 22, 2020 8:50 am
by 17789313
Thanks, that works perfectly.