diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2014-05-05 08:45:33 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2014-05-05 08:45:33 +0000 |
| commit | e3d114cbca503194d41fc8edb86848ea03074089 (patch) | |
| tree | 0019498d47ccb79f7a6f447b8a0f468372006bb7 /src/sp-lpe-item.cpp | |
| parent | adding VinÃcius work whith node tips (diff) | |
| parent | Documentation. Elements of design tutorial update ((not fully translated); Up... (diff) | |
| download | inkscape-e3d114cbca503194d41fc8edb86848ea03074089.tar.gz inkscape-e3d114cbca503194d41fc8edb86848ea03074089.zip | |
update to trunk
(bzr r11950.1.340)
Diffstat (limited to 'src/sp-lpe-item.cpp')
| -rw-r--r-- | src/sp-lpe-item.cpp | 21 |
1 files changed, 14 insertions, 7 deletions
diff --git a/src/sp-lpe-item.cpp b/src/sp-lpe-item.cpp index 33359727a..762dc3191 100644 --- a/src/sp-lpe-item.cpp +++ b/src/sp-lpe-item.cpp @@ -442,6 +442,9 @@ void SPLPEItem::addPathEffect(LivePathEffectObject * new_lpeobj) g_free(hrefstr); } +/** + * If keep_path == true, the item should not be updated, effectively 'flattening' the LPE. + */ void SPLPEItem::removeCurrentPathEffect(bool keep_paths) { Inkscape::LivePathEffect::LPEObjectReference* lperef = this->getCurrentLPEReference(); @@ -456,27 +459,31 @@ void SPLPEItem::removeCurrentPathEffect(bool keep_paths) this->getRepr()->setAttribute("inkscape:path-effect", r.c_str()); } else { this->getRepr()->setAttribute("inkscape:path-effect", NULL); + } + + if (!keep_paths) { // Make sure that ellipse is stored as <svg:circle> or <svg:ellipse> if possible. if( SP_IS_GENERICELLIPSE(this)) { SP_GENERICELLIPSE(this)->write( this->getRepr()->document(), this->getRepr(), SP_OBJECT_WRITE_EXT ); } - } - if (!keep_paths) { sp_lpe_item_cleanup_original_path_recursive(this); } } +/** + * If keep_path == true, the item should not be updated, effectively 'flattening' the LPE. + */ void SPLPEItem::removeAllPathEffects(bool keep_paths) { this->getRepr()->setAttribute("inkscape:path-effect", NULL); - // Make sure that ellipse is stored as <svg:circle> or <svg:ellipse> if possible. - if( SP_IS_GENERICELLIPSE(this)) { - SP_GENERICELLIPSE(this)->write( this->getRepr()->document(), this->getRepr(), SP_OBJECT_WRITE_EXT ); - } - if (!keep_paths) { + // Make sure that ellipse is stored as <svg:circle> or <svg:ellipse> if possible. + if (SP_IS_GENERICELLIPSE(this)) { + SP_GENERICELLIPSE(this)->write(this->getRepr()->document(), this->getRepr(), SP_OBJECT_WRITE_EXT); + } + sp_lpe_item_cleanup_original_path_recursive(this); } } |
