diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2014-11-15 17:29:41 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2014-11-15 17:29:41 +0000 |
| commit | a5333b6abc807176319c96d66cb7111e70f4896f (patch) | |
| tree | 5d835204a110f9fa328e96919078edf83af69784 /src/live_effects/lpegroupbbox.cpp | |
| parent | Six a bug on subpaths pointed by suv (diff) | |
| download | inkscape-a5333b6abc807176319c96d66cb7111e70f4896f.tar.gz inkscape-a5333b6abc807176319c96d66cb7111e70f4896f.zip | |
ignore this commit
(bzr r13682.1.9)
Diffstat (limited to 'src/live_effects/lpegroupbbox.cpp')
| -rw-r--r-- | src/live_effects/lpegroupbbox.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/live_effects/lpegroupbbox.cpp b/src/live_effects/lpegroupbbox.cpp index 2a1b70a6a..78545e9c5 100644 --- a/src/live_effects/lpegroupbbox.cpp +++ b/src/live_effects/lpegroupbbox.cpp @@ -8,6 +8,7 @@ #include "live_effects/lpegroupbbox.h" #include "sp-item.h" +#include "sp-item-group.h" namespace Inkscape { namespace LivePathEffect { @@ -34,9 +35,20 @@ void GroupBBoxEffect::original_bbox(SPLPEItem const* lpeitem, bool absolute) } Geom::OptRect bbox = lpeitem->geometricBounds(transform); + std::cout << bbox->hasZeroArea() << "=AREA\n"; + if(bbox->hasZeroArea() && SP_IS_GROUP(lpeitem)){ + bbox = (Geom::OptRect)SP_GROUP(lpeitem)->bbox(transform, SPLPEItem::GEOMETRIC_BBOX); + //GSList const *items = sp_item_group_item_list(SPGroup * group); + //for ( GSList const *i = items ; i != NULL ; i = i->next ) { + // bbox.unionWith(SP_ITEM(i->data)->desktopGeometricBounds()); + //} + } + std::cout << bbox->hasZeroArea() << "=AREA222\n"; if (bbox) { boundingbox_X = (*bbox)[Geom::X]; boundingbox_Y = (*bbox)[Geom::Y]; + std::cout << boundingbox_X << "=BBOXX\n"; + std::cout << boundingbox_Y << "=BBOXY\n"; } else { boundingbox_X = Geom::Interval(); boundingbox_Y = Geom::Interval(); |
