From f8f159c4d3f42e86f7af2fe28a43d20512b2d978 Mon Sep 17 00:00:00 2001 From: Ajinkya Dahale Date: Tue, 27 Feb 2024 14:35:32 +0530 Subject: [PATCH] [Sketcher] Include endpoint-to-endpoint tangency as coincidence Coincidence is implied as part of this particular variety of tangent constraint. --- src/Mod/Sketcher/App/SketchObject.cpp | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/Mod/Sketcher/App/SketchObject.cpp b/src/Mod/Sketcher/App/SketchObject.cpp index ba972818a1..a9f985b851 100644 --- a/src/Mod/Sketcher/App/SketchObject.cpp +++ b/src/Mod/Sketcher/App/SketchObject.cpp @@ -8331,6 +8331,20 @@ void SketchObject::getDirectlyCoincidentPoints(int GeoId, PointPos PosId, PosIdList.push_back((*it)->FirstPos); } } + if ((*it)->Type == Sketcher::Tangent) { + if ((*it)->First == GeoId && (*it)->FirstPos == PosId && + ((*it)->SecondPos == Sketcher::PointPos::start || + (*it)->SecondPos == Sketcher::PointPos::end)) { + GeoIdList.push_back((*it)->Second); + PosIdList.push_back((*it)->SecondPos); + } + if ((*it)->Second == GeoId && (*it)->SecondPos == PosId && + ((*it)->FirstPos == Sketcher::PointPos::start || + (*it)->FirstPos == Sketcher::PointPos::end)) { + GeoIdList.push_back((*it)->First); + PosIdList.push_back((*it)->FirstPos); + } + } } if (GeoIdList.size() == 1) { GeoIdList.clear();