From 65660350dd868d2d67bbf0146c6f8254634d4361 Mon Sep 17 00:00:00 2001 From: Dean Lee Date: Sun, 28 Apr 2024 07:31:48 +0800 Subject: [PATCH] cabana: show enum string in chart tooltip (#32303) old-commit-hash: 37877185f812321ecf3c8b5e787838d9b9204b75 --- tools/cabana/chart/chart.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/cabana/chart/chart.cc b/tools/cabana/chart/chart.cc index dd34782e33..ce52825ac5 100644 --- a/tools/cabana/chart/chart.cc +++ b/tools/cabana/chart/chart.cc @@ -581,7 +581,7 @@ void ChartView::showTip(double sec) { // use reverse iterator to find last item <= sec. auto it = std::lower_bound(s.vals.crbegin(), s.vals.crend(), sec, [](auto &p, double x) { return p.x() > x; }); if (it != s.vals.crend() && it->x() >= axis_x->min()) { - value = QString::number(it->y()); + value = s.sig->formatValue(it->y(), false); s.track_pt = *it; x = std::max(x, chart()->mapToPosition(*it).x()); }