diff options
Diffstat (limited to 'src/sp-star.cpp')
| -rw-r--r-- | src/sp-star.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/sp-star.cpp b/src/sp-star.cpp index d112962a2..d7ee352c7 100644 --- a/src/sp-star.cpp +++ b/src/sp-star.cpp @@ -223,7 +223,7 @@ void SPStar::update(SPCtx *ctx, guint flags) { } void SPStar::update_patheffect(bool write) { - this->set_shape(); + this->set_shape(true); if (write) { Inkscape::XML::Node *repr = this->getRepr(); @@ -363,7 +363,7 @@ sp_star_get_curvepoint (SPStar *star, SPStarPoint point, gint index, bool previ) #define NEXT false #define PREV true -void SPStar::set_shape() { +void SPStar::set_shape(bool force) { // perhaps we should convert all our shapes into LPEs without source path // and with knotholders for parameters, then this situation will be handled automatically // by disabling the entire stack (including the shape LPE) @@ -446,6 +446,12 @@ void SPStar::set_shape() { /* Reset the shape'scurve to the "original_curve" * This is very important for LPEs to work properly! (the bbox might be recalculated depending on the curve in shape)*/ + if(this->getCurveBeforeLPE()) { + if(!force && this->getCurveBeforeLPE()->get_pathvector() == c->get_pathvector()) { + c->unref(); + return; + } + } this->setCurveInsync( c, TRUE); this->setCurveBeforeLPE( c ); |
