diff options
| author | Maximilian Albert <maximilian.albert@gmail.com> | 2008-09-13 16:51:16 +0000 |
|---|---|---|
| committer | cilix42 <cilix42@users.sourceforge.net> | 2008-09-13 16:51:16 +0000 |
| commit | 7b4d58faf59da2981349ebfacdbcdd64fc05f228 (patch) | |
| tree | 59cec14d5c71b8942eb942e704c76e6577b946e8 /src/sp-lpe-item.cpp | |
| parent | Add option to align & distribute dialog to treat the selection as a group (cl... (diff) | |
| download | inkscape-7b4d58faf59da2981349ebfacdbcdd64fc05f228.tar.gz inkscape-7b4d58faf59da2981349ebfacdbcdd64fc05f228.zip | |
Hide canvas text, too, when lpe-path-length is invisible
(bzr r6801)
Diffstat (limited to 'src/sp-lpe-item.cpp')
| -rw-r--r-- | src/sp-lpe-item.cpp | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/src/sp-lpe-item.cpp b/src/sp-lpe-item.cpp index 6e2e65d7d..56ffd190c 100644 --- a/src/sp-lpe-item.cpp +++ b/src/sp-lpe-item.cpp @@ -18,6 +18,7 @@ #endif #include "live_effects/effect.h" +#include "live_effects/lpe-path_length.h" #include "live_effects/lpeobject.h" #include "live_effects/lpeobject-reference.h" @@ -353,6 +354,19 @@ sp_lpe_item_update_patheffect (SPLPEItem *lpeitem, bool wholetree, bool write) if (!sp_lpe_item_path_effects_enabled(lpeitem)) return; + // TODO: hack! this will be removed when path length measuring is reimplemented in a better way + PathEffectList lpelist = sp_lpe_item_get_effect_list(lpeitem); + std::list<Inkscape::LivePathEffect::LPEObjectReference *>::iterator i; + for (i = lpelist.begin(); i != lpelist.end(); ++i) { + Inkscape::LivePathEffect::Effect *lpe = (*i)->lpeobject->lpe; + if (dynamic_cast<Inkscape::LivePathEffect::LPEPathLength *>(lpe)) { + if (!lpe->isVisible()) { + // we manually disable text for LPEPathLength + dynamic_cast<Inkscape::LivePathEffect::LPEPathLength *>(lpe)->hideCanvasText(); + } + } + } + SPLPEItem *top; if (wholetree) { |
