Don't display event duration when zero on flow graph

This commit is contained in:
Guy Scharf 2020-05-26 10:07:59 -07:00
parent 4fa353a263
commit 66523e15f4

View File

@ -223,7 +223,10 @@ void gLineOverlayBar::paint(QPainter &painter, gGraph &w, const QRegion &region)
painter.drawRect(rect);
// Queue tooltip
QString lab2 = QString("%1 (%2)").arg(schema::channel[m_code].fullname()).arg(raw);
QString lab2 = QString("%1").arg(schema::channel[m_code].fullname());
if (raw != 0) // Hide duration when it is zero
lab2 += QString(" (%1)").arg(raw);
w.ToolTip(lab2, x1 - 10, start_py + 24 + (3 * w.printScaleY()), TT_AlignRight, AppSetting->tooltipTimeout());
painter.setPen(QPen(col,3));