]> granicus.if.org Git - graphviz/commitdiff
Visio plugin: squash some MSVC warnings from initializing floats with doubles
authorMatthew Fernandez <matthew.fernandez@gmail.com>
Sat, 9 Apr 2022 19:41:18 +0000 (12:41 -0700)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Tue, 12 Apr 2022 14:40:31 +0000 (07:40 -0700)
plugin/visio/VisioGraphic.cpp
plugin/visio/VisioRender.cpp
plugin/visio/VisioText.cpp

index 9f061ea878c8393efbae96a05e0e1c9b546c6ee1..06e2137a222865665e9fa295bd0c0e0cec6d28ea 100644 (file)
@@ -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),
index 2490958c640e05a9bcf6d5aa39d5c48908976fe9..a339c6be920c81663c3f55f77980ce6dcf2983ac 100644 (file)
@@ -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
        {
index 5bf1a88a0cd48bafacfba0f4d73dd4f93a961e4c..f6ebaf928870f76d96f48ec4d9e0e6d4566d1807 100644 (file)
@@ -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),