Code

ellipses and groups now use 2geompath for svg_write: sp_svg_write_path(np->curve...
authorjohanengelen <johanengelen@users.sourceforge.net>
Fri, 6 Jun 2008 23:51:48 +0000 (23:51 +0000)
committerjohanengelen <johanengelen@users.sourceforge.net>
Fri, 6 Jun 2008 23:51:48 +0000 (23:51 +0000)
src/sp-ellipse.cpp
src/sp-item-group.cpp

index e7a42ab7f2027d3aae65c624e46ce3632941f6ef..4b68a2ca6b14094e9cbf4294dcb1c1af40377e41 100644 (file)
@@ -167,14 +167,9 @@ sp_genericellipse_update_patheffect(SPLPEItem *lpeitem, bool write)
     if (write) {
         Inkscape::XML::Node *repr = SP_OBJECT_REPR(shape);
         if ( shape->curve != NULL ) {
-            NArtBpath const *abp = shape->curve->get_bpath();
-            if (abp) {
-                gchar *str = sp_svg_write_path(abp);
-                repr->setAttribute("d", str);
-                g_free(str);
-            } else {
-                repr->setAttribute("d", "");
-            }
+            gchar *str = sp_svg_write_path(shape->curve->get_pathvector());
+            repr->setAttribute("d", str);
+            g_free(str);
         } else {
             repr->setAttribute("d", NULL);
         }
index 347f50491454b596e88d1077f4b6e86bb720621e..109b55eb76331c426f7e8dd8d2ab2a41bc20f8e3 100644 (file)
@@ -853,16 +853,11 @@ sp_group_perform_patheffect(SPGroup *group, SPGroup *topgroup)
             
             Inkscape::XML::Node *repr = SP_OBJECT_REPR(subitem);
  
-                NArtBpath const *abp = c->first_bpath();
-                if (abp) {
-                    gchar *str = sp_svg_write_path(abp);
-                    repr->setAttribute("d", str);
-                    g_free(str);
-                } else {
-                   repr->setAttribute("d", "");
-                }
+            gchar *str = sp_svg_write_path(c->get_pathvector());
+            repr->setAttribute("d", str);
+            g_free(str);
 
-                c->unref();
+            c->unref();
         }
     }
 }