From: cilix42 Date: Sun, 25 May 2008 14:06:41 +0000 (+0000) Subject: Fix some compile warnings X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=6abea082648dbf7f285cf3d09c45af46df97c729;p=inkscape.git Fix some compile warnings --- diff --git a/src/live_effects/lpe-patternalongpath.cpp b/src/live_effects/lpe-patternalongpath.cpp index 9ab085d54..85de609fb 100644 --- a/src/live_effects/lpe-patternalongpath.cpp +++ b/src/live_effects/lpe-patternalongpath.cpp @@ -144,7 +144,7 @@ LPEPatternAlongPath::doEffect_pwd2 (Geom::Piecewise > con double scaling = 1; switch(type) { case PAPCT_REPEATED: - nbCopies = floor((uskeleton.domain().extent() - toffset + xspace)/(pattBndsX.extent()+xspace)); + nbCopies = static_cast(floor((uskeleton.domain().extent() - toffset + xspace)/(pattBndsX.extent()+xspace))); pattBndsX = Interval(pattBndsX.min(),pattBndsX.max()+xspace); break; @@ -160,12 +160,12 @@ LPEPatternAlongPath::doEffect_pwd2 (Geom::Piecewise > con case PAPCT_REPEATED_STRETCHED: // if uskeleton is closed: if(path_i.segs.front().at0() == path_i.segs.back().at1()){ - nbCopies = std::floor((uskeleton.domain().extent() - toffset)/(pattBndsX.extent()+xspace)); + nbCopies = static_cast(std::floor((uskeleton.domain().extent() - toffset)/(pattBndsX.extent()+xspace))); pattBndsX = Interval(pattBndsX.min(),pattBndsX.max()+xspace); scaling = (uskeleton.domain().extent() - toffset)/(((double)nbCopies)*pattBndsX.extent()); // if not closed: no space at the end }else{ - nbCopies = std::floor((uskeleton.domain().extent() - toffset + xspace)/(pattBndsX.extent()+xspace)); + nbCopies = static_cast(std::floor((uskeleton.domain().extent() - toffset + xspace)/(pattBndsX.extent()+xspace))); pattBndsX = Interval(pattBndsX.min(),pattBndsX.max()+xspace); scaling = (uskeleton.domain().extent() - toffset)/(((double)nbCopies)*pattBndsX.extent() - xspace); }