diff options
| author | Jabier Arraiza <jabier.arraiza@marker.es> | 2017-12-07 14:45:26 +0000 |
|---|---|---|
| committer | Jabier Arraiza <jabier.arraiza@marker.es> | 2017-12-14 22:11:55 +0000 |
| commit | aeb9391d258b5f76c64333633286abf841d508c5 (patch) | |
| tree | c07e602458d0065b5c6316824e618b1a4dd15f55 /src | |
| parent | This commit: (diff) | |
| download | inkscape-aeb9391d258b5f76c64333633286abf841d508c5.tar.gz inkscape-aeb9391d258b5f76c64333633286abf841d508c5.zip | |
Make optional convert clone to path by a prefs option
Diffstat (limited to 'src')
| -rw-r--r-- | src/path-chemistry.cpp | 15 | ||||
| -rw-r--r-- | src/ui/dialog/inkscape-preferences.cpp | 5 | ||||
| -rw-r--r-- | src/ui/dialog/inkscape-preferences.h | 1 |
3 files changed, 18 insertions, 3 deletions
diff --git a/src/path-chemistry.cpp b/src/path-chemistry.cpp index 9ad6c8c76..d87dd96cd 100644 --- a/src/path-chemistry.cpp +++ b/src/path-chemistry.cpp @@ -55,7 +55,10 @@ ObjectSet::combine(bool skip_undo) { //Inkscape::Selection *selection = desktop->getSelection(); SPDocument *doc = document(); - unlinkRecursive(true); + Inkscape::Preferences *prefs = Inkscape::Preferences::get(); + if (prefs->getBool("/options/pathoperationsunlink/value", true)) { + unlinkRecursive(true); + } std::vector<SPItem*> items_copy(items().begin(), items().end()); if (items_copy.size() < 1) { @@ -306,7 +309,10 @@ void ObjectSet::toCurves(bool skip_undo) // set "busy" cursor desktop()->setWaitingCursor(); } - unlinkRecursive(true); + Inkscape::Preferences *prefs = Inkscape::Preferences::get(); + if (prefs->getBool("/options/pathoperationsunlink/value", true)) { + unlinkRecursive(true); + } std::vector<SPItem*> selected(items().begin(), items().end()); std::vector<Inkscape::XML::Node*> to_select; clear(); @@ -337,7 +343,10 @@ void ObjectSet::toLPEItems() if (isEmpty()) { return; } - unlinkRecursive(true); + Inkscape::Preferences *prefs = Inkscape::Preferences::get(); + if (prefs->getBool("/options/pathoperationsunlink/value", true)) { + unlinkRecursive(true); + } std::vector<SPItem*> selected(items().begin(), items().end()); std::vector<Inkscape::XML::Node*> to_select; clear(); diff --git a/src/ui/dialog/inkscape-preferences.cpp b/src/ui/dialog/inkscape-preferences.cpp index b2d4c5837..803dede7e 100644 --- a/src/ui/dialog/inkscape-preferences.cpp +++ b/src/ui/dialog/inkscape-preferences.cpp @@ -1394,6 +1394,11 @@ void InkscapePreferences::initPageBehavior() _page_clones.add_line(true, "", _clone_relink_on_duplicate, "", _("When duplicating a selection containing both a clone and its original (possibly in groups), relink the duplicated clone to the duplicated original instead of the old original")); + _page_clones.add_group_header( _("Unlinking clones")); + _clone_to_curves.init ( _("Paths operations unlink clones"), "/options/pathoperationsunlink/value", true); + _page_clones.add_line(true, "", _clone_to_curves, "", + _("This paths operations unlink clones: stroke to path, boolops operations, to curves, combine")); + //TRANSLATORS: Heading for the Inkscape Preferences "Clones" Page this->AddPage(_page_clones, _("Clones"), iter_behavior, PREFS_PAGE_BEHAVIOR_CLONES); diff --git a/src/ui/dialog/inkscape-preferences.h b/src/ui/dialog/inkscape-preferences.h index a197a8e65..58e61470c 100644 --- a/src/ui/dialog/inkscape-preferences.h +++ b/src/ui/dialog/inkscape-preferences.h @@ -272,6 +272,7 @@ protected: UI::Widget::PrefRadioButton _clone_option_unlink; UI::Widget::PrefRadioButton _clone_option_delete; UI::Widget::PrefCheckButton _clone_relink_on_duplicate; + UI::Widget::PrefCheckButton _clone_to_curves; UI::Widget::PrefCheckButton _mask_mask_on_top; UI::Widget::PrefCheckButton _mask_mask_remove; |
