Supporting tooltips on Area glyphs #11979
Replies: 1 comment 1 reply
-
@xaptronic I am not sure this is advised? (or maybe I am misunderstanding somethign) For tooltips we would definitely want to pop up a hover any time the mouse is inside the (one, single) polygon that defines the |
Beta Was this translation helpful? Give feedback.
-
cc: @bokeh/dev
Hello! I've gone through the hit-testing / index selection code related to Areas / Glyphs and come up with a way to get this to work.
The core of the change is that, instead of doing hit testing on the entire area glyph polygon, I changed the implementation to iterate throug each segment of the Polygon (essentially "sub-polygons") and then if hit test passes, mark the index for use by the
_update
method inhover_tooltip.ts
.I have posted a proof-of-concept of this with working examples on my bokeh fork, and would welcome some feedback in terms of direction of this change.
The VAreaView handling code in
hover_tooltip.ts
is especially proof-of-concept - really just some hacking to get it work.Thanks!
Beta Was this translation helpful? Give feedback.
All reactions