From: Matthew Fernandez Date: Sat, 9 Apr 2022 19:41:18 +0000 (-0700) Subject: Visio plugin: squash some MSVC warnings from initializing floats with doubles X-Git-Tag: 4.0.0~111^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a9ab5f2c6fdb90d8f79ae4d98c7e6c0f9147d3a7;p=graphviz Visio plugin: squash some MSVC warnings from initializing floats with doubles --- diff --git a/plugin/visio/VisioGraphic.cpp b/plugin/visio/VisioGraphic.cpp index 9f061ea87..06e2137a2 100644 --- a/plugin/visio/VisioGraphic.cpp +++ b/plugin/visio/VisioGraphic.cpp @@ -37,7 +37,7 @@ namespace Visio { using namespace std; - static const float INCHES_PER_POINT = 1.0 / 72.0; + static const float INCHES_PER_POINT = 1.0f / 72.0f; Fill::Fill(unsigned char red, unsigned char green, unsigned char blue, double transparency): _red(red), diff --git a/plugin/visio/VisioRender.cpp b/plugin/visio/VisioRender.cpp index 2490958c6..a339c6be9 100644 --- a/plugin/visio/VisioRender.cpp +++ b/plugin/visio/VisioRender.cpp @@ -38,8 +38,8 @@ namespace Visio { using namespace std; - static const float INCHES_PER_POINT = 1.0 / 72.0; - static const float ZERO_ADJUST = 0.125; + static const float INCHES_PER_POINT = 1.0f / 72.0f; + static const float ZERO_ADJUST = 0.125f; enum ConLineRouteExt { diff --git a/plugin/visio/VisioText.cpp b/plugin/visio/VisioText.cpp index 5bf1a88a0..f6ebaf928 100644 --- a/plugin/visio/VisioText.cpp +++ b/plugin/visio/VisioText.cpp @@ -21,7 +21,7 @@ namespace Visio { - static const float INCHES_PER_POINT = 1.0 / 72.0; + static const float INCHES_PER_POINT = 1.0f / 72.0f; Char::Char(double size, unsigned char red, unsigned char green, unsigned char blue): _size(size),