From 346c58863ab3c563ebe8470a93e4a0ffbc251f95 Mon Sep 17 00:00:00 2001 From: Alvin Penner Date: Mon, 3 Nov 2014 13:42:13 -0500 Subject: update svg-length-test.h from 90 to 96 dpi (bzr r13664) --- src/selection-chemistry.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/selection-chemistry.cpp') diff --git a/src/selection-chemistry.cpp b/src/selection-chemistry.cpp index 6a091bd12..abc3b990c 100644 --- a/src/selection-chemistry.cpp +++ b/src/selection-chemistry.cpp @@ -3661,7 +3661,7 @@ void sp_selection_create_bitmap_copy(SPDesktop *desktop) if (hint_xdpi != 0) { res = hint_xdpi; } else { - // if all else fails, take the default 90 dpi + // if all else fails, take the default 96 dpi res = Inkscape::Util::Quantity::convert(1, "in", "px"); } } @@ -3709,7 +3709,7 @@ void sp_selection_create_bitmap_copy(SPDesktop *desktop) double shift_x = bbox->min()[Geom::X]; double shift_y = bbox->max()[Geom::Y]; - if (res == Inkscape::Util::Quantity::convert(1, "in", "px")) { // for default 90 dpi, snap it to pixel grid + if (res == Inkscape::Util::Quantity::convert(1, "in", "px")) { // for default 96 dpi, snap it to pixel grid shift_x = round(shift_x); shift_y = -round(-shift_y); // this gets correct rounding despite coordinate inversion, remove the negations when the inversion is gone } @@ -3744,7 +3744,7 @@ void sp_selection_create_bitmap_copy(SPDesktop *desktop) // TODO: avoid unnecessary roundtrip between data URI and decoded pixbuf Inkscape::XML::Node * repr = xml_doc->createElement("svg:image"); sp_embed_image(repr, pb); - if (res == Inkscape::Util::Quantity::convert(1, "in", "px")) { // for default 90 dpi, snap it to pixel grid + if (res == Inkscape::Util::Quantity::convert(1, "in", "px")) { // for default 96 dpi, snap it to pixel grid sp_repr_set_svg_double(repr, "width", width); sp_repr_set_svg_double(repr, "height", height); } else { -- cgit v1.2.3