Commit Graph

41450 Commits

Author SHA1 Message Date
tetektoza
ce1ca376f1 Gui: Fix stack-use-after-return in DlgSettingsLightSources lambdas
Randomly discovered during some other bug hunt, only with
AddressSanitizer on. Basically, ASAN detected stack-use-after-return
when playing with spinboxes in the Light Sources preferences when Qt
signal handlers tried to invoke lambda callbacks that referenced
deallocated stack memory.

The main problem is that those lambda functions in the constructor
were captruing by reference. When they were connected to Qt signals
and invoked after constructor completed, they accessed stack vars that
have gone out of scope.

So fixed that by changing lambda captures from `[&]` to explicit captures:
- [this] for lambdas needing only class member access
- [this, updateLight] for lambdas that need both class members and the
`updateLight` lambda.
2025-10-19 22:23:36 +02:00
theo-vt
63080eef8e Quickmeasure: Allow measuring the length of a parabola 2025-10-19 12:31:47 -05:00
Furgo
5c5f1d743f BIM: Fix widget value setting in ArchMaterial (#24710)
ArchMaterial's view provider has a setTaskValue helper to set values of widgets inside a task panel. While specific to ArchMaterial, the real place where the helper is called is at BIM_Classification. It appears it's not a general but more like an ad-hoc API for a specific purpose and for a specific object.

In any case, this fix allows widgets that expect a numerical value to have their value set. Before, their value was set as text, unexpectedly.
2025-10-19 09:13:51 +00:00
sliptonic
dbd6e98fed Merge pull request #24725 from davidgilkaufman/adaptive_model_aware_checkbox
[CAM] fix bug opening job ui panel
2025-10-18 10:07:23 -05:00
paul
c8162b34cd [ArchStairs] Fix StringerOverlap & StructureOffset (#24608)
1. Fix #24321
2. Fix - The 'Structure Offset' property does not allow to insert negative values

(Forum Discussion
- https://forum.freecad.org/viewtopic.php?t=100060 contains discussion on the above 2 issues)
2025-10-18 14:44:21 +00:00
Furgo
994990c283 BIM: Prevent editing label on double-click (#24712)
Before this fix, double-clicking on an ArchMultimaterial object opened its task panel as expected. Unexpectedly, its label was selected and set for edit.

- The tree view's double-click handling expects the view-provider to declare whether it handled the double-click.
- The ViewProvider API's doubleClicked() is documented to return bool (True if handled).
- If a view provider's doubleClicked method returns None/False, the tree falls back to the default Qt behavior (which is beginning inline editing of the item label).
- In ArchMaterial.py the view provider calls self.edit() (or FreeCADGui.ActiveDocument.setEdit(...)) but the method that the tree actually calls (the view provider's doubleClicked) does not return True. Because the method returns None, the tree continues and starts inline label-editing.

In summary: setEdit returning True is fine, but doubleClicked is the method the tree checks; it must return True to suppress the default inline rename.
2025-10-18 15:34:10 +02:00
ebswift
c34e4c5fcd Fix compilation error in TaskFeatureParameters.cpp 2025-10-17 22:35:44 -05:00
theo-vt
ab035c4586 Measure: allow length measurement for ellipse, hyperbola and parabola (#24659) 2025-10-17 21:34:07 +00:00
Chris
ba036d2be4 PD: Fix uninfomative error message box (#24705) 2025-10-17 19:48:31 +00:00
David Kaufman
dcca69383e fix bug opening job ui panel 2025-10-17 15:08:10 -04:00
sliptonic
ee42b453f6 remove old supplemental fixture 2025-10-17 12:10:22 -05:00
David Kaufman
0335d06311 [CAM] make the adaptive model aware feature optional (#24553)
* [CAM] make the adaptive model aware feature optional

* fix CAM tests

* placate github codql

* remove model-aware-only properties from the adaptive task ui panel
2025-10-17 10:42:15 -05:00
sliptonic
6abf3993b0 Merge pull request #24661 from tarman3/icon
CAM: Fix icon while changing Active state for class ObjectOp
2025-10-17 10:41:20 -05:00
sliptonic
4acd1e3b8e Merge pull request #24606 from tarman3/toggle
CAM: Toggle Operation improve
2025-10-17 10:41:00 -05:00
sliptonic
051c5c3456 Merge pull request #24674 from Connor9220/EmbeddedToolMigrationFix
CAM: Fix embedded toolbits showing up as custom.
2025-10-17 10:40:40 -05:00
Chris Hennes
d51afd67de Addon Manager: Synchronize with 2025.10.16 version 2025-10-17 05:25:19 +02:00
Furgo
f1b8c0dba3 BIM: replace obsolete urllib2 in BimTutorial 2025-10-16 21:21:40 +02:00
Furgo
01e87a2072 BIM: remove obsolete Python 2 urllib2 import
Python 3 combined the former `urllib`, `urllib2`, `urlparse` Python 2 modules into subpackages of `urllib`. FreeCAD is written in Python 3, thus the `urllib2` import fallback will not work and needs to be removed.
2025-10-16 21:21:40 +02:00
tetektoza
e74cd082ca Gui: Restore focus to tree upon deletion and move selection to next obj (#24679) 2025-10-16 13:13:08 -05:00
PaddleStroke
cfe4180dae Sketcher: Fix ctrlA with filter vertex index issue (#24665)
* Sketcher: Fix ctrlA with filter vertex index issue

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-16 13:01:30 -05:00
Chris Hennes
c1af83fb54 Merge pull request #24692 from Roy-043/BIM-improve-MultiMaterial-task-panel
BIM: improve MultiMaterial task panel
2025-10-16 12:56:20 -05:00
captain0xff
36573bf817 Gui: fix null handling logic in Application::setEditDocument 2025-10-16 12:54:20 -05:00
Furgo
c78b8930ba BIM: add missing DraftGeomUtils import (#24683)
Added import for DraftGeomUtils to ArchCommands.makeFace to prevent crash.
2025-10-16 18:00:32 +02:00
Roy-043
b0f2845ab8 BIM: improve MultiMaterial task panel
Update MultiMaterialColumnWidth values to 120
2025-10-16 15:00:35 +02:00
Roy-043
791e4bdd85 BIM: improve MultiMaterial task panel
Remove extra left margin from the first column in the tree view.
2025-10-16 14:58:59 +02:00
Billy Huddleston
58de49717f Promote embedded toolbits to correct shape type during migration
- Enhance _promote_toolbit to handle embedded toolbits that still have a "Custom" shape type.
- If ShapeType is "Custom" but ShapeID is present, attempt to promote to the correct shape class using ShapeID.
- Log promotion for traceability.
- This improves migration of legacy embedded toolbits and ensures proper shape assignment.
2025-10-15 18:04:40 -04:00
marcuspollio
e831fc9163 Add Draft workbench to .pre-commit-config (#24664)
* Add Draft workbench to .pre-commit-config

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-15 11:21:09 +02:00
tetektoza
f43af65eca BIM: Remove icon after unclone (#24654)
As the title says - upon unclone icon is not being removed, but the
cloned item stops mirroring original item which is correct, so this just
aligns the icon removal logic with the correct behavior.
2025-10-15 10:21:38 +02:00
tarman3
4c3f6fc21f CAM: Fix icon and Active state for class ObjectOp 2025-10-15 07:39:02 +03:00
Chris Hennes
73d9793725 Merge pull request #22696 from schmidtw/assembly-crash-fix
Fix: Prevent attempting to access non-existant nodes.
2025-10-14 10:14:51 -05:00
Kacper Donat
c4dbe7e866 PartDesign: Fix boolean fuse without tools
This fixes issue where exception was thrown when no tools were selected
preventing the task dialog from being opened.
2025-10-14 10:05:24 -05:00
Kacper Donat
4145011938 PartDesign: Ignore errors due to object misconfiguration in previews
This adds ignoring catch to the updatePreview method of
ViewProviderTransformed so it does not report issues that happen because
recompute takes place on object that is not yet fully configured.
2025-10-14 10:04:28 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ
f99a6b3cbf [ Surface ]: Updated SPDX (#24560) 2025-10-14 10:02:53 -05:00
PhoneDroid
d01e8ca47d [ OpenSCAD ]: Updated SPDX 2025-10-14 10:01:41 -05:00
PhoneDroid
2e8a7328fb [ MeshPart ]: Update SPDX 2025-10-14 10:01:02 -05:00
PhoneDroid
c913317c28 [ Base ]: Updated SPDX 2025-10-14 10:00:04 -05:00
Chris Hennes
5227e6765e Merge pull request #23592 from ryankembrey/td-vertices
TechDraw: Fix vertices regressions
2025-10-14 08:26:50 -05:00
PaddleStroke
bec782ce0b Sketcher: Fix deactivated Block bug (#24548)
* Sketcher: Fix deactivated Block bug

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update Sketch.cpp

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-14 11:58:22 +02:00
Pieter Hijma
9f8fd3e078 Gui: Fix supporting links in add property dialog 2025-10-14 11:56:47 +02:00
PaddleStroke
d862324a76 Sketcher: bspline tool: fix error message (#24566)
* Sketcher: bspline tool: fix error message

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-14 11:53:54 +02:00
Roy-043
baef3e6047 Tux: remove obsolete pythonToolbars function 2025-10-14 11:50:19 +02:00
PaddleStroke
a0c28aba75 Assembly: Fix lengths cannot be negative (#24625)
* Assembly: Fix lengths cannot be negative

* Update PropertyUnits.cpp

* Update PropertyUnits.h

* Update JointObject.py
2025-10-14 11:40:10 +02:00
marcuspollio
c55e1c3bba BIM: Prevent crash when removing a wall's base component (#24633)
* BIM: Prevent crash when removing a wall's base component

When a user selected a wall's base object in the Tree View and used the
`Arch_Remove` command, a traceback occurred due to an `AttributeError`.

The `removeComponents` function was incorrectly checking for the `.Base`
attribute on a list of subtractions (`s.Base`) instead of on the parent
host object (`h.Base`).

This commit corrects the reference to check against the parent object,
resolving the crash and allowing the component to be removed.

Fixes: https://github.com/FreeCAD/FreeCAD/issues/24532

Authored-by:  furgo16 <148809153+furgo16@users.noreply.github.com>

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: Furgo <148809153+furgo16@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-14 11:19:43 +02:00
Florian Foinant-Willig
b75b1508d4 Core: fix Std_Placement for multiple objects 2025-10-13 22:54:31 +02:00
PaddleStroke
4b9d1bb4e5 PartDesign: Linear pattern, add checkbox for dir2 (#24378)
* PartDesign: Linear pattern, add checkbox for dir2

* Update PatternParametersWidget.ui

* Update PatternParametersWidget.h

* Update PatternParametersWidget.cpp
2025-10-13 21:34:38 +02:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ
f620d68c19 Removed outdated UTF8 declaration [ Other ] (#24528)
* Removed outdated UTF8 declaration

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-13 18:34:43 +02:00
WandererFan
489e3ca6fc TechDraw: fix leader positioning (snapping) (#24468)
* [TD]specialize leader snap handling

* [TD]fix leader live update regression

* [TD]QGTracker code clean-up
2025-10-13 18:21:31 +02:00
matthiasdanner
54c2470027 Sketcher: Fix Angle Constraint jumping to opposite side on movement (#24150)
* Sketcher: Fix Angle Constraint jumping to opposite side on movement

* implement way to dynamically disable snapping where not needed

---------

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
2025-10-13 18:07:09 +02:00
Chris Hennes
62e9b499d4 Robot: Remove unlicensed files
Users must obtain these files directly from Kuka, no license has been
granted to distribute them.
2025-10-13 18:02:37 +02:00
Florian Foinant-Willig
542856acbd Sketcher: rename DeriVector2::crossProdNorm to DeriVector2::crossProdZ 2025-10-13 17:57:51 +02:00