From 5fee6608eaaf72bdfdf021c5d3197d5d33294765 Mon Sep 17 00:00:00 2001 From: Ajinkya Dahale Date: Wed, 8 Mar 2023 19:49:45 +0530 Subject: [PATCH] [Sketcher] Disable degree setting in B-spline by interpolation This commit is part of a project funded by the Open Toolchain Foundation under the title "Open Toolchain Foundation - Curve drawing tool in Sketcher Workbench" --- .../DrawSketchHandlerBSplineByInterpolation.h | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/Mod/Sketcher/Gui/DrawSketchHandlerBSplineByInterpolation.h b/src/Mod/Sketcher/Gui/DrawSketchHandlerBSplineByInterpolation.h index 6bbb99c037..bab9e615db 100644 --- a/src/Mod/Sketcher/Gui/DrawSketchHandlerBSplineByInterpolation.h +++ b/src/Mod/Sketcher/Gui/DrawSketchHandlerBSplineByInterpolation.h @@ -199,17 +199,17 @@ public: void registerPressedKey(bool pressed, int key) override { - if (SoKeyboardEvent::D == key && pressed) { - SplineDegree = QInputDialog::getInt( - Gui::getMainWindow(), - QObject::tr("B-Spline Degree"), - QObject::tr("NOTE: For construction by interpolation, this degree is ignored for now.\n" - "Define B-Spline Degree, between 1 and %1:") - .arg(QString::number(Geom_BSplineCurve::MaxDegree())), - SplineDegree, 1, Geom_BSplineCurve::MaxDegree(), 1); - // FIXME: Pressing Esc here also finishes the B-Spline creation. - // The user may only want to exit the dialog. - } + // if (SoKeyboardEvent::D == key && pressed) { + // SplineDegree = QInputDialog::getInt( + // Gui::getMainWindow(), + // QObject::tr("B-Spline Degree"), + // QObject::tr("NOTE: For construction by interpolation, this degree is ignored for now.\n" + // "Define B-Spline Degree, between 1 and %1:") + // .arg(QString::number(Geom_BSplineCurve::MaxDegree())), + // SplineDegree, 1, Geom_BSplineCurve::MaxDegree(), 1); + // // FIXME: Pressing Esc here also finishes the B-Spline creation. + // // The user may only want to exit the dialog. + // } if (SoKeyboardEvent::M == key && pressed) { // TODO: On pressing, say, M, modify the knot's multiplicity if (BSplineMults.size() > 1) {