From ea86bc4d01851dab34b6ec0e1015a224cecc0fd5 Mon Sep 17 00:00:00 2001 From: Marcus Comstedt Date: Sun, 6 Apr 2014 17:04:42 +0200 Subject: [PATCH] Fix polymorphic function lookup problem Instead of taking min() of a qreal and a double, use two doubles. (The result is assigned to a double anyway.) Fixes build problem on Android --- pv/view/decodetrace.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pv/view/decodetrace.cpp b/pv/view/decodetrace.cpp index c3bc1dff..618de9a3 100644 --- a/pv/view/decodetrace.cpp +++ b/pv/view/decodetrace.cpp @@ -373,7 +373,7 @@ void DecodeTrace::draw_instant(const pv::data::decode::Annotation &a, QPainter & { const QString text = a.annotations().empty() ? QString() : a.annotations().back(); - const double w = min(p.boundingRect(QRectF(), 0, text).width(), + const double w = min((double)p.boundingRect(QRectF(), 0, text).width(), 0.0) + h; const QRectF rect(x - w / 2, y - h / 2, w, h); -- 2.30.2