From 97f3cbc18d6174227dfe2b749d9f04c0e63d3d72 Mon Sep 17 00:00:00 2001 From: Gaute Lindkvist Date: Mon, 12 Nov 2018 08:38:11 +0100 Subject: [PATCH] #3656 Improve display of Y-axis values. --- .../RivWindowEdgeAxesOverlayItem.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ApplicationCode/ModelVisualization/WindowEdgeAxesOverlayItem/RivWindowEdgeAxesOverlayItem.cpp b/ApplicationCode/ModelVisualization/WindowEdgeAxesOverlayItem/RivWindowEdgeAxesOverlayItem.cpp index f9072d55d2..687af70e58 100644 --- a/ApplicationCode/ModelVisualization/WindowEdgeAxesOverlayItem/RivWindowEdgeAxesOverlayItem.cpp +++ b/ApplicationCode/ModelVisualization/WindowEdgeAxesOverlayItem/RivWindowEdgeAxesOverlayItem.cpp @@ -311,7 +311,7 @@ void RivWindowEdgeAxesOverlayItem::addTextToTextDrawer(TextDrawer* textDrawer) double tickValue = m_domainCoordsXValues[i]; String valueString; - valueString = String::number(tickValue); + valueString = String::number(tickValue, 'f', 0); auto labelSize = m_font->textExtent(valueString); Vec2f pos(textX - labelSize.x()*0.5f, textYBott); @@ -335,7 +335,7 @@ void RivWindowEdgeAxesOverlayItem::addTextToTextDrawer(TextDrawer* textDrawer) double tickValue = m_isSwitchingYAxisValueSign ? -m_domainCoordsYValues[i]: m_domainCoordsYValues[i]; String valueString; - valueString = String::number(tickValue); + valueString = String::number(tickValue, 'f', 0); auto labelSize = m_font->textExtent(valueString); Vec2f pos(textXRight, textY);