summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-02-21 16:07:47 +0200
committerNoel Grandin <noel@peralex.com>2014-02-25 15:16:57 +0200
commitffdd5d304779e7ec7cdf7d4f5dbeb24584970c6b (patch)
treea604155c23874afd4400c1bc8cba40d80c4479db
parenta77461db606859f8b29b24990094deaceed07114 (diff)
remove unused code basegfx::snapToRange(double, double, double)
Change-Id: I72813be5f82b1a43fbb765d1b5f96f47b62920b8
-rw-r--r--basegfx/source/numeric/ftools.cxx25
-rw-r--r--include/basegfx/numeric/ftools.hxx4
-rw-r--r--unusedcode.easy1
3 files changed, 0 insertions, 30 deletions
diff --git a/basegfx/source/numeric/ftools.cxx b/basegfx/source/numeric/ftools.cxx
index 1cbbe5cc2136..a3a27a7a50c8 100644
--- a/basegfx/source/numeric/ftools.cxx
+++ b/basegfx/source/numeric/ftools.cxx
@@ -75,31 +75,6 @@ namespace basegfx
}
}
- double snapToRange(double v, double fLow, double fHigh)
- {
- if(fTools::equal(fLow, fHigh))
- {
- // with no range all snaps to range bound
- return 0.0;
- }
- else
- {
- if(fLow > fHigh)
- {
- // correct range order. Evtl. assert this (?)
- std::swap(fLow, fHigh);
- }
-
- if(v < fLow || v > fHigh)
- {
- return snapToZeroRange(v - fLow, fHigh - fLow) + fLow;
- }
- else
- {
- return v;
- }
- }
- }
} // end of namespace basegfx
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/include/basegfx/numeric/ftools.hxx b/include/basegfx/numeric/ftools.hxx
index 140731eee8dd..2e327df4587d 100644
--- a/include/basegfx/numeric/ftools.hxx
+++ b/include/basegfx/numeric/ftools.hxx
@@ -152,10 +152,6 @@ namespace basegfx
*/
double snapToZeroRange(double v, double fWidth);
- /** Snap v to the range [fLow .. fHigh] using modulo
- */
- double snapToRange(double v, double fLow, double fHigh);
-
/** return fValue with the sign of fSignCarrier, thus evtl. changed
*/
inline double copySign(double fValue, double fSignCarrier)
diff --git a/unusedcode.easy b/unusedcode.easy
index dd441f8d4de5..5de3a502dfd3 100644
--- a/unusedcode.easy
+++ b/unusedcode.easy
@@ -278,7 +278,6 @@ apitest::XTextContent::testAttach()
apitest::XTextContent::testGetAnchor()
apitest::XTextField::testGetPresentation()
basegfx::snapToNearestMultiple(double, double)
-basegfx::snapToRange(double, double, double)
basegfx::tools::containsOnlyHorizontalAndVerticalEdges(basegfx::B2DPolyPolygon const&)
basegfx::tools::equal(basegfx::B2DPolygon const&, basegfx::B2DPolygon const&, double const&)
basegfx::tools::equal(basegfx::B3DPolyPolygon const&, basegfx::B3DPolyPolygon const&)