summaryrefslogtreecommitdiffstats
path: root/src/path-chemistry.cpp
diff options
context:
space:
mode:
authorJabier Arraiza Cenoz <jabier.arraiza@marker.es>2016-10-03 20:51:05 +0000
committerjabiertxof <info@marker.es>2016-10-03 20:51:05 +0000
commit4db35e8a6706ddece9e977e5f26d4a6867ff8cbe (patch)
treef9711f260f694d96e26bf3216fb64f2b38611b2b /src/path-chemistry.cpp
parentupdate to trunk (diff)
parentMerge in jabiertxof's hover information for measure tool (diff)
downloadinkscape-4db35e8a6706ddece9e977e5f26d4a6867ff8cbe.tar.gz
inkscape-4db35e8a6706ddece9e977e5f26d4a6867ff8cbe.zip
Update to trunk
(bzr r15017.1.35)
Diffstat (limited to 'src/path-chemistry.cpp')
-rw-r--r--src/path-chemistry.cpp17
1 files changed, 7 insertions, 10 deletions
diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp
index 1a345b565..5295b7a70 100644
--- a/src/path-chemistry.cpp
+++ b/src/path-chemistry.cpp
@@ -15,15 +15,13 @@
*/
#ifdef HAVE_CONFIG_H
-# include <config.h>
+#include <config.h>
#endif
#include <cstring>
#include <string>
#include "xml/repr.h"
#include "svg/svg.h"
#include "display/curve.h"
-#include "color.h"
-#include <glib.h>
#include <glibmm/i18n.h>
#include "sp-path.h"
#include "sp-text.h"
@@ -37,7 +35,6 @@
#include "selection.h"
#include "box3d.h"
-#include <2geom/pathvector.h>
#include "selection-chemistry.h"
#include "path-chemistry.h"
#include "verbs.h"
@@ -57,7 +54,7 @@ sp_selected_path_combine(SPDesktop *desktop, bool skip_undo)
Inkscape::Selection *selection = desktop->getSelection();
SPDocument *doc = desktop->getDocument();
- std::vector<SPItem*> items(selection->itemList());
+ std::vector<SPItem*> items(selection->items().begin(), selection->items().end());
if (items.size() < 1) {
desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select <b>object(s)</b> to combine."));
@@ -203,7 +200,7 @@ sp_selected_path_break_apart(SPDesktop *desktop, bool skip_undo)
bool did = false;
- std::vector<SPItem*> itemlist(selection->itemList());
+ std::vector<SPItem*> itemlist(selection->items().begin(), selection->items().end());
for (std::vector<SPItem*>::const_iterator i = itemlist.begin(); i != itemlist.end(); ++i){
SPItem *item = *i;
@@ -303,7 +300,7 @@ sp_selected_path_to_curves(Inkscape::Selection *selection, SPDesktop *desktop, b
desktop->setWaitingCursor();
}
- std::vector<SPItem*> selected(selection->itemList());
+ std::vector<SPItem*> selected(selection->items().begin(), selection->items().end());
std::vector<Inkscape::XML::Node*> to_select;
selection->clear();
std::vector<SPItem*> items(selected);
@@ -334,7 +331,7 @@ void sp_selected_to_lpeitems(SPDesktop *desktop)
return;
}
- std::vector<SPItem*> selected(selection->itemList());
+ std::vector<SPItem*> selected(selection->items().begin(), selection->items().end());
std::vector<Inkscape::XML::Node*> to_select;
selection->clear();
std::vector<SPItem*> items(selected);
@@ -603,7 +600,7 @@ void
sp_selected_path_reverse(SPDesktop *desktop)
{
Inkscape::Selection *selection = desktop->getSelection();
- std::vector<SPItem*> items = selection->itemList();
+ auto items = selection->items();
if (items.empty()) {
desktop->getMessageStack()->flash(Inkscape::WARNING_MESSAGE, _("Select <b>path(s)</b> to reverse."));
@@ -617,7 +614,7 @@ sp_selected_path_reverse(SPDesktop *desktop)
bool did = false;
desktop->messageStack()->flash(Inkscape::IMMEDIATE_MESSAGE, _("Reversing paths..."));
- for (std::vector<SPItem*>::const_iterator i = items.begin(); i != items.end(); ++i){
+ for (auto i = items.begin(); i != items.end(); ++i){
SPPath *path = dynamic_cast<SPPath *>(*i);
if (!path) {