summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKrzysztof Kosi??ski <tweenk.pl@gmail.com>2015-05-08 15:37:07 +0000
committerKrzysztof KosiƄski <tweenk.pl@gmail.com>2015-05-08 15:37:07 +0000
commit9d9699dd9cc0e86ac34a97f051ddf975bd004b8e (patch)
tree1da1538a5e0b22640d0733ee578e0fcd14ac3ba3
parentAdjust CMakeLists for 2geom directory (diff)
downloadinkscape-9d9699dd9cc0e86ac34a97f051ddf975bd004b8e.tar.gz
inkscape-9d9699dd9cc0e86ac34a97f051ddf975bd004b8e.zip
Remove round_rectangle_outwards from helper/geom.h
(bzr r14059.2.9)
-rw-r--r--src/helper/geom.cpp12
-rw-r--r--src/helper/geom.h2
-rw-r--r--src/main.cpp2
3 files changed, 1 insertions, 15 deletions
diff --git a/src/helper/geom.cpp b/src/helper/geom.cpp
index daaf90ff2..0e97265d1 100644
--- a/src/helper/geom.cpp
+++ b/src/helper/geom.cpp
@@ -856,18 +856,6 @@ recursive_bezier4(const double x1, const double y1,
}
-/**
- * rounds all corners of the rectangle 'outwards', i.e. x0 and y0 are floored, x1 and y1 are ceiled.
- */
-void round_rectangle_outwards(Geom::Rect & rect) {
- Geom::Interval ints[2];
- for (int i=0; i < 2; i++) {
- ints[i] = Geom::Interval(std::floor(rect[i][0]), std::ceil(rect[i][1]));
- }
- rect = Geom::Rect(ints[0], ints[1]);
-}
-
-
namespace Geom {
bool transform_equalp(Geom::Affine const &m0, Geom::Affine const &m1, Geom::Coord const epsilon) {
diff --git a/src/helper/geom.h b/src/helper/geom.h
index 3232d9fd5..22d770040 100644
--- a/src/helper/geom.h
+++ b/src/helper/geom.h
@@ -33,8 +33,6 @@ void recursive_bezier4(const double x1, const double y1, const double x2, const
std::vector<Geom::Point> &pointlist,
int level);
-void round_rectangle_outwards(Geom::Rect & rect);
-
namespace Geom{
bool transform_equalp(Geom::Affine const &m0, Geom::Affine const &m1, Geom::Coord const epsilon);
bool translate_equalp(Geom::Affine const &m0, Geom::Affine const &m1, Geom::Coord const epsilon);
diff --git a/src/main.cpp b/src/main.cpp
index 415118407..f72b6d121 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1545,7 +1545,7 @@ static int sp_do_export_png(SPDocument *doc)
}
if (sp_export_area_snap) {
- round_rectangle_outwards(area);
+ area = area.roundOutwards();
}
// default dpi