From: Krzysztof KosiƄski Date: Sat, 3 Apr 2010 22:19:13 +0000 (+0200) Subject: Fix --export-page-drawing option in PDF, PS and LaTeX export. X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=1969fd5cf6b74455ebddfc4c515e1d294eaecec8;p=inkscape.git Fix --export-page-drawing option in PDF, PS and LaTeX export. --- diff --git a/src/extension/internal/cairo-renderer.cpp b/src/extension/internal/cairo-renderer.cpp index 6e4bb3b7e..52f070591 100644 --- a/src/extension/internal/cairo-renderer.cpp +++ b/src/extension/internal/cairo-renderer.cpp @@ -631,12 +631,8 @@ CairoRenderer::setupDocument(CairoRenderContext *ctx, SPDocument *doc, bool page if (ret && !pageBoundingBox) { - double high = sp_document_height(doc); - if (ctx->_vector_based_target) - high *= PT_PER_PX; - Geom::Matrix tp(Geom::Translate(-d.x0 * (ctx->_vector_based_target ? PX_PER_PT : 1.0), - (d.y1 - high) * (ctx->_vector_based_target ? PX_PER_PT : 1.0))); + -d.y0 * (ctx->_vector_based_target ? PX_PER_PT : 1.0))); ctx->transform(&tp); } diff --git a/src/extension/internal/latex-text-renderer.cpp b/src/extension/internal/latex-text-renderer.cpp index 28bba1beb..1fdf1d7fd 100644 --- a/src/extension/internal/latex-text-renderer.cpp +++ b/src/extension/internal/latex-text-renderer.cpp @@ -501,7 +501,8 @@ LaTeXTextRenderer::setupDocument(SPDocument *doc, bool pageBoundingBox, SPItem * if (!pageBoundingBox) { - push_transform( Geom::Translate( - d->min() ) ); + Geom::Translate t(-d->min()[Geom::X], d->max()[Geom::Y] - sp_document_height(doc)); + push_transform( t ); } // flip y-axis