diff --git a/src/Mod/Sketcher/App/SketchObject.cpp b/src/Mod/Sketcher/App/SketchObject.cpp index a134403d03..6eeac89950 100644 --- a/src/Mod/Sketcher/App/SketchObject.cpp +++ b/src/Mod/Sketcher/App/SketchObject.cpp @@ -11438,6 +11438,17 @@ Data::IndexedName SketchObject::checkSubName(const char *subname) const{ int posId = static_cast(PointPos::none); if ((iss >> sep >> posId) && sep == 'v') { int idx = getVertexIndexGeoPos(geoId, static_cast(posId)); + + // Outside edit-mode circles exposes the seam point but not the center, while in edit-mode we expose the center but not the seam. + // getVertexIndexGeoPos searching for a circle start point (g1v1 for example) (which happens outside of edit mode) will fail. + // see https://github.com/FreeCAD/FreeCAD/issues/25089 + // The following fix works because circles have always 1 vertex, whether in or out of edit mode. + if (idx < 0 && (static_cast(posId) == PointPos::start || static_cast(posId) == PointPos::end)) { + if (geo->is() || geo->is()) { + idx = getVertexIndexGeoPos(geoId, PointPos::mid); + } + } + if (idx < 0) { FC_ERR("invalid subname " << subname); return Data::IndexedName();