emilk / emilk/egui_plot

How to define a custom on_hover behavior for a BarChart - is it really needed to re-implement all of PlotItem?

Open
#106 4 comments 0 reactions 0 assignees View on GitHub
Dominant language
Rust
Stars
468
Forks
108
Avg merge
15m
Merged PRs (30d)
3

Description

Currently it only seems possible to provide a custom String to content_formatter to change
what is written when hovering over a bar. But depending on the graph this is often not very well readable.

I'd much rather display a small Box similar to the legend to give more info about the current Bar in the BarChart.

I'm kind of pulling my hair out on this one and have not found a proper solution.

EDIT: A special problem seems to be that I cannot even re-implement PlotItem because for base and mut_base methods to be implemented, I need to use the Type PlotItemBase whcih is inaccesible as the items module is private. I am really stuck here :(
And that is even more frustrating because they are just returning the same as the original implementation anyway. I don't want to do anything special there...

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.