diff options
| author | Liam P. White <inkscapebrony@gmail.com> | 2014-08-04 16:10:37 +0000 |
|---|---|---|
| committer | Liam P. White <inkscapebrony@gmail.com> | 2014-08-04 16:10:37 +0000 |
| commit | acd8f135f2a901c5f046e51ad7783e442c43997a (patch) | |
| tree | 12418cabb430ca8041c12e7c3d014185c4b4541b /src/sp-item.cpp | |
| parent | Exporting. Fix for bug #1350897 (XAML export formats numbers in the top-level... (diff) | |
| download | inkscape-acd8f135f2a901c5f046e51ad7783e442c43997a.tar.gz inkscape-acd8f135f2a901c5f046e51ad7783e442c43997a.zip | |
Allow editing of fill and stroke patterns simultaneously. Fixes #601336, #604025, #486192
Fixed bugs:
- https://launchpad.net/bugs/601336
- https://launchpad.net/bugs/604025
- https://launchpad.net/bugs/486192
(bzr r13489)
Diffstat (limited to 'src/sp-item.cpp')
| -rw-r--r-- | src/sp-item.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/sp-item.cpp b/src/sp-item.cpp index 6c2ada9d7..780845deb 100644 --- a/src/sp-item.cpp +++ b/src/sp-item.cpp @@ -1109,9 +1109,10 @@ void SPItem::invoke_hide(unsigned key) // Adjusters -void SPItem::adjust_pattern (Geom::Affine const &postmul, bool set) +void SPItem::adjust_pattern(Geom::Affine const &postmul, bool set, PatternTransform pt) { - if (style && (style->fill.isPaintserver())) { + bool fill = (pt == TRANSFORM_FILL || pt == TRANSFORM_BOTH); + if (fill && style && (style->fill.isPaintserver())) { SPObject *server = style->getFillPaintServer(); if ( SP_IS_PATTERN(server) ) { SPPattern *pattern = sp_pattern_clone_if_necessary(this, SP_PATTERN(server), "fill"); @@ -1119,7 +1120,8 @@ void SPItem::adjust_pattern (Geom::Affine const &postmul, bool set) } } - if (style && (style->stroke.isPaintserver())) { + bool stroke = (pt == TRANSFORM_STROKE || pt == TRANSFORM_BOTH); + if (stroke && style && (style->stroke.isPaintserver())) { SPObject *server = style->getStrokePaintServer(); if ( SP_IS_PATTERN(server) ) { SPPattern *pattern = sp_pattern_clone_if_necessary(this, SP_PATTERN(server), "stroke"); |
