☰Read-only archive⌕
Looking for help with Bokeh?

This is a read-only archive. Ask questions and join the conversation on GitHub.

Visit Community Support on GitHub →
Archived discussions · Captured October 28, 2026

Legend click modifier: hide all others

Community Supportserver
fleimgruber
fleimgruber

Given e.g. 10 lines with legends, all visible initially and p.legend.click_policy = "hide" to see only one line at a time the user has to hide all others by clicking on them separately one after the other. Is there a way to “Show only this line” when clicking on a line in the legend, e.g. by having a modifier key Shift or Ctrl held down while clicking?

I got used to this feature from Grafana, although there the behaviour is the inverse, i.e. click shows only one line and modifier+click shows/hides single line.

Related to this topic, but with clicking instead of hovering.

⌁   Link to post

End of archived discussion · Replies are disabled