summaryrefslogtreecommitdiff
path: root/basegfx
diff options
context:
space:
mode:
authorArmin Le Grand <Armin.Le.Grand@cib.de>2018-08-30 23:41:36 +0200
committerArmin Le Grand <Armin.Le.Grand@cib.de>2018-08-31 19:28:29 +0200
commitb5f081e1ac14f60497f62a27be86b07b0baa42f7 (patch)
tree86dfda11c47f96d9c640b76dd01c13a7897b2c0c /basegfx
parentcecf71c18da5430c10daa8522d38d5144edefc14 (diff)
Support RTL layout in VCL using Matrices
Did some changes inspired by Noel, corrected the transformation due to mirroring already applied, re-added 'mirror this window back'-mode Change-Id: I21999e59898cf672fd293bc2b11f5d568e6673be Reviewed-on: https://gerrit.libreoffice.org/59842 Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk> Tested-by: Jenkins Reviewed-by: Armin Le Grand <Armin.Le.Grand@cib.de>
Diffstat (limited to 'basegfx')
-rw-r--r--basegfx/source/matrix/b2dhommatrix.cxx14
1 files changed, 13 insertions, 1 deletions
diff --git a/basegfx/source/matrix/b2dhommatrix.cxx b/basegfx/source/matrix/b2dhommatrix.cxx
index 1e991304a4f0..61178c496011 100644
--- a/basegfx/source/matrix/b2dhommatrix.cxx
+++ b/basegfx/source/matrix/b2dhommatrix.cxx
@@ -148,8 +148,20 @@ namespace basegfx
B2DHomMatrix& B2DHomMatrix::operator*=(const B2DHomMatrix& rMat)
{
- if(!rMat.isIdentity())
+ if(rMat.isIdentity())
+ {
+ // multiply with identity, no change -> nothing to do
+ }
+ else if(isIdentity())
+ {
+ // we are identity, result will be rMat -> assign
+ *this = rMat;
+ }
+ else
+ {
+ // multiply
mpImpl->doMulMatrix(*rMat.mpImpl);
+ }
return *this;
}