diff options
| author | Jabier Arraiza <jabier.arraiza@marker.es> | 2019-07-14 18:59:12 +0000 |
|---|---|---|
| committer | Jabier Arraiza <jabier.arraiza@marker.es> | 2019-07-14 18:59:12 +0000 |
| commit | 50fd2f7be0c87a24fee7100514201180f3a5b740 (patch) | |
| tree | 4d1244c265d6e1d5777bb7b9e8e674fc3c6f5e51 /src/ui/tools/freehand-base.cpp | |
| parent | remove clang format diff (diff) | |
| download | inkscape-50fd2f7be0c87a24fee7100514201180f3a5b740.tar.gz inkscape-50fd2f7be0c87a24fee7100514201180f3a5b740.zip | |
retain tool color
Diffstat (limited to 'src/ui/tools/freehand-base.cpp')
| -rw-r--r-- | src/ui/tools/freehand-base.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ui/tools/freehand-base.cpp b/src/ui/tools/freehand-base.cpp index 556ba9f2b..88a0fcf2c 100644 --- a/src/ui/tools/freehand-base.cpp +++ b/src/ui/tools/freehand-base.cpp @@ -291,6 +291,7 @@ static void spdc_apply_powerstroke_shape(std::vector<Geom::Point> points, Freeha item = successor; dc->selection->set(item); item->setLocked(false); + dc->white_item = item; rename_id(SP_OBJECT(item), "path-1"); } else { using namespace Inkscape::LivePathEffect; @@ -451,7 +452,7 @@ static void spdc_check_for_and_apply_waiting_LPE(FreehandBase *dc, SPItem *item, if (dc->tablet_enabled) { std::vector<Geom::Point> points; spdc_apply_powerstroke_shape(points, dc, item); - shape_applied = false; + shape_applied = true; shape = NONE; previous_shape_type = NONE; } @@ -618,7 +619,7 @@ static void spdc_check_for_and_apply_waiting_LPE(FreehandBase *dc, SPItem *item, sp_repr_css_set_property (css, "fill", cfill); } sp_repr_css_set_property (css, "stroke", "none"); - sp_desktop_apply_css_recursive(item, css, true); + sp_desktop_apply_css_recursive(dc->white_item, css, true); sp_repr_css_attr_unref(css); return; } @@ -926,6 +927,7 @@ static void spdc_flush_white(FreehandBase *dc, SPCurve *gc) if (!dc->white_item) { // Attach repr SPItem *item = SP_ITEM(desktop->currentLayer()->appendChildRepr(repr)); + dc->white_item = item; //Bend needs the transforms applied after, Other effects best before spdc_check_for_and_apply_waiting_LPE(dc, item, c, true); Inkscape::GC::release(repr); |
