On Dec 7, 2014, at 12:16 AM, Sean Truong <[email protected]> wrote:
Thanks for the quick fix! Unfortunately I use the 'components' functionality to embed the div/script onto my pages, and point to the bokeh-0.7.0.min.js via CDN from pydata.org, so I can't recompile the updated *.coffee files. Or if I can get a diff of the bokeh.js before/after the change, I can then use the bokeh.js on my server. Otherwise I'll wait for the next release with the fix.
On Saturday, December 6, 2014 9:10:30 PM UTC-8, Bryan Van de ven wrote:
Sean, you are correct that one possibility is to add multiple hover tools. However, the exiting behavior should not have broken. I have determined a short term fix that restores the previous behavior, and pushed a PR:
You can expect this to be part of a dev build release out in the next week or so (or it will be available in master in a day or two, if you care to build Bokeh yourself).
A few notes: this solves the problem by creating a separate tooltip for every renderer the HoverTool is configured with. This means that if there are lots of renderers, and the mouse happens to hit elements of many of them at once, you will get many tooltips (one for each renderer). But if this was not a problem for you before, then it will probably not be one now, either.
The long term solution will involve adding some sort of plot-global "tooltip manager" that can limit the number of tooltips and also handle dodging them visually. That will come in a later release.
> On Dec 6, 2014, at 10:23 PM, Sean Truong <[email protected]> wrote:
> Ok based on the thread "different hover tooltips for different glyphs"
> and also from this example: https://github.com/bokeh/bokeh/blob/f76ccc44fb39007743ffbe71659b282759915653/examples/glyphs/data_tables.py
> It looks like I now have to define a separate HoverTool object for each glyph then add it to the plot.tools.
> On Saturday, December 6, 2014 7:53:32 PM UTC-8, Sean Truong wrote:
> I recently upgraded from 0.6.1 to 0.7.0 and it seems the behavior of HoverTool has change. My graph has multiple lines/glyphs and all it took was one call to setup HoverTool so that mousing over any data point would display the tooltip (primarily needed to get the @x and @y values). Now after upgrading to 0.7.0, the HoverTool tooltip only displays data for the last data set in my for loop. I've tried moving to the code that sets up hover inside my for loop, but it still didn't work.
> PSEUDO Code working in 0.6.1:
> # Draw a curve for each dataset
> for k in datasets:
> source = ColumnDataSource(
> data = dict(
> // set up data for this k
> bk.line( ... )
> bk.square( ... )
> # Set up hovertool
> hover = bk.curplot().select(dict(type=HoverTool))
> hover.tooltips = OrderedDict([
> ( ... ),
> Any help or explanation in the change of behavior is appreciated.
> You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/d9ec0593-5067-428b-9d76-98f7bd6eb541%40continuum.io.
> For more options, visit https://groups.google.com/a/continuum.io/d/optout.
You received this message because you are subscribed to the Google Groups "Bokeh Discussion - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/bokeh/a9f38ba4-2a01-47e1-820c-de84e7e84871%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.