diff options
| author | Krzysztof Kosi??ski <tweenk.pl@gmail.com> | 2015-07-04 15:25:59 +0000 |
|---|---|---|
| committer | Krzysztof KosiĆski <tweenk.pl@gmail.com> | 2015-07-04 15:25:59 +0000 |
| commit | 60437ac397d41678daba5daece227240e8ddd364 (patch) | |
| tree | 31f18c8296ffde9122492b46623375fc98585b17 /src/2geom/curve.h | |
| parent | 2Geom CMake adjustment (diff) | |
| download | inkscape-60437ac397d41678daba5daece227240e8ddd364.tar.gz inkscape-60437ac397d41678daba5daece227240e8ddd364.zip | |
Upgrade to 2Geom r2413
(bzr r14059.2.18)
Diffstat (limited to 'src/2geom/curve.h')
| -rw-r--r-- | src/2geom/curve.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/2geom/curve.h b/src/2geom/curve.h index 7da0d17a0..abbdb1100 100644 --- a/src/2geom/curve.h +++ b/src/2geom/curve.h @@ -184,7 +184,17 @@ public: * Because of this method, all curve types must be closed under affine * transformations. * @param m Affine describing the affine transformation */ - virtual void transform(Affine const &m) = 0; + void transform(Affine const &m) { + *this *= m; + } + + virtual void operator*=(Translate const &tr) { *this *= Affine(tr); } + virtual void operator*=(Scale const &s) { *this *= Affine(s); } + virtual void operator*=(Rotate const &r) { *this *= Affine(r); } + virtual void operator*=(HShear const &hs) { *this *= Affine(hs); } + virtual void operator*=(VShear const &vs) { *this *= Affine(vs); } + virtual void operator*=(Zoom const &z) { *this *= Affine(z); } + virtual void operator*=(Affine const &m) = 0; /** @brief Create a curve transformed by an affine transformation. * This method returns a new curve instead modifying the existing one. |
