-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature Request] Ability to replace LineTouchTooltipData widget #1612
Comments
+1, also have a case where I'd like to use a |
+1 |
+1 |
I realize this might be a larger task since it looks like the library is rendering the tooltips with the Canvas API, which doesn't directly support rendering widgets (correct me if I am wrong), so this might require a larger refactor to move the tooltips to an OverlayEntry. |
Yes, exactly you're correct. |
Is your feature request relasted to a problem? Please describe.
SideTitles() allows the user to override the titles widget with practically anything they want, making the axis titles very flexible and extendable as needed, but I have some use cases where I would like to stylize the tooltip created by LineTouchTooltipData().
More specifically, I'd like to be able to stylize the container or even extend functionality of the tooltip widget. Currently I am working with some signal processing, and I'd like to be able to extend the tooltip to add left/right arrows to move a marker to the previous or next peaks in the signal, respectively. We draw the tooltips above the chart using the
showOnTopOfTheChartBoxArea
property ofLineTouchTooltipData
, but we would like to extend the functionality of the tooltips.Describe the solution you'd like
It would be fantastic if we could change the function getTooltipItems from
{List<LineTooltipItem?> Function(List<LineBarSpot>)}
to something like{Widget Function(LineBarSpot) getTitlesWidget = defaultGetTooltipItems}
.The text was updated successfully, but these errors were encountered: