diff options
| author | Johan B. C. Engelen <jbc.engelen@swissonline.ch> | 2014-11-25 21:10:16 +0000 |
|---|---|---|
| committer | Johan B. C. Engelen <j.b.c.engelen@alumnus.utwente.nl> | 2014-11-25 21:10:16 +0000 |
| commit | 9bbf7d5063006d3c81b7acee6d37fe30ecc67bda (patch) | |
| tree | 05963176530472b77bc15a3fda3be35d3d133b44 /src/selection-chemistry.cpp | |
| parent | Fix applying LPE to clones (through the "+" button in the LPE dialog). (diff) | |
| download | inkscape-9bbf7d5063006d3c81b7acee6d37fe30ecc67bda.tar.gz inkscape-9bbf7d5063006d3c81b7acee6d37fe30ecc67bda.zip | |
More C++ string usage.
(bzr r13762)
Diffstat (limited to 'src/selection-chemistry.cpp')
| -rw-r--r-- | src/selection-chemistry.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/selection-chemistry.cpp b/src/selection-chemistry.cpp index ca39ca4c7..bedce4e94 100644 --- a/src/selection-chemistry.cpp +++ b/src/selection-chemistry.cpp @@ -2910,7 +2910,7 @@ void sp_selection_clone_original_path_lpe(SPDesktop *desktop) lpe_repr->setAttribute("linkedpaths", os.str().c_str()); desktop->doc()->getDefs()->getRepr()->addChild(lpe_repr, NULL); // adds to <defs> and assigns the 'id' attribute } - const gchar * lpe_id = lpe_repr->attribute("id"); + std::string lpe_id_href = '#' + lpe_repr->attribute("id"); Inkscape::GC::release(lpe_repr); // create the new path @@ -2922,9 +2922,7 @@ void sp_selection_clone_original_path_lpe(SPDesktop *desktop) SPObject *clone_obj = desktop->doc()->getObjectById(clone->attribute("id")); SPLPEItem *clone_lpeitem = dynamic_cast<SPLPEItem *>(clone_obj); if (clone_lpeitem) { - gchar *href = g_strdup_printf("#%s", lpe_id); - clone_lpeitem->addPathEffect(href, false); - g_free(href); + clone_lpeitem->addPathEffect(lpe_id_href, false); } } |
