From a7f2b2ba3f13ceb60376802f4a31e104153839e8 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Tue, 17 Feb 2015 03:00:37 +0100 Subject: At first, I was thinking "I just have to go to the selection file, and change that GSList* with a std::list, then resolve the few problems" So, i tried that. And I will continue tomorrow, and the days after, on and on. (bzr r13922.1.1) --- src/path-chemistry.cpp | 125 +++++++++++++++++++++++++------------------------ 1 file changed, 63 insertions(+), 62 deletions(-) (limited to 'src/path-chemistry.cpp') diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp index 5f6e1495b..a5e71b720 100644 --- a/src/path-chemistry.cpp +++ b/src/path-chemistry.cpp @@ -44,13 +44,22 @@ using Inkscape::DocumentUndo; + +inline bool less_than_objects(SPObject const *first, SPObject const *second) +{ + return sp_repr_compare_position(first->getRepr(), + second->getRepr())<0; +} + void sp_selected_path_combine(SPDesktop *desktop) { Inkscape::Selection *selection = desktop->getSelection(); SPDocument *doc = desktop->getDocument(); + + SelContainer items(selection->itemList()); - if (g_slist_length((GSList *) selection->itemList()) < 1) { + if (items.size() < 1) { desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select object(s) to combine.")); return; } @@ -59,28 +68,26 @@ sp_selected_path_combine(SPDesktop *desktop) // set "busy" cursor desktop->setWaitingCursor(); - GSList *items = g_slist_copy((GSList *) selection->itemList()); - items = sp_degroup_list (items); // descend into any groups in selection - GSList *to_paths = NULL; - for (GSList *i = items; i != NULL; i = i->next) { - SPItem *item = (SPItem *) i->data; + SelContainer to_paths; + for (SelContainer::const_iterator i=items.begin();i!=items.end();i++) { + SPItem *item = (SPItem *) (*i); if (!dynamic_cast(item) && !dynamic_cast(item)) { - to_paths = g_slist_prepend(to_paths, item); + to_paths.push_front(item); } } - GSList *converted = NULL; - bool did = sp_item_list_to_curves(to_paths, &items, &converted); - g_slist_free(to_paths); - for (GSList *i = converted; i != NULL; i = i->next) - items = g_slist_prepend(items, doc->getObjectByRepr((Inkscape::XML::Node*)(i->data))); + SelContainer converted; + bool did = sp_item_list_to_curves(to_paths, items, converted); + to_paths.clear(); + for (SelContainer::const_iterator i=converted.begin();i!=converted.end();i++) + items.push_front(doc->getObjectByRepr((Inkscape::XML::Node*)(*i))); items = sp_degroup_list (items); // converting to path may have added more groups, descend again - items = g_slist_sort(items, (GCompareFunc) sp_item_repr_compare_position); - items = g_slist_reverse(items); - assert(items); // cannot be NULL because of list length check at top of function + items.sort(less_than_objects); + items.reverse(); + assert(!items.empty()); // cannot be NULL because of list length check at top of function // remember the position, id, transform and style of the topmost path, they will be assigned to the combined one gint position = 0; @@ -97,9 +104,9 @@ sp_selected_path_combine(SPDesktop *desktop) selection->clear(); } - for (GSList *i = items; i != NULL; i = i->next) { // going from top to bottom + for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ - SPItem *item = (SPItem *) i->data; + SPItem *item = (SPItem *) (*i); SPPath *path = dynamic_cast(item); if (!path) { continue; @@ -136,7 +143,6 @@ sp_selected_path_combine(SPDesktop *desktop) } } - g_slist_free(items); if (did) { first->deleteObject(false); @@ -200,11 +206,10 @@ sp_selected_path_break_apart(SPDesktop *desktop) bool did = false; - for (GSList *items = g_slist_copy((GSList *) selection->itemList()); - items != NULL; - items = items->next) { + SelContainer itemlist(selection->itemList()); + for (SelContainer::const_iterator i=itemlist.begin();i!=itemlist.end();i++){ - SPItem *item = (SPItem *) items->data; + SPItem *item = (SPItem *) (*i); SPPath *path = dynamic_cast(item); if (!path) { @@ -241,7 +246,7 @@ sp_selected_path_break_apart(SPDesktop *desktop) curve->unref(); - GSList *reprs = NULL; + SelContainer reprs; for (GSList *l = list; l != NULL; l = l->next) { curve = (SPCurve *) l->data; @@ -267,14 +272,14 @@ sp_selected_path_break_apart(SPDesktop *desktop) if (l == list) repr->setAttribute("id", id); - reprs = g_slist_prepend (reprs, repr); + reprs.push_front(dynamic_cast(repr)); Inkscape::GC::release(repr); } selection->setReprList(reprs); - g_slist_free(reprs); + reprs.clear(); g_slist_free(list); g_free(style); g_free(path_effect); @@ -307,18 +312,18 @@ sp_selected_path_to_curves(Inkscape::Selection *selection, SPDesktop *desktop, b desktop->setWaitingCursor(); } - GSList *selected = g_slist_copy((GSList *) selection->itemList()); - GSList *to_select = NULL; + SelContainer selected(selection->itemList()); + SelContainer to_select; selection->clear(); - GSList *items = g_slist_copy(selected); + SelContainer items(selected); - did = sp_item_list_to_curves(items, &selected, &to_select); + did = sp_item_list_to_curves(items, selected, to_select); - g_slist_free (items); + items.clear(); selection->setReprList(to_select); selection->addList(selected); - g_slist_free (to_select); - g_slist_free (selected); + to_select.clear(); + selected.clear(); if (interactive && desktop) { desktop->clearWaitingCursor(); @@ -341,33 +346,29 @@ void sp_selected_to_lpeitems(SPDesktop *desktop) return; } - GSList *selected = g_slist_copy((GSList *) selection->itemList()); - GSList *to_select = NULL; + SelContainer selected(selection->itemList()); + SelContainer to_select; selection->clear(); - GSList *items = g_slist_copy(selected); + SelContainer items(selected); + - sp_item_list_to_curves(items, &selected, &to_select, true); + sp_item_list_to_curves(items, selected, to_select, true); - g_slist_free(items); - items = 0; + items.clear(); selection->setReprList(to_select); selection->addList(selected); - g_slist_free(to_select); - to_select = 0; - g_slist_free(selected); - selected = 0; + to_select.clear(); + selected.clear(); } bool -sp_item_list_to_curves(const GSList *items, GSList **selected, GSList **to_select, bool skip_all_lpeitems) +sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelContainer &to_select, bool skip_all_lpeitems) { bool did = false; - for (; - items != NULL; - items = items->next) { + for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ - SPItem *item = dynamic_cast(static_cast(items->data)); + SPItem *item = dynamic_cast(static_cast(*i)); g_assert(item != NULL); SPDocument *document = item->document; @@ -398,9 +399,9 @@ sp_item_list_to_curves(const GSList *items, GSList **selected, GSList **to_selec Inkscape::XML::Node *repr = box3d_convert_to_group(box)->getRepr(); if (repr) { - *to_select = g_slist_prepend (*to_select, repr); + to_select.push_front(dynamic_cast(repr)); did = true; - *selected = g_slist_remove (*selected, item); + selected.remove(item); } continue; @@ -408,17 +409,17 @@ sp_item_list_to_curves(const GSList *items, GSList **selected, GSList **to_selec if (group) { group->removeAllPathEffects(true); - GSList *item_list = sp_item_group_item_list(group); + SelContainer item_list = sp_item_group_item_list(group); - GSList *item_to_select = NULL; - GSList *item_selected = NULL; + SelContainer item_to_select; + SelContainer item_selected; - if (sp_item_list_to_curves(item_list, &item_selected, &item_to_select)) + if (sp_item_list_to_curves(item_list, item_selected, item_to_select)) did = true; - g_slist_free(item_list); - g_slist_free(item_to_select); - g_slist_free(item_selected); + item_list.clear(); + item_to_select.clear(); + item_selected.clear(); continue; } @@ -428,7 +429,7 @@ sp_item_list_to_curves(const GSList *items, GSList **selected, GSList **to_selec continue; did = true; - *selected = g_slist_remove (*selected, item); + selected.remove(item); // remember the position of the item gint pos = item->getRepr()->position(); @@ -470,7 +471,7 @@ sp_item_list_to_curves(const GSList *items, GSList **selected, GSList **to_selec /* Buglet: We don't re-add the (new version of the) object to the selection of any other * desktops where it was previously selected. */ - *to_select = g_slist_prepend (*to_select, repr); + to_select.push_front(dynamic_cast(repr)); Inkscape::GC::release(repr); } @@ -612,9 +613,9 @@ void sp_selected_path_reverse(SPDesktop *desktop) { Inkscape::Selection *selection = desktop->getSelection(); - GSList *items = (GSList *) selection->itemList(); + SelContainer items = selection->itemList(); - if (!items) { + if (items.empty()) { desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select path(s) to reverse.")); return; } @@ -626,9 +627,9 @@ sp_selected_path_reverse(SPDesktop *desktop) bool did = false; desktop->messageStack()->flash(Inkscape::IMMEDIATE_MESSAGE, _("Reversing paths...")); - for (GSList *i = items; i != NULL; i = i->next) { + for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ - SPPath *path = dynamic_cast(static_cast(i->data)); + SPPath *path = dynamic_cast(static_cast(*i)); if (!path) { continue; } -- cgit v1.2.3 From 5fd00cab14d48beaf2279a2b8f3ad5b02b76c87b Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Thu, 19 Feb 2015 04:25:21 +0100 Subject: Put a few std::vector (bzr r13922.1.5) --- src/path-chemistry.cpp | 73 +++++++++++++++++++++++++------------------------- 1 file changed, 37 insertions(+), 36 deletions(-) (limited to 'src/path-chemistry.cpp') diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp index a5e71b720..ae1e0064f 100644 --- a/src/path-chemistry.cpp +++ b/src/path-chemistry.cpp @@ -51,13 +51,19 @@ inline bool less_than_objects(SPObject const *first, SPObject const *second) second->getRepr())<0; } +inline bool less_than_items(SPItem const *first, SPItem const *second) +{ + return sp_repr_compare_position(first->getRepr(), + second->getRepr())<0; +} + void sp_selected_path_combine(SPDesktop *desktop) { Inkscape::Selection *selection = desktop->getSelection(); SPDocument *doc = desktop->getDocument(); - SelContainer items(selection->itemList()); + std::vector items(selection->itemList()); if (items.size() < 1) { desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select object(s) to combine.")); @@ -70,23 +76,22 @@ sp_selected_path_combine(SPDesktop *desktop) items = sp_degroup_list (items); // descend into any groups in selection - SelContainer to_paths; - for (SelContainer::const_iterator i=items.begin();i!=items.end();i++) { + std::vector to_paths; + for (std::vector::const_reverse_iterator i=items.rbegin();i!=items.rend();i++) { SPItem *item = (SPItem *) (*i); if (!dynamic_cast(item) && !dynamic_cast(item)) { - to_paths.push_front(item); + to_paths.push_back(item); } } - SelContainer converted; + std::vector converted; bool did = sp_item_list_to_curves(to_paths, items, converted); to_paths.clear(); - for (SelContainer::const_iterator i=converted.begin();i!=converted.end();i++) - items.push_front(doc->getObjectByRepr((Inkscape::XML::Node*)(*i))); + for (std::vector::const_iterator i=converted.begin();i!=converted.end();i++) + items.push_back((SPItem*)doc->getObjectByRepr((Inkscape::XML::Node*)(*i))); items = sp_degroup_list (items); // converting to path may have added more groups, descend again - items.sort(less_than_objects); - items.reverse(); + sort(items.begin(),items.end(),less_than_objects); assert(!items.empty()); // cannot be NULL because of list length check at top of function // remember the position, id, transform and style of the topmost path, they will be assigned to the combined one @@ -104,7 +109,7 @@ sp_selected_path_combine(SPDesktop *desktop) selection->clear(); } - for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ + for (std::vector::const_reverse_iterator i=items.rbegin();i!=items.rend();i++){ SPItem *item = (SPItem *) (*i); SPPath *path = dynamic_cast(item); @@ -206,8 +211,8 @@ sp_selected_path_break_apart(SPDesktop *desktop) bool did = false; - SelContainer itemlist(selection->itemList()); - for (SelContainer::const_iterator i=itemlist.begin();i!=itemlist.end();i++){ + std::vector itemlist(selection->itemList()); + for (std::vector::const_iterator i=itemlist.begin();i!=itemlist.end();i++){ SPItem *item = (SPItem *) (*i); @@ -246,7 +251,7 @@ sp_selected_path_break_apart(SPDesktop *desktop) curve->unref(); - SelContainer reprs; + std::vector reprs; for (GSList *l = list; l != NULL; l = l->next) { curve = (SPCurve *) l->data; @@ -272,14 +277,13 @@ sp_selected_path_break_apart(SPDesktop *desktop) if (l == list) repr->setAttribute("id", id); - reprs.push_front(dynamic_cast(repr)); + reprs.push_back(repr); Inkscape::GC::release(repr); } - + //reverse selection->setReprList(reprs); - reprs.clear(); g_slist_free(list); g_free(style); g_free(path_effect); @@ -312,10 +316,10 @@ sp_selected_path_to_curves(Inkscape::Selection *selection, SPDesktop *desktop, b desktop->setWaitingCursor(); } - SelContainer selected(selection->itemList()); - SelContainer to_select; + std::vector selected(selection->itemList()); + std::vector to_select; selection->clear(); - SelContainer items(selected); + std::vector items(selected); did = sp_item_list_to_curves(items, selected, to_select); @@ -346,27 +350,24 @@ void sp_selected_to_lpeitems(SPDesktop *desktop) return; } - SelContainer selected(selection->itemList()); - SelContainer to_select; + std::vector selected(selection->itemList()); + std::vector to_select; selection->clear(); - SelContainer items(selected); + std::vector items(selected); sp_item_list_to_curves(items, selected, to_select, true); - items.clear(); selection->setReprList(to_select); selection->addList(selected); - to_select.clear(); - selected.clear(); } bool -sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelContainer &to_select, bool skip_all_lpeitems) +sp_item_list_to_curves(const std::vector &items, std::vector& selected, std::vector &to_select, bool skip_all_lpeitems) { bool did = false; - for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ + for (std::vector::const_iterator i=items.begin();i!=items.end();i++){ SPItem *item = dynamic_cast(static_cast(*i)); g_assert(item != NULL); @@ -399,9 +400,9 @@ sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelCon Inkscape::XML::Node *repr = box3d_convert_to_group(box)->getRepr(); if (repr) { - to_select.push_front(dynamic_cast(repr)); + to_select.push_back(repr); did = true; - selected.remove(item); + selected.erase(find(selected.begin(),selected.end(),item)); } continue; @@ -409,10 +410,10 @@ sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelCon if (group) { group->removeAllPathEffects(true); - SelContainer item_list = sp_item_group_item_list(group); + std::vector item_list = sp_item_group_item_list(group); - SelContainer item_to_select; - SelContainer item_selected; + std::vector item_to_select; + std::vector item_selected; if (sp_item_list_to_curves(item_list, item_selected, item_to_select)) did = true; @@ -429,7 +430,7 @@ sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelCon continue; did = true; - selected.remove(item); + selected.erase(find(selected.begin(),selected.end(),item)); // remember the position of the item gint pos = item->getRepr()->position(); @@ -471,7 +472,7 @@ sp_item_list_to_curves(const SelContainer &items, SelContainer& selected, SelCon /* Buglet: We don't re-add the (new version of the) object to the selection of any other * desktops where it was previously selected. */ - to_select.push_front(dynamic_cast(repr)); + to_select.push_back(repr); Inkscape::GC::release(repr); } @@ -613,7 +614,7 @@ void sp_selected_path_reverse(SPDesktop *desktop) { Inkscape::Selection *selection = desktop->getSelection(); - SelContainer items = selection->itemList(); + std::vector items = selection->itemList(); if (items.empty()) { desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select path(s) to reverse.")); @@ -627,7 +628,7 @@ sp_selected_path_reverse(SPDesktop *desktop) bool did = false; desktop->messageStack()->flash(Inkscape::IMMEDIATE_MESSAGE, _("Reversing paths...")); - for (SelContainer::const_iterator i=items.begin();i!=items.end();i++){ + for (std::vector::const_iterator i=items.begin();i!=items.end();i++){ SPPath *path = dynamic_cast(static_cast(*i)); if (!path) { -- cgit v1.2.3 From 9a7fa4d1899d30ec745107823f307b2a0bf3172f Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Fri, 27 Feb 2015 03:10:36 +0100 Subject: corrected the casts (hopefully) (bzr r13922.1.10) --- src/path-chemistry.cpp | 49 +++++++++++++++++-------------------------------- 1 file changed, 17 insertions(+), 32 deletions(-) (limited to 'src/path-chemistry.cpp') diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp index ae1e0064f..53ad96596 100644 --- a/src/path-chemistry.cpp +++ b/src/path-chemistry.cpp @@ -45,16 +45,10 @@ using Inkscape::DocumentUndo; -inline bool less_than_objects(SPObject const *first, SPObject const *second) -{ - return sp_repr_compare_position(first->getRepr(), - second->getRepr())<0; -} - inline bool less_than_items(SPItem const *first, SPItem const *second) { return sp_repr_compare_position(first->getRepr(), - second->getRepr())<0; + second->getRepr())>0; } void @@ -77,21 +71,19 @@ sp_selected_path_combine(SPDesktop *desktop) items = sp_degroup_list (items); // descend into any groups in selection std::vector to_paths; - for (std::vector::const_reverse_iterator i=items.rbegin();i!=items.rend();i++) { - SPItem *item = (SPItem *) (*i); - if (!dynamic_cast(item) && !dynamic_cast(item)) { - to_paths.push_back(item); + for (std::vector::const_reverse_iterator i = items.rbegin(); i != items.rend(); i++) { + if (!dynamic_cast(*i) && !dynamic_cast(*i)) { + to_paths.push_back(*i); } } std::vector converted; bool did = sp_item_list_to_curves(to_paths, items, converted); - to_paths.clear(); - for (std::vector::const_iterator i=converted.begin();i!=converted.end();i++) - items.push_back((SPItem*)doc->getObjectByRepr((Inkscape::XML::Node*)(*i))); + for (std::vector::const_iterator i = converted.begin(); i != converted.end(); i++) + items.push_back((SPItem*)doc->getObjectByRepr(*i)); items = sp_degroup_list (items); // converting to path may have added more groups, descend again - sort(items.begin(),items.end(),less_than_objects); + sort(items.begin(),items.end(),less_than_items); assert(!items.empty()); // cannot be NULL because of list length check at top of function // remember the position, id, transform and style of the topmost path, they will be assigned to the combined one @@ -109,9 +101,9 @@ sp_selected_path_combine(SPDesktop *desktop) selection->clear(); } - for (std::vector::const_reverse_iterator i=items.rbegin();i!=items.rend();i++){ + for (std::vector::const_reverse_iterator i = items.rbegin(); i != items.rend(); i++){ - SPItem *item = (SPItem *) (*i); + SPItem *item = *i; SPPath *path = dynamic_cast(item); if (!path) { continue; @@ -212,9 +204,9 @@ sp_selected_path_break_apart(SPDesktop *desktop) bool did = false; std::vector itemlist(selection->itemList()); - for (std::vector::const_iterator i=itemlist.begin();i!=itemlist.end();i++){ + for (std::vector::const_iterator i = itemlist.begin(); i != itemlist.end(); i++){ - SPItem *item = (SPItem *) (*i); + SPItem *item = *i; SPPath *path = dynamic_cast(item); if (!path) { @@ -277,11 +269,10 @@ sp_selected_path_break_apart(SPDesktop *desktop) if (l == list) repr->setAttribute("id", id); - reprs.push_back(repr); + reprs.insert(reprs.begin(),repr); Inkscape::GC::release(repr); } - //reverse selection->setReprList(reprs); g_slist_free(list); @@ -323,11 +314,8 @@ sp_selected_path_to_curves(Inkscape::Selection *selection, SPDesktop *desktop, b did = sp_item_list_to_curves(items, selected, to_select); - items.clear(); selection->setReprList(to_select); selection->addList(selected); - to_select.clear(); - selected.clear(); if (interactive && desktop) { desktop->clearWaitingCursor(); @@ -367,9 +355,9 @@ sp_item_list_to_curves(const std::vector &items, std::vector& { bool did = false; - for (std::vector::const_iterator i=items.begin();i!=items.end();i++){ + for (std::vector::const_iterator i = items.begin(); i != items.end(); i++){ - SPItem *item = dynamic_cast(static_cast(*i)); + SPItem *item = *i; g_assert(item != NULL); SPDocument *document = item->document; @@ -400,7 +388,7 @@ sp_item_list_to_curves(const std::vector &items, std::vector& Inkscape::XML::Node *repr = box3d_convert_to_group(box)->getRepr(); if (repr) { - to_select.push_back(repr); + to_select.insert(to_select.begin(),repr); did = true; selected.erase(find(selected.begin(),selected.end(),item)); } @@ -418,9 +406,6 @@ sp_item_list_to_curves(const std::vector &items, std::vector& if (sp_item_list_to_curves(item_list, item_selected, item_to_select)) did = true; - item_list.clear(); - item_to_select.clear(); - item_selected.clear(); continue; } @@ -472,7 +457,7 @@ sp_item_list_to_curves(const std::vector &items, std::vector& /* Buglet: We don't re-add the (new version of the) object to the selection of any other * desktops where it was previously selected. */ - to_select.push_back(repr); + to_select.insert(to_select.begin(),repr); Inkscape::GC::release(repr); } @@ -628,7 +613,7 @@ sp_selected_path_reverse(SPDesktop *desktop) bool did = false; desktop->messageStack()->flash(Inkscape::IMMEDIATE_MESSAGE, _("Reversing paths...")); - for (std::vector::const_iterator i=items.begin();i!=items.end();i++){ + for (std::vector::const_iterator i = items.begin(); i != items.end(); i++){ SPPath *path = dynamic_cast(static_cast(*i)); if (!path) { -- cgit v1.2.3 From 9bdc157f705ca61516e599cb416580283d21ec35 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Fri, 27 Feb 2015 04:21:48 +0100 Subject: more cast cleanup (bzr r13922.1.11) --- src/path-chemistry.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/path-chemistry.cpp') diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp index 53ad96596..b128535bc 100644 --- a/src/path-chemistry.cpp +++ b/src/path-chemistry.cpp @@ -48,7 +48,7 @@ using Inkscape::DocumentUndo; inline bool less_than_items(SPItem const *first, SPItem const *second) { return sp_repr_compare_position(first->getRepr(), - second->getRepr())>0; + second->getRepr())<0; } void @@ -615,7 +615,7 @@ sp_selected_path_reverse(SPDesktop *desktop) for (std::vector::const_iterator i = items.begin(); i != items.end(); i++){ - SPPath *path = dynamic_cast(static_cast(*i)); + SPPath *path = dynamic_cast(*i); if (!path) { continue; } -- cgit v1.2.3 From 60bdd590969d1c32c392a8fed15f4ceac4a678d2 Mon Sep 17 00:00:00 2001 From: Marc Jeanmougin Date: Mon, 27 Apr 2015 01:12:03 +0200 Subject: Just reread the entire diff against trunk. Given the diff size, i must have forgotten things, but hopefully, there are only very few changes of semantics: ->childList is now in the intuitive order (childList()[0] is now firstChild) -> sp_selection_paste_impl is now in the opposite order (change is local to selection-chemistry.cpp, and simplify a few things) -> selection.setReprList now takes the list in the opposite order. It was always the case (the list was always reversed before handing to it) -> a few comparison functions now work "the c++ way": the C way was to return -1 if ab, now they return (bool)(asetAttribute("id", id); - reprs.insert(reprs.begin(),repr); + reprs.push_back(repr); Inkscape::GC::release(repr); } -- cgit v1.2.3