From 95a0c8412e84f5e0cc1d9a63fce2be75f9fa517e Mon Sep 17 00:00:00 2001 From: Krzysztof Kosi??ski Date: Tue, 6 Apr 2010 16:11:54 +0200 Subject: Revert the inverted coordinate system fix. 3D Boxes and guides require an XML-level backwards compatibility mechanism to fix properly, and it's too late in the 0.48 cycle to introduce it. (bzr r9298) --- src/sp-item.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/sp-item.cpp') diff --git a/src/sp-item.cpp b/src/sp-item.cpp index f60a2b27a..c4411e47d 100644 --- a/src/sp-item.cpp +++ b/src/sp-item.cpp @@ -1574,7 +1574,8 @@ Geom::Matrix sp_item_i2d_affine(SPItem const *item) g_assert(SP_IS_ITEM(item)); Geom::Matrix const ret( sp_item_i2doc_affine(item) - ); + * Geom::Scale(1, -1) + * Geom::Translate(0, sp_document_height(SP_OBJECT_DOCUMENT(item))) ); return ret; } @@ -1587,7 +1588,8 @@ void sp_item_set_i2d_affine(SPItem *item, Geom::Matrix const &i2dt) if (SP_OBJECT_PARENT(item)) { dt2p = sp_item_i2d_affine((SPItem *) SP_OBJECT_PARENT(item)).inverse(); } else { - dt2p = ( Geom::identity() ); + dt2p = ( Geom::Translate(0, -sp_document_height(SP_OBJECT_DOCUMENT(item))) + * Geom::Scale(1, -1) ); } Geom::Matrix const i2p( i2dt * dt2p ); -- cgit v1.2.3