From d433c8e7c5ec19f123fc6ca8cbb6114b6c1bd0d7 Mon Sep 17 00:00:00 2001 From: Sebastian Kuzminsky Date: Tue, 18 Jun 2024 13:58:45 -0600 Subject: [PATCH] signal makePrettyOutput: add a space between value and unit Instead of rendering as "45Celsius" it now renders as "45 Celsius". --- dbc/dbc_classes.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dbc/dbc_classes.cpp b/dbc/dbc_classes.cpp index da44f804..9ea594a9 100644 --- a/dbc/dbc_classes.cpp +++ b/dbc/dbc_classes.cpp @@ -214,12 +214,12 @@ QString DBC_SIGNAL::makePrettyOutput(double floatVal, int64_t intVal, bool outpu } } if (!foundVal) outputString += QString::number(intVal); - if (outputUnit) outputString += unitName; + if (outputUnit) outputString += " " + unitName; } else //otherwise display the actual number and unit (if it exists) { outputString += (isInteger ? QString::number(intVal) : QString::number(floatVal)); - if (outputUnit) outputString += unitName; + if (outputUnit) outputString += " " + unitName; } return outputString; }