summaryrefslogtreecommitdiffstats
path: root/src/ui/dialog/export.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2017-01-24 18:11:26 +0000
committerjabiertxof <info@marker.es>2017-01-24 18:11:26 +0000
commit176b68d76f6b684b4bf0797e1d132e8377bddab0 (patch)
treeb1918157cb8d5ada5bb76a0fd98b2433d2dd476d /src/ui/dialog/export.cpp
parentFix a translation bug in rotate copies LPE (diff)
parentPut namespace as constant (diff)
downloadinkscape-176b68d76f6b684b4bf0797e1d132e8377bddab0.tar.gz
inkscape-176b68d76f6b684b4bf0797e1d132e8377bddab0.zip
merge lp:~inkscape.dev/inkscape/doc_rotate
(bzr r15444)
Diffstat (limited to 'src/ui/dialog/export.cpp')
-rw-r--r--src/ui/dialog/export.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/ui/dialog/export.cpp b/src/ui/dialog/export.cpp
index 1bb952de4..b7207fd50 100644
--- a/src/ui/dialog/export.cpp
+++ b/src/ui/dialog/export.cpp
@@ -978,7 +978,9 @@ void Export::onExport ()
SPNamedView *nv = desktop->getNamedView();
SPDocument *doc = desktop->getDocument();
-
+ Geom::Affine rot = doc->getRoot()->c2p;
+ doc->getRoot()->c2p = doc->getRoot()->rotation.inverse() * doc->getRoot()->c2p;
+ doc->ensureUpToDate();
bool exportSuccessful = false;
bool hide = hide_export.get_active ();
@@ -1003,6 +1005,7 @@ void Export::onExport ()
if (num < 1) {
desktop->messageStack()->flash(Inkscape::ERROR_MESSAGE, _("No items selected."));
+ doc->getRoot()->c2p *= doc->getRoot()->rotation;
return;
}
@@ -1094,6 +1097,7 @@ void Export::onExport ()
if (filename.empty()) {
desktop->messageStack()->flash(Inkscape::ERROR_MESSAGE, _("You have to enter a filename."));
sp_ui_error_dialog(_("You have to enter a filename"));
+ doc->getRoot()->c2p *= doc->getRoot()->rotation;
return;
}
@@ -1110,6 +1114,7 @@ void Export::onExport ()
if (!((x1 > x0) && (y1 > y0) && (width > 0) && (height > 0))) {
desktop->messageStack()->flash(Inkscape::ERROR_MESSAGE, _("The chosen area to be exported is invalid."));
sp_ui_error_dialog(_("The chosen area to be exported is invalid"));
+ doc->getRoot()->c2p *= doc->getRoot()->rotation;
return;
}
@@ -1132,6 +1137,7 @@ void Export::onExport ()
g_free(safeDir);
g_free(error);
+ doc->getRoot()->c2p *= doc->getRoot()->rotation;
return;
}
@@ -1281,6 +1287,7 @@ void Export::onExport ()
}
}
}
+ doc->getRoot()->c2p *= doc->getRoot()->rotation;
} // end of sp_export_export_clicked()
/// Called when Browse button is clicked