diff options
| author | Jabier Arraiza Cenoz <jabier.arraiza@marker.es> | 2015-04-02 23:46:44 +0000 |
|---|---|---|
| committer | Jabiertxof <jtx@jtx.marker.es> | 2015-04-02 23:46:44 +0000 |
| commit | 323fc5ae45fd8374de4561d0771f6b9d5cd3e87a (patch) | |
| tree | b79bfbdf24df455572eed37aa5afc27b8dac4b1e /src/helper | |
| parent | add move knots when move nodes pointed by su_v (diff) | |
| download | inkscape-323fc5ae45fd8374de4561d0771f6b9d5cd3e87a.tar.gz inkscape-323fc5ae45fd8374de4561d0771f6b9d5cd3e87a.zip | |
Adding suport for duplicate nodes
Allow degenrate curves
Show helper path whith original path
(bzr r13645.1.70)
Diffstat (limited to 'src/helper')
| -rw-r--r-- | src/helper/geom-pointwise.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/helper/geom-pointwise.cpp b/src/helper/geom-pointwise.cpp index cfe93311c..261d2bff4 100644 --- a/src/helper/geom-pointwise.cpp +++ b/src/helper/geom-pointwise.cpp @@ -123,28 +123,26 @@ void Pointwise::pwd2Append(Piecewise<D2<SBasis> > A) size_t new_subpath_index = _path_info.subPathIndex(i); _path_info.setPwd2(_pwd2); bool subpath_is_changed = false; + bool not_exist = ; if (_pwd2.size() <= i - counter) { subpath_is_changed = false; } else { subpath_is_changed = new_subpath_index != _path_info.subPathIndex(i - counter); } - if (!reorder && first == i - counter && - !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001) && - !subpath_is_changed) { + if (!reorder && first == i - counter && !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001) && !subpath_is_changed) { //Send the modified subpath to back subpathToBack(_path_info.subPathIndex(first)); reorder = true; i--; continue; } - if (!reversed && first == i - counter && - !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001) && - !subpath_is_changed) { + if (!reversed && first == i - counter && !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001) && !subpath_is_changed) { subpathReverse(first, last); reversed = true; } - if (_pwd2.size() <= i - counter || - !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001)) { + if (_pwd2.size() <= i - counter || !are_near(_pwd2[i - counter].at0(), A[i].at0(), 0.001) || + /*this condition for duplicate node Shift+d*/(i > 0 && are_near(A[i - 1].at0(), A[i].at0(), 0.001) && + !are_near(_pwd2[i - counter].at0(), _pwd2[i - counter - 1].at0(), 0.001))){ counter++; bool active = true; bool hidden = false; |
