The underlying technical work for a persistent tooltip has already been done, in this PR:
Which was added for 3.0 awhile back.
These Tooltip
objects can be attached to just about anything, but the specific use-case of adding them to plots is not yet very well demonstrated. Additionally there are probably some conveniences that are missing to make this specific use-case simpler. [1] The motivation at the time was for adding them to widgets, etc, so that is where the examples and docs were focused. Improving things for this use-case and adding examples/docs to support it would be a welcome contribution. I’d encourage starting a GitHub development discussion about this, so it’s easier to loop in relevant core devs.
cc @mateusz
-
Right now I think you’d have to manually compute a data-screen coordinate transform in a tap tool callback (or whatever) in order to add the tooltip relative to a data coordinate, and if your plot can be pan/zoomed, you’d probably need to manually update that screen position in a range callback. ↩︎