Commit Graph

2606 Commits

Author SHA1 Message Date
Alfredo Monclus
003e239daf feat(PD): set the proper angle for threads and countersinks
apply the recommended thread angle only if the user hasn't set an angle
2024-12-20 07:51:34 -03:00
Alfredo Monclus
ce91285e4d feat(PD): BSF threads 2024-12-20 07:51:34 -03:00
Alfredo Monclus
edb565046d feat(PD): BSW threads 2024-12-20 07:51:34 -03:00
Alfredo Monclus
80d4185c09 refactor(PD): new cut profile for threads
fixes tapered threds
removing 2 points increases performance around 10% when doing an M1 in my imprecise testing
2024-12-20 07:51:33 -03:00
Alfredo Monclus
3e161f9c96 refactor(PD): change tabs to whitespaces 2024-12-20 07:51:33 -03:00
Alfredo Monclus
df22f8060d feat(PD): tapered threads support, NPT and BSPT are now possible 2024-12-20 07:51:33 -03:00
Alfredo Monclus
588f4c3b00 feat(PD): ANSI pipe threads 2024-12-20 07:51:33 -03:00
Alfredo Monclus
acf04c7f1e feat(PD): BSP - British standard pipe threads 2024-12-20 07:51:33 -03:00
Alfredo Monclus
db1b0c56bf fix(PD): complete ISO-273 2024-12-20 07:51:33 -03:00
Florian Foinant-Willig
e607b5757e PartDesign: Add Std_ToggleFreeze to context menu 2024-12-16 11:47:52 -05:00
Chris Hennes
8d110b3b0b Merge pull request #18354 from CalligaroV/pd-hole-restore-missing-refineShapeIfActive
[PartDesign] Hole: restore missing call to FeatureAddSub::refineShapeIfActive()
2024-12-16 11:41:50 -05:00
PaddleStroke
fa8b273f7d Merge branch 'main' into core_LCS3 2024-12-13 18:48:35 +01:00
wmayer
00f6fbeaa3 PD: Fix possible crash in up to shape 2024-12-13 12:15:49 -05:00
PaddleStroke
5d02008227 Remove PartDesign Datums commands from the UI. 2024-12-13 18:04:10 +01:00
PaddleStroke
c5fbbb3830 SubShapeBinder: Add support for point. 2024-12-13 18:04:10 +01:00
PaddleStroke
9504b7e569 PartDesign: Enable the use of the core datums as references. 2024-12-13 18:04:10 +01:00
PaddleStroke
48dbdacdbd Part: add datum objects and commands to create them. 2024-12-13 18:04:10 +01:00
PaddleStroke
fc56730648 Core: Datums: Fix axis placement and add migration script. 2024-12-13 18:04:10 +01:00
Florian Foinant-Willig
c4528eb3a5 PartDesign: fix helix with negative angle 2024-12-13 11:41:55 -05:00
Kacper Donat
d1f706050d TopoNaming: Refine - mark joined faces as modified not generated
This is parity change with LS3: a9810d509a/src/Mod/Part/App/TopoShapeEx.cpp (L3357)
2024-12-13 11:41:29 -05:00
Snow Faerie
8bc062b6e8 Fix and add menu accelerators (#15532)
* Fix and add menu accelerators: menus common to all workbenches

I use menu accelerators fairly often, so I find it very frustrating when
they are missing, or worse, they don't work due to the same letter being
assigned to several commands.

This patch adds accelerators to lots of menu entries missing them and
fixes broken accelerators.

Wherever possible, standard accelerator keys are used:
https://doc.qt.io/qt-5/accelerators.html

This commit covers accelerator fixes that are common to all workbenches.
Accelerator fixes for specific workbenches will be done in separate
commits.

* Add missing accelerators: Spreadsheet workbench
2024-12-13 10:39:30 -06:00
Jacob Oursland
16ac5f9977 PartDesign: Fix failing TNP test. 2024-12-09 17:27:28 -05:00
Chris Hennes
fde778faeb Merge pull request #18273 from Ondsel-Development/sk_group_drag
Sketcher: Group dragging
2024-12-09 12:29:49 -05:00
bgbsww
5266a3b26d Toponaming: Add a plane matching based heuristic to TNP mitigation (#16803)
* Add a plane matching based heuristic to TNP mitigation

* Improve comments, add test
2024-12-09 11:06:02 -06:00
Jonas Bähr
e89fb4a92c PD: Fix error "duplicate command PartDesign_InvoluteGear"
Every time the InvoluteGearFeature python module was imported, and we're
in GUI context, the command "PartDesign_InvoluteGear" was registered. On
the 2nd (3rd, ...) time, this was reported as an error in the console,
like "error: Command.cpp(1841): duplicate command PartDesign_InvoluteGear"

The first import happens when the PartDesign FreeCAD Module is loaded,
via `InitGui.py`. Subsequent imports may happen when e.g. executing the
involute gear command or when running it's tests via FC's Test WB.

This change now registers the command only then the PartDesign WB is set
up in InitGui, not when importing the python module. The same fix is
applied for sprocket, where the same pattern for command registration
was used.

In addition, the import error catch was removed, which seems to be a copy
paste left-over from the ShaftWizard. In contrast to ShaftWizard,
involute gear and sprocket only use modules from the Python standard lib,
so I think this precaution is not worth the additional complexity, just
for hiding actual errors.
2024-12-09 11:53:23 -05:00
Florian Foinant-Willig
669f108fab fix testGiantHelix* 2024-12-09 17:52:02 +01:00
Alexey Chernov
66e1c0154d Require read-only and output attributes on updated properties
Require the property to be both read-only and output for it to be
updated back from support to binder when calculated with expression in
support.
2024-12-08 15:12:38 -05:00
Alexey Chernov
4db7cd52e6 Use lambda to prevent code duplication 2024-12-08 15:12:38 -05:00
Alexey Chernov
2501296c95 Apply result of copy on change properties
Copy on change properties propagated to SubShapeBinder can be changed
there and then updated in the base body (support). On the other hand,
they might be used in calculation of some other properties in the base
body which could also be copy on change and propagated to the same
SubShapeBinder. It looks natural that these latter properties should be
updated with the calculation results as well.

Example:
Body has copy on change properties A = 200 mm and B = 3 * A = 600 mm.
SubShapeBinder with support of Body has A changed to 300 mm and expects
B = 3 * 300 mm = 900 mm. Without this change B is not updated and equals
to 600 mm in SubShapeBinder as well.
2024-12-08 15:12:38 -05:00
Vincenzo Calligaro
fe7bff5a9a [PartDesign] Hole: restore missing call to FeatureAddSub::refineShapeIfActive()
Signed-off-by: Vincenzo Calligaro <vincenzo.calligaro@gmail.com>
2024-12-07 15:23:44 +01:00
Kacper Donat
651cefde4d Gui: Use getObject<T>() helpers in classes
This commit is generated using regex based find and replace:

```
s/[\w:]+_cast\s*<([^>]+)\*>\s*\(\s*getObject\(\s*\)\)/getObject<$1>/
s/[\w:]+_cast\s*<([^>]+)\*>\s*\(\s*([^)]*)\s*->\s*getObject\(\s*\)\)/$2->getObject<$1>()/
```

To regenerate if needed.
2024-12-06 18:29:39 +01:00
Kacper Donat
deb15a57e4 Gui: Add getObject<T>() helpers to various classes
Obtaining specific kind of document object is very common task. This
commit introduces handy helper which makes that a lot easier.
2024-12-06 18:19:53 +01:00
Chris Hennes
b87bdc1f84 Merge pull request #18126 from Ondsel-Development/core_LCS2
Core datums : Card2 : Core implementation
2024-12-06 12:12:04 -05:00
Nicola Cerone
571018807e Gui: Added SendToPythonConsole item in PartDesign tree view right-click menu. 2024-12-06 11:46:46 -05:00
PaddleStroke
4a80af74f4 PartDesign: revert c09ef94 and a3c4f4b to fix https://github.com/FreeCAD/FreeCAD/issues/17949 2024-12-06 11:36:51 -05:00
PaddleStroke
b92bda03da Sketcher: Rename movePoint to moveGeometries. 2024-12-06 16:45:47 +01:00
luzpaz
96c838f3b9 Fix various typos
Found with codespell
2024-12-04 23:18:00 -05:00
Ajinkya Dahale
ca989f73a2 [PartDesign] Fix TestTopologicalNamingProblem
Issue caused by refactor of `SketchObject::trim()`.
2024-12-04 00:57:40 +05:30
Florian Foinant-Willig
70184ba59d PartDesign: decouple refine and other geometric computation (#17008) 2024-12-02 10:57:30 -06:00
PaddleStroke
374c5713b2 PartDesign: Fix newSketch not working when editing a body from an external file. 2024-11-29 12:00:41 -05:00
wmayer
601637320d PD: Add test case to show the fix for the crash with active objects 2024-11-28 17:15:39 +01:00
wmayer
92e96839c9 PD: Avoid touching the document when opening pad or pocket dialog 2024-11-28 17:11:42 +01:00
PaddleStroke
b7f1a0c150 ViewProviderOrigin: Renamed to ViewProviderCoordinateSystem 2024-11-27 12:15:53 +01:00
PaddleStroke
19702dcb21 Core: Add App::LocalCoordinateSystem.
Most of App::Origin is moved into this sub class of App::Origin.
Add App::Point. Change graphics of the planes/axis.
Remove scale-by-content behavior and make it fixed size on screen.
2024-11-26 17:36:02 +01:00
PaddleStroke
aa2e4ca1cb Rename ViewProviderOriginFeature to ViewProviderDatum 2024-11-26 15:36:48 +01:00
PaddleStroke
3e33cf61e5 Rename 'OriginFeature' to 'DatumElement' 2024-11-26 15:36:48 +01:00
PaddleStroke
3c1358da10 Core: Rename 'OriginFeature' file to 'Datums' 2024-11-26 15:36:48 +01:00
wmayer
28282e6800 PD: Cleanup code of TaskRevolutionParameters 2024-11-22 11:59:21 -05:00
mwganson
d8286158b0 [PartDesign] change claimChildren() function to include all profile objects except for other Part Design features 2024-11-22 11:51:30 -05:00
wmayer
aea09d4a45 MSVC: Fix compiler warnings 2024-11-22 16:53:00 +01:00