Compare commits

...

1491 Commits

Author SHA1 Message Date
pre-commit-ci[bot] 25c3ba7338 All: Reformat according to new standard 2025-11-11 13:49:01 +01:00
Kacper Donat eafd18dac0 Part,PartDesign,Gui: Add to pre-commit formatting 2025-11-11 13:45:27 +01:00
Kacper Donat b70b31226b All: Update formatting style 2025-11-11 13:45:27 +01:00
pre-commit-ci[bot] 28a5bcdf8e [pre-commit.ci] pre-commit autoupdate
updates:
- [github.com/psf/black-pre-commit-mirror: fe95161893684893d68b1225356702ca71f8d388 → 2892f1f81088477370d4fbc56545c05d33d2493f](https://github.com/psf/black-pre-commit-mirror/compare/fe95161893684893d68b1225356702ca71f8d388...2892f1f81088477370d4fbc56545c05d33d2493f)
- [github.com/pre-commit/mirrors-clang-format: 719856d56a62953b8d2839fb9e851f25c3cfeef8 → 317810f3c6a0ad3572367dc86cb6e41863e16e08](https://github.com/pre-commit/mirrors-clang-format/compare/719856d56a62953b8d2839fb9e851f25c3cfeef8...317810f3c6a0ad3572367dc86cb6e41863e16e08)
2025-11-11 09:47:59 +01:00
Billy Huddleston ec2a41b86b CAM: Fix ReferenceError when accessing deleted toolbit object
Prevent crash (CAMTests) in ToolBitRecomputeObserver when the toolbit object has been deleted/missing
by catching ReferenceError before accessing its Document attribute. This ensures slotRecomputedDocument
exits gracefully if the object is no longer valid.

src/Mod/CAM/Path/Tool/toolbit/models/base.py
- Wrapped access to self.toolbit_proxy.obj.Document in try/except to handle ReferenceError
if object is deleted/missing, preventing crash during document recompute.
2025-11-10 18:44:02 -06:00
Kacper Donat 5556821e7e Gui: Add special handling for too small overlay side panel
This basically is due to how OverlayTabWidget::setRect is implemented. If it faces width (or
height) of 0 it forces the width to be minimumOverlayWidth * 3, which in the default config
appears to be 90. 90 is obviously way too small of a value to display any widget in the side
panel, so we need to basically need to treat anything smaller or equal to that as an
incorrect value for width. We use here 100 just to be safe.

For the height value of 100 may be reasonable, so we leave it as is.
2025-11-10 18:40:17 -06:00
Chris Hennes 44c73fdd5b Gui: Restore 'Exit' menu text for Linux/Windows
Only macOS appears to set the text based on the menu item's role.
2025-11-11 00:17:00 +01:00
Chris Hennes 80080d9fde Merge pull request #25216 from kadet1090/fix-overlay-task-panel
Gui: Enable Overlay only for new users
2025-11-10 16:46:16 -06:00
pjcreath 280addd21c Gui: Fix crash in placement window after closing a document. (#25110)
Fixes #18156
2025-11-10 11:03:05 -06:00
Chris Hennes 483d0ef6fe Gui: Ensure Quit menu item is QAction::QuitRole 2025-11-10 17:52:31 +01:00
PaddleStroke 0ff0359524 PartDesign: Fix 'UpToShape' not saving correctly 2025-11-10 10:49:50 -06:00
FEA-eng b038f4130c FEM: Add ccx capacitance two spheres example (#25117)
* FEM: Update CMakeLists.txt

* FEM: add new ccx electrostatics example

* FEM: Update equation_electrostatics_capacitance_two_balls.py

* FEM: Update equation_electrostatics_capacitance_two_balls_ccx.py
2025-11-10 10:47:33 -06:00
Billy Huddleston 2d83e86f07 CAM: Improve Z retract reliability in rotational scan after geometry recompute
Introduced FLOAT_EPSILON for robust floating point comparisons, resolving cases
where Z axis retract moves were missing after geometry recompute in 3D Surface
rotational scan operations. This prevents precision errors from causing the
cutter to skip intended lifts between rings or scan lines.

src/Mod/CAM/Path/Op/Surface.py
 - Added FLOAT_EPSILON constant
 - Updated Z move comparison logic to use tolerance
2025-11-10 10:45:58 -06:00
Billy Huddleston 871ab6df64 CAM: Fix infinite recompute loop when ToolBit properties use expressions
A bug in the ToolBit model caused an infinite recompute loop and UI freeze when properties such as Diameter, Flutes, or CuttingEdgeHeight were set to expressions. The visual representation update was being triggered during document recompute, which could recursively trigger further recomputes. This fix defers visual updates by queuing them and processing only after the document recompute completes, using a document observer. The observer is cleaned up after use and on object deletion, preventing memory leaks and repeated recompute cycles.

src/Mod/CAM/Path/Tool/toolbit/models/base.py:
- ToolBitRecomputeObserver: Document observer class that triggers queued visual updates after recompute completes via slotRecomputedDocument.
- _queue_visual_update: Queues a visual update to be processed after document recompute.
- _setup_recompute_observer: Registers the document observer for recompute completion.
- _process_queued_visual_update: Processes the queued visual update and cleans up the observer.
- onChanged: Now queues visual updates instead of calling them directly.
- onDelete: Cleans up any pending document observer before object removal.
2025-11-10 10:43:15 -06:00
neurallambda df7ee72171 Fix CAM job "no attribute Proxy" (#25034) 2025-11-10 10:42:32 -06:00
tarman3 2e37667371 CAM: Slot - Fix references enumeration 2025-11-10 10:41:58 -06:00
marbocub b5b00f7aff Fix legacy mmTangentPlane orientation in 1.1.0dev (resolves #24254) (#24529)
* Add legacy TangentPlane orientation compatibility layer

* Refactor: extract lambda for object identifier construction

* Refactor: axis calculation using std::ranges::max_element and std::distance

* Apply suggestions from code review

Co-authored-by: Pieter Hijma <pieterhijma@users.noreply.github.com>

* Part: Add regression test for issue 24254

---------

Co-authored-by: Pieter Hijma <pieterhijma@users.noreply.github.com>
Co-authored-by: Chris Hennes <chennes@gmail.com>
2025-11-10 10:36:42 -06:00
Kacper Donat f7908335e5 Gui: Make overlay dragger respect palette
This changes Overlay Dragger to not have hardcoded color but instead
respect the palette from theme.
2025-11-10 17:05:25 +01:00
Kacper Donat f43c6906ff Gui: Enable Overlay only for new users
This change tries to detect invalid state where overlay was
half-initialized that resulted in overlay being enabled for more users
that we initially aimed for.
2025-11-10 17:05:25 +01:00
pjcreath 3071cc847c Gui: Fix crash in measuring tool after an undo. (#25129)
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-11-09 20:04:22 -06:00
Steven James 5c464e0746 Fix setting Bool value in VarSet add properties dialog. (#24873)
* Connect Bool checkbox checkStateChanged to the editor callback so changes will actually happen.
Make the change compatible with Qt versions <6.7.0

* Remove delayed singleshot-value changed from the event filter for Checkbox as suggested by @pieterhijma

* Remove no longer relevent comment
2025-11-09 17:45:57 -06:00
theo-vt 484c724ac6 Techdraw: Assign AutoDistribute when creating a projection group (#25103) 2025-11-09 17:41:50 -06:00
tetektoza 6bed2e663e Sketcher: Clear selection on selected geometry when hiding
When a geometry element is selected and then hidden using the visibility
checkbox in the Elements panel, it remains in the selection.
Subsequently, if another geometry element is selected and deleted, both
the visible element AND the hidden element are deleted.

Root cause of that is basically that `changeLayer()` functions change
the geometry's visual layer, but never clear the geometry from
`Gui::Selection()`.

So, this patch adds the handling to collect every sub-element name of
the hidden geometry and then formats it and calls remove selection on
the geometry during layer change transaction.
2025-11-09 17:40:08 -06:00
chris ffea3da872 freecad issue #25069 fix issue with selecting the plot tab / window from the menu bar 2025-11-09 17:20:15 -06:00
Florian Foinant-Willig ee34d09f7a Core: add a check on object deletion 2025-11-09 16:44:40 -06:00
Chris Hennes 948f284472 Merge pull request #25186 from Roy-043/BIM-fix-human-figure
BIM: Fix human figure
2025-11-09 16:36:52 -06:00
pjcreath b92b54de0e Gui: prevent native macOS color picker crash.
Fixes #25153
2025-11-09 16:23:17 -06:00
paul 50d22e2bb7 [ArchStairs] Fix StringerOverlap with Base at Angle (#25167)
* [ArchStairs] Fix StringerOverlap Base at Angle

Github Issue Discussion
- https://github.com/FreeCAD/FreeCAD/issues/24321#issuecomment-3492459309

"... error when Stringer Overlap is set above certain threshold combined with a non-baseless stair which does not have orthogonal direction - this means that the base line or sketch is rotated to a degree, which is not 0, 90, 180 or 270 degrees."

Further
Fix #24321

* [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-11-09 18:59:14 +01:00
Roy-043 071e7f3dfa Remove HumanFigure.brep from Arch.qrc resources 2025-11-09 18:49:00 +01:00
Roy-043 ce0a3dd526 BIM: Fix human figure
Fixes #25084.

Instead of a brep file a point list is now used to generate the figure.

Additionally:
Two points have been added to make the head of the figure less 'pointy'.

It would make sense to move the `get_human_figure` function to a different file in the future.

With 1.7m the figure is not very tall BTW.
2025-11-09 16:49:37 +01:00
marioalexis 9e7b5f6444 Fem: Fix CapacitanceBody default value 2025-11-08 14:15:42 -06:00
Chris Hennes ca5d22ebca Merge pull request #25162 from Rexbas/sketcher-cleanup-grid-icon
Sketcher: Remove unused icons and fix SIGSEGV
2025-11-08 14:13:49 -06:00
Bas Ruigrok 3d0db63193 TechDraw: Fix ignored "Zoom at Cursor" for TouchPad style 2025-11-08 11:37:37 -06:00
Chris Hennes 924dfe29c8 CI: Update Python version to 3.13 in fetch-crowdin (#25149) 2025-11-08 18:23:17 +01:00
Bas Ruigrok d95f56b39b Sketcher: Remove unused rendering order icons 2025-11-08 14:12:33 +01:00
Bas Ruigrok a479197f0b Sketcher: Remove unused snap icons and fix SIGSEGV 2025-11-08 14:08:32 +01:00
Bas Ruigrok c828c5d1d1 Sketcher: Remove unused grid toggle icons and fix SIGSEGV 2025-11-08 13:42:39 +01:00
pjcreath be93298afd Gui: process remaining deferredDelete events before stopping event loop 2025-11-07 13:18:47 +01:00
marioalexis 06131ce8b5 Base: Restore schema spec for electromagnetic potential unit - fix #25093 2025-11-06 15:05:25 +01:00
FEA-eng 66600f9f1f Gui: Fix unreadable Choose Folder button in the macro recording panel 2025-11-06 15:04:04 +01:00
Florian Foinant-Willig 3ae8f3d57a OCC usage: fix deprecated Handle_* 2025-11-06 10:43:52 +01:00
Chris Hennes af41a9dcef Merge pull request #24317 from kpemartin/Issue24314
Update unit test to use new storage for DXF import settings
2025-11-05 14:25:58 -06:00
dependabot[bot] 7ecdb0236b Bump prefix-dev/setup-pixi from 0.9.2 to 0.9.3
Bumps [prefix-dev/setup-pixi](https://github.com/prefix-dev/setup-pixi) from 0.9.2 to 0.9.3.
- [Release notes](https://github.com/prefix-dev/setup-pixi/releases)
- [Commits](https://github.com/prefix-dev/setup-pixi/compare/28eb668aafebd9dede9d97c4ba1cd9989a4d0004...82d477f15f3a381dbcc8adc1206ce643fe110fb7)

---
updated-dependencies:
- dependency-name: prefix-dev/setup-pixi
  dependency-version: 0.9.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-05 13:19:26 -06:00
marioalexis 6c7187b54f Fem: Fix magnetodynamic2D boundary condition 2025-11-05 13:06:53 -06:00
Pieter Hijma 011b6cdfbf Gui: Fix supporting xlinks in add property dialog 2025-11-05 12:49:47 -06:00
Ajinkya Dahale 857190a20a Sketcher: Only transfer equality in specific cases in trim
The transfer on should apply to (arcs of) conics.

Fixes #25008.
2025-11-05 12:48:05 -06:00
wandererfan 37af704998 [TD]fix angle dim in detail view 2025-11-05 12:46:35 -06:00
PhoneDroid f2d60d7abe [ Plot ]: Update SPDX License Identifiers 2025-11-05 12:45:42 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 54948b441d SPDX [ 34 ][ Src / Mod / Points ] (#25073) 2025-11-05 12:44:17 -06:00
PhoneDroid 28d5539fc7 [ Reverse ]: Update SPDX License Identifier 2025-11-05 12:42:10 -06:00
PhoneDroid bde82f19cb [ MacAppBundle ]: Update SPDX License Identifiers 2025-11-05 12:40:53 -06:00
marioalexis 123aee6b1b Fem: Fix CalculiX body heat source writer for 2D case 2025-11-05 12:37:52 -06:00
PhoneDroid 4e9fe02b9a [ Ext ]: Update SPDX License Identifiers 2025-11-05 12:37:18 -06:00
PaddleStroke cb108249f2 Sketcher: Fix offset of open profile (#25091)
* Sketcher: Fix offset of open profile

* [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-11-05 12:35:45 -06:00
dependabot[bot] a8ce12f2b4 Bump step-security/harden-runner from 2.13.1 to 2.13.2
Bumps [step-security/harden-runner](https://github.com/step-security/harden-runner) from 2.13.1 to 2.13.2.
- [Release notes](https://github.com/step-security/harden-runner/releases)
- [Commits](https://github.com/step-security/harden-runner/compare/f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a...95d9a5deda9de15063e7595e9719c11c38c90ae2)

---
updated-dependencies:
- dependency-name: step-security/harden-runner
  dependency-version: 2.13.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-11-05 11:20:34 -06:00
pre-commit-ci[bot] 8ddecd21a1 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-11-05 13:32:09 +00:00
Kevin Martin 520dd7b2b7 Remove test from old location 2025-11-05 08:28:35 -05:00
Kevin Martin 5afe1e64f8 Transplant the test code from the old location
For some reason the app hangs after the test GUI is run
2025-11-05 08:28:34 -05:00
Kevin Martin 2d5bb51734 Add the sample input file 2025-11-05 08:28:34 -05:00
Kevin Martin 44bb16cae7 Enable Python Draft import tests
A failing test was added to Draft tests to ensure CI catches it
2025-11-05 08:28:17 -05:00
Furgo 2d2684cc3d BIM: remove BIM Project command from toolbar (#25086)
- The BIM_Project command is removed from the toolbar and relocated to
  the Utils menu
- The default when creating a new project has been changed to
  non-IFC-native
- The BIM_Project and IFC_MakeProject command menu text have been
  reworded to remove ambiguity
2025-11-05 09:56:46 +01:00
PaddleStroke af014a1bb4 Sketcher: Restore ExprBasedConstrDimColor (#25055)
* Sketcher: Restore ExprBasedConstrDimColor

* [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-11-04 20:07:44 +01:00
Chris Hennes 75151b2987 Addon Manager: Update to 2025-11-04 2025-11-04 20:04:03 +01:00
Chris Hennes 736ffd0140 Merge pull request #25015 from PhoneDroid/SPDX-Src-Mod-Spreadsheet
SPDX [ 33 ][ Src / Mod / Spreadsheet ]
2025-11-03 15:28:46 -06:00
Chris Hennes acb3f4a8f9 Merge pull request #24912 from marioalexis84/fem-elmer_solver 2025-11-03 12:40:06 -06:00
Kacper Donat 54d25bcabc Merge pull request #24904 from tetektoza/fix/23459_fix_locked_ovp_allowing_change_geom
Sketcher: Remember cursor angle for OVPs after OVP is set
2025-11-03 19:25:56 +01:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ f0e70e68e0 [ Draft ]: Update SPDX License Identifiers (#24965) 2025-11-03 11:58:14 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 0df300cee6 [ Import ]: Update SPDX License Identifiers (#24976) 2025-11-03 11:57:57 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ df142c35aa SPDX [ 25 ][ Src / Mod / Material ] (#24979)
* [ Material ]: Update SPDX License Identifiers

* [ Material ]: Correct Test Material License

---------

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-11-03 11:57:40 -06:00
PhoneDroid 00887c4f3a [ Web ]: Update SPDX License Identifiers 2025-11-03 11:57:21 -06:00
PhoneDroid a26610b315 [ Tux ]: Update SPDX License Identifiers 2025-11-03 11:57:14 -06:00
PhoneDroid 5400e01651 [ Start ]: Update SPDX License Identifiers 2025-11-03 11:57:06 -06:00
Adrian Insaurralde Avalos c783f818a8 [weeklies] fix #22989, missing ThirdPartyLibraries.html on windows bundles 2025-11-03 11:48:49 -06:00
Chris Hennes 5ea8399ada Spreadsheet: Correct accidental license change
In formatting commit 5bd5f3a963 a
contributor mistakenly changed the license of importXLSX.py
from LGPL to GPL. The original code contributed by @ulrich1a included an
LGPL license block in it, and that license should have been retained.
This commit changes the license block to the originally-intended LGPL
block, and updates the SPDX header to match.
2025-11-03 11:47:45 -06:00
Chris Hennes 0bc707ad34 CI: Silence expected error message for shallow repo 2025-11-03 14:14:43 -03:00
sliptonic 22309af65c Merge pull request #24732 from tarman3/dressup_icon
CAM: Fix Dressups icon Active state
2025-11-03 11:14:15 -06:00
paul 2c7e0f044b [BimWindow] Fix SymbolPlan position (#25001)
* [BimWindow] Fix SymbolPlan position

Fix #24903

* [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-11-03 18:08:56 +01:00
sliptonic cd5209f264 Merge pull request #25003 from chennes/contributingPRTitle
Project: Revise PR message guidelines for clarity
2025-11-03 10:44:36 -06:00
Chris Hennes 098f19f706 Merge pull request #24890 from mosfet80/upSubmodules
Update git submodules
2025-11-03 07:39:03 -06:00
tetektoza 08e4191e5a Gui: Force Expression Completer to show drop-down upon clicking on item (#25011)
As the title says - currently if user clicks "Box" from the autocomplete
dropdown, it adds "Box.", but the property drop-down is never resolved
further, so user has to delete the separator and write it by hand.

When a completion ends with '.' or '#' and is being selected by
clicking, code sets `block=true` and calls `slotTextChanged()` which
prevents the `textChanged2` signal from being emitted. This results in
completer being blocked from updating next level of properties.

So, this patch adds a direct call to `completer->slotUpdate()`, which
triggers completer to parse the expression and show the drop-down.
2025-11-03 11:11:55 +01:00
Chris Hennes 79412d205b Merge pull request #24970 from maxwxyz/cp_18075 2025-11-02 21:38:58 -06:00
PhoneDroid 27f6c9081c [ Spreadsheet ]: Update SPDX License Identifiers 2025-11-02 21:36:25 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ cdb990e810 [ JtReader ]: Update SPDX License Identifiers (#24977)
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-11-02 16:27:55 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 489e429b5c SPDX [ 29 ][ Src / Tools ] (#24999)
* [ Tools ]: Update SPDX License Identifiers

* [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-11-02 16:21:34 -06:00
PhoneDroid d80cd13d41 [ Part ]: Update SPDX License Identifiers 2025-11-02 16:16:07 -06:00
Joao Matos 41395f2051 Add PartDesign build dependency to Import.
Import now depends on PartDesign, so ensure CMake configure-time
dependency enforcement requires PartDesign alongside Part.

Fixes build regression from
https://github.com/FreeCAD/FreeCAD/commit/6fd6558040bb61cc1a9d35fd360cb1a169276cd3.
2025-11-02 15:59:06 -06:00
Roy-043 08cf89d1c9 Fix path for ContinueMode parameter retrieval 2025-11-02 15:50:26 -06:00
PhoneDroid 90a4f9ecb0 [ Mesh ]: Update SPDX License Identifiers 2025-11-02 15:49:56 -06:00
PhoneDroid 53ba534677 [ Measure ]: Update SPDX License Identifiers 2025-11-02 15:22:11 -06:00
Chris Hennes 8504bc8988 Points: Remove unimplemented CmdPointsTransform 2025-11-02 22:17:01 +01:00
PhoneDroid 69674d706f [ Inspection ]: Update SPDX License Identifiers 2025-11-02 15:06:47 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ ca1a25d6d6 SPDX [ 21 ][ Src / Mod / Assembly ] (#24974)
* [ Assembly ]: Update SPDX License Identifiers

* [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-11-02 15:06:03 -06:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 46909c6fb8 [ IDF ]: Update SPDX License Identifiers (#24967) 2025-11-02 15:05:15 -06:00
PhoneDroid 6a1929a6d6 [ Help ]: Update SPDX License Identifiers 2025-11-02 14:58:06 -06:00
Roy-043 5b872b59a1 BIM/Draft: fix paths related to example files
* My mod (#23284) of CMakeLists.txt did not create the desired subfolder. Therefore the TTF and PAT files have now been put in the main example folder.
* draft_test_objects.FCStd has been update for the new path of the mentioned files.
* BIMExample.FCStd has been updated to use the PAT file from the example folder instead of acad.pat from a local folder.
2025-11-02 14:51:27 -06:00
Chris Hennes fe4a734a9d Merge pull request #24764 from WandererFan/FillTemplate2
[TD]defend against deleted object error
2025-11-02 14:49:34 -06:00
Chris Hennes 4d201c8f0e Merge pull request #24856 from tetektoza/fix/21547_respect_treat_ellipses_opt_in_prefs
Import: Use proper location for DXF prefs
2025-11-02 14:23:35 -06:00
Chris Hennes c8eefab345 Project: Revise PR message guidelines for clarity 2025-11-02 12:53:43 -06:00
Max Wilfinger aeb83b3c05 App: Apply code review suggestions 2025-11-02 17:38:06 +01:00
PaddleStroke 45ca23d074 Update JointObject.py 2025-11-02 17:03:37 +01:00
Leandro Heck e4f36afcb3 Gui: Use system dialogs by default (#24882)
* Fix the selector of the FileDialog and add the same default settings for the ColorDialog.

* Add option to set the default ColorDialog

* Use system dialog by default

* Remove new env var

* Fix the native file dialog selector

* Adjust env variable name

* Adjust env variable name
2025-11-02 16:50:48 +01:00
PaddleStroke 0b2268a921 Sketcher: Constraint rendering (#24534)
* Sketcher: Constraint rendering

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

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

* Update EditModeConstraintCoinManager.h

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

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

* Update EditModeConstraintCoinManager.cpp

* Update SoDatumLabel.cpp

* Update SoDatumLabel.cpp

* Update EditModeConstraintCoinManager.cpp

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

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

* Update EditModeConstraintCoinManager.cpp

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

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

* revert changes drawing the box around fx

* Update EditModeConstraintCoinManager.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-11-02 15:51:14 +01:00
Joao Matos 36d432e2cc Gui: Use C99 _Exit instead of not as portable POSIX _exit.
The actual fix here is for a compile error which started appearing as an
error due to `unistd.h` include being included implicitly from
`boost::signals`, which FastSignals does not do anymore.

```
Error:
/Users/runner/work/FreeCAD/FreeCAD/src/Gui/Dialogs/DlgVersionMigrator.cpp:366:5:
error: use of undeclared identifier '_exit'
```
2025-11-01 21:49:24 +01:00
Chris Hennes c5489e0f0a Gui: Fix allocation of posted ESC event 2025-11-01 21:47:00 +01:00
tetektoza ad2e866332 Gui: Fix window restoration after Edit->Alignment completion
After completing Edit->Alignment, main window remains small instead of
maximized. It looks like this is Qt 6 regression as the automatic
maximization behavior was somehow changed. Previously it didn't need
explicit handling to restore the maximisation.

So, this patch preserves the previous window state before entering
Alignment editor and restores window being maximized/minimized or normal
upon finishing the operation.
2025-11-01 21:17:24 +01:00
tetektoza ced9c0dd4f Sketcher: Remember cursor angle for Rectangle OVPs after OVP is set
As the title says. Currently user is able to change geometry if OVP is
set on labels. This is because `doEnforceControlParameters` reads mouse
position every mouse move and calculates angle from it, resulting in a
new angle every time mouse is moved.

So, this patch basically reads the position before it was set, and once
it is set, locks the position of the mouse and calculates angle from it
which will be maintained until user cleans the OVP or makes a new
primitive.
2025-11-01 20:43:12 +01:00
tetektoza 1f78dac7b5 Sketcher: Remember cursor angle for Line OVPs after OVP is set
As the title says. Currently user is able to change geometry if OVP is
set on labels. This is because `doEnforceControlParameters` reads mouse
position every mouse move and calculates angle from it, resulting in a
new angle every time mouse is moved.

So, this patch basically reads the position before it was set, and once
it is set, locks the position of the mouse and calculates angle from it
which will be maintained until user cleans the OVP or makes a new
primitive.
2025-11-01 20:43:12 +01:00
tetektoza e2a141785f Sketcher: Remember cursor angle for Slot OVPs after OVP is set
As the title says. Currently user is able to change geometry if OVP is
set on labels. This is because `doEnforceControlParameters` reads mouse
position every mouse move and calculates angle from it, resulting in a
new angle every time mouse is moved.

So, this patch basically reads the position before it was set, and once
it is set, locks the position of the mouse and calculates angle from it
which will be maintained until user cleans the OVP or makes a new
primitive.
2025-11-01 20:43:12 +01:00
wandererfan 97ca7d9818 [TD]use local language for ProjectionType 2025-11-01 20:34:44 +01:00
Roy-043 48d91d6dd8 BIM: no longer use DraftVecUtils.precision()
Fixes #24928

Use `Draft.precision()` instead of `DraftVecUtils.precision()`.
2025-11-01 20:25:41 +01:00
Chris Hennes 0b1b7ccc62 Tools: Add Measure to translation download 2025-11-01 20:15:59 +01:00
PaddleStroke 0d75ff1542 Assembly: ExplodedViews: fix their use in techdraw (#24769)
* Assembly: ExplodedViews: Add getExplodedShape for techdraw to use

* TechDraw: ShapeExtractor fix assembly exploded views

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

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

* Assembly: Fix variable casing in CommandCreateView.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-11-01 20:02:48 +01:00
Kacper Donat 3b83367c4a Merge pull request #24936 from chennes/femTestTweaks
Fem test tweaks
2025-11-01 20:01:58 +01:00
tetektoza 9b2e4b4975 Draft: Do not set Make Face property when importing with DXF (#24857)
* Draft: Do not set Make Face property when importing with DXF

As the title says - this option was taken from last Draft setting, so
this disables it to always preserve only wire during import, instead of
adding faces on.

* Draft: Do not make faces when importing dxf primitives for legacy import
2025-11-01 13:26:13 +01:00
Max Wilfinger 7106c697d0 GUI: no minimum width for status bar buttons 2025-11-01 11:41:15 +01:00
wwmayer 1844fdd443 PD: Toggling transparency doesn't reset colors 2025-11-01 09:05:03 +01:00
sliptonic 0257c40bc4 Merge pull request #24964 from PhoneDroid/SPDX-Src-Mod-CAM
SPDX [ 17 ][ Src / Mod / CAM ]
2025-10-31 17:14:28 -05:00
pre-commit-ci[bot] f413a569b3 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-10-31 21:06:39 +00:00
PhoneDroid ba99bc5da4 [ CAM ]: Update SPDX License Identifiers 2025-10-31 17:00:32 -04:00
sliptonic 05b7ad0e9c Merge pull request #24875 from tarman3/simsubmenu
CAM: Simulators - Drop down menu in toolbar
2025-10-31 11:11:34 -05:00
Chris Hennes f7689115ae FEM: Disable FEM GUI unit tests 2025-10-30 23:13:14 -05:00
Jacob Oursland c270a8ac66 CI: upgrade pixi to prevent CI-breaking version mismatch. 2025-10-30 22:23:50 -05:00
Chris Hennes c93db04d9e FEM/Tests: Ensure deletion of test files 2025-10-30 22:14:33 -05:00
sliptonic 4227a6d11b Merge pull request #24935 from chennes/updateImperialPressureUnitTest
Tests: Update values for Imperial pressure tests
2025-10-30 20:41:46 -05:00
marioalexis 428340a974 Fem: Migrate old Elmer solver object 2025-10-30 10:47:10 -03:00
marioalexis c7e74a68a7 Fem: Update Elmer test files 2025-10-30 10:47:10 -03:00
marioalexis 6c583d82f2 Fem: Use FileChooser widget in CalculiX task panel 2025-10-30 10:47:10 -03:00
marioalexis 243b42f4cb Fem: Rework Elmer solver - fixes #21479 2025-10-30 10:47:10 -03:00
marioalexis 275ece0bb2 Fem: Create element groups with gmsh 2025-10-30 10:47:10 -03:00
marioalexis d018b3f8fb Fem: Add method to rename mesh group 2025-10-30 10:47:10 -03:00
marioalexis 5e42f6a48d Fem: Add ParaView .pvd file importer 2025-10-30 10:47:09 -03:00
paul 6ab89664c6 [ArchStairs] Fix structure: when RiserThickness set & ConnectionDown not HorizontalCut (#24917)
* [ArchStairs]  Fix Structure: when RiserThickness is set & ConnectionDown is not HorizontalCut

Fix #24409

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

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

* Update src/Mod/BIM/ArchStairs.py - typo correction

Co-authored-by: João Matos <joao@tritao.eu>

* Update ArchStairs.py - typo correction

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: João Matos <joao@tritao.eu>
2025-10-30 11:41:58 +01:00
Chris Hennes 5379378626 Tests: Update values for Imperial pressure tests 2025-10-29 21:36:52 -05:00
Billy Huddleston 5b2987bd07 CAM: Fix expression editor so that widgets refresh after closing
src/Gui/QuantitySpinBox.cpp:
- Call updateExpression() after setExpression() in QuantitySpinBox

src/Gui/SpinBox.cpp:
- Call updateExpression() after setExpression() in ExpressionSpinBox

src/Gui/Widgets.cpp:
- Call onChange() after setExpression() in ExpLineEdit

src/Mod/CAM/Path/Base/Gui/Util.py:
- Connect to showFormulaDialog signal and refresh CAM QuantitySpinBox Python wrapper when dialog closes
2025-10-28 15:29:01 -05:00
dependabot[bot] 67cdd23918 Bump github/issue-metrics from 3.25.1 to 3.25.2
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.25.1 to 3.25.2.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/c640329f02bd24b12b91d51cd385f0b1c25cefb9...637a24e71b78bc10881e61972b19ea9ff736e14a)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.25.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-28 13:27:59 +01:00
github-actions 11fecb1558 Update translations from Crowdin 2025-10-27 21:06:54 -05:00
mosfet80 c2bd7d3543 Updated submodule src/3rdParty/GSL 2025-10-28 02:45:42 +01:00
mosfet80 f8de1c60b4 Updated submodule src/3rdParty/OndselSolver 2025-10-28 02:45:33 +01:00
mosfet80 0a2362dd57 Updated submodule src/Mod/AddonManager 2025-10-28 02:43:52 +01:00
dependabot[bot] 25e3cb0144 Bump actions/upload-artifact from 4 to 5
Bumps [actions/upload-artifact](https://github.com/actions/upload-artifact) from 4 to 5.
- [Release notes](https://github.com/actions/upload-artifact/releases)
- [Commits](https://github.com/actions/upload-artifact/compare/v4...v5)

---
updated-dependencies:
- dependency-name: actions/upload-artifact
  dependency-version: '5'
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-27 19:10:43 -05:00
wandererfan f507ee449b [TD]use scale from view to fill template 2025-10-27 18:19:19 -04:00
wandererfan c72a707fca [TD]restore undo/redo function in FillTemplates 2025-10-27 18:19:19 -04:00
wandererfan 2709d2a595 [TD]defend against deleted object error
- App.ActiveDocument.Objects was returning a deleted object
  Most likely due to shenanigans with DrawViewPart/DrawProjGroup item
  in TaskProjGroup.
2025-10-27 18:19:19 -04:00
tarman3 478f8a0c76 CAM: Fix Dressups icon Active state 2025-10-27 20:21:45 +02:00
Max Wilfinger cf9bb8bb16 Merge pull request #23471 from hyarion/change/tasks-at-right 2025-10-27 19:01:03 +01:00
Roy-043 6eafca89e3 Draft: fix relative path issue when editing existing hatch
Something that was missed in #23294
2025-10-27 18:34:36 +01:00
PaddleStroke 676a3c3d0d Update Tree.cpp 2025-10-27 12:16:50 -05:00
sliptonic 3a5b565bd8 Merge pull request #24809 from sebastianohl/main
Zero-4 machine controller don't like two M-commands in one line
2025-10-27 12:11:27 -05:00
Billy Huddleston 478292b9ec CAM: Refactor LeadInOut task panel to use QuantitySpinBox and improve migration/visibility logic
- Replace QDoubleSpinBox widgets with Gui::QuantitySpinBox in DressUpLeadInOutEdit.ui for all lead-in/out numeric fields, enabling unit/expressions support.
- Register QuantitySpinBox as a custom widget in the .ui file.
- Refactor TaskDressupLeadInOut panel setup:
  - Add setupSpinBoxes, setupGroupBoxes, setupDynamicVisibility for cleaner UI initialization.
  - Use PathGuiUtil.QuantitySpinBox for all numeric fields and ensure updateWidget() is called for each.
  - Centralize signal registration and field updates using getSignalsForUpdate and pageGetFields.
  - Move group box signal handler to a class method.
  - Share hideModes dictionary for field visibility logic.
  - Add dynamic label switching for "Radius"/"Length" with translation placeholders.
  - Remove the Include layers Check Box
- Improve ObjectDressup migration:
  - Use shared hideModes from TaskDressupLeadInOut.
  - Set default angles to 90 instead of 45.
  - Preserve previous style values when migrating StyleOn/StyleOff.
  - Ensure field visibility is updated after migration.
- Add Perpendicular and Tangent to lead_styles in correct order.
2025-10-27 12:10:06 -05:00
FilippoR 9cf380810a Use packit to build rpm and add it as check on pull request (#21063)
* Update spec file

use custom macro to package the source file

reformat freecad.spec

add script for build from source archive

use bcond macro

use standard builddir and don't delete it to fast local rebuild

configure cmake correctly to avoid moving file later

add tests

remove python bytecompile is default

build in RelWithDebInfo to generate correctly the debuginfo package (debug info will be stripped from standard package and a debuginfo package will be generated

export dev package for ondselsolver

export libondselsolver

use new macro for filtering requires provides

simplify regexp.
remove delete unused source
enable gui tests
other fix

Disabile gui test to avoid timeout

add timeout to tests

remove rpkg macro for archive extraction

refactor prepare for packit

small fix

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

small fix

change packit configuration

fix format

fix packit

/packit build

authomatic build on commit

remove libkdtree++-devel missing in rawhide

* add packit configuration

escape changelog for spec file

add new build on release

simplify configuration to use only packit
remove script used to have only a spec file and build with 3 system
rpkg
custom bash script
packit

* add tests in test-farm

add test that read build time tests result

use default build type for pr build and always print buiild time tests result

fix and disable option without bundled_gtest

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

* add github action

Update fedora-daily.yml

Potential fix for code scanning alert no. 203: Workflow does not contain permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* Update spec file

use custom macro to package the source file

reformat freecad.spec

add script for build from source archive

use bcond macro

use standard builddir and don't delete it to fast local rebuild

configure cmake correctly to avoid moving file later

add tests

remove python bytecompile is default

build in RelWithDebInfo to generate correctly the debuginfo package (debug info will be stripped from standard package and a debuginfo package will be generated

export dev package for ondselsolver

export libondselsolver

use new macro for filtering requires provides

simplify regexp.
remove delete unused source
enable gui tests
other fix

Disabile gui test to avoid timeout

add timeout to tests

remove rpkg macro for archive extraction

refactor prepare for packit

small fix

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

small fix

change packit configuration

fix format

fix packit

/packit build

authomatic build on commit

remove libkdtree++-devel missing in rawhide

* add packit configuration

escape changelog for spec file

add new build on release

simplify configuration to use only packit
remove script used to have only a spec file and build with 3 system
rpkg
custom bash script
packit

* add tests in test-farm

add test that read build time tests result

use default build type for pr build and always print buiild time tests result

fix and disable option without bundled_gtest

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

Update package/fedora/freecad.spec

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

* add github action

Update fedora-daily.yml

Potential fix for code scanning alert no. 203: Workflow does not contain permissions

Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>

* tentative fix test

* add verbose failed tests

* fix ctest

* Remove error file if 2 time is successful

* Update plan.fmf add IfcOpenShell-python3

* Update .packit.yaml

Update freecad.spec

Update plan.fmf

Update .packit.yaml

Update plan.fmf

* Update freecad.spec

* restore version

* add rpm cmake preset

* update tests

* add qt6-assistant deps

* use xvfb-run for QuantitySpinBox test

* fix ctest command

* clean

* restore Addon Manager: Add defusedxml dependency

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2025-10-27 12:06:38 -05:00
sliptonic 1111f8da7c Merge pull request #24851 from FreeCAD/removeLiberaPayFromFunding
Remove Liberapay entry from FUNDING.yml
2025-10-27 11:55:06 -05:00
theo-vt 87d21a643d Sketcher: Reassign virtual space flag to constraints after modifying them through a default DHS 2025-10-27 11:53:26 -05:00
Chris Hennes 9a12579cb9 Merge pull request #24277 from ryankembrey/werner_fix_23504
Gui: Do not accept changes when pressing ESC key in 3D view
2025-10-27 11:49:46 -05:00
Roy-043 ee512ebc00 BIM: BIM_ProjectManager: add missing self.project check 2025-10-27 11:48:06 -05:00
Chris Hennes 8fe33581e6 Build: Use date as revision when using a shallow clone 2025-10-27 17:47:41 +01:00
Steven James 909d581265 Add Dockerfile and script to create an Ubuntu Qt6 based build image for docker. 2025-10-27 11:37:16 -05:00
wandererfan 09f3e6738c [TD]shrink selection frame 2025-10-27 11:36:31 -05:00
Kacper Donat 9e6e2f474f Gui: Enable overlay for the Tasks panel by default 2025-10-27 17:32:06 +01:00
tarman3 9a81201b24 CAM: Simulator submenu in toolbar 2025-10-27 12:46:06 +02:00
paul 3084c48c8e [ArchStairs] Fix Wrong Height when toSlabThickness & Landings AtCenter are set (#24864)
* [ArchStairs] Fix Wrong Height when toSlabThickness & Landings AtCenter are set

Fix #24408

This fix both Stairs Flight set as Straight and HalfTurnLeft/Right

* [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-27 11:10:48 +01:00
NepEgor 5409b12e6e Gui: Fix FreeTurntable orbit style not constraining vertical axis (#24861)
* Gui: Fix FreeTurntable orbit style not constraining vertical axis

* Apply suggestions from code review

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-26 22:41:45 +00:00
Syres916 e95d3cbdc9 [TechDraw] Fix the projection type combobox and align all references to First angle and Third angle (#24762) 2025-10-26 17:31:44 -05:00
tetektoza 4718c46170 TechDraw: Fix centerlines being double Y-axis transformed
As the title says. Currently when user exports to DXF, centerlines and
cosmetic edges appeared offset below their correct positions. The offset
was visible when opening exported DXF file in CAD software - centerlines
were displaced downward where they should be.

The issue was that cosmetic edges are already stored with the correct Y
orientation and should not be mirrored during export, so this caused
centerlines to be mirrored when they shouldn't be, resulting in
incorrect Y position.

So this is just a small modification to cosmetic edge export to skip the
Y-axis mirroring step.
2025-10-26 17:24:58 -05:00
tetektoza b65451c2b4 Import: Make sure to not convert text height from draw units to points
When importing DXF files using the C++ importer, TEXT and MTEXT entities
had incorrect heights. For example:
- text with height 100mm in the DXF file was imported as 35.28mm in FC.
The scaling factor was consistent to be 0.3528.

The issue was that we were applying a point-to-millimeter conversion to
the text height , but that seems to be incorrect since according to DXF
spec, TEXT and MTEXT entity heights are always specified in drawing
units, not in points, so just remove that code.
2025-10-26 16:47:43 -05:00
Florian Foinant-Willig 501c6273a3 PartDesign: only warn on refine failure 2025-10-26 22:16:04 +01:00
Benjamin Nauck 5aa00ca0ad Gui: Move tasks to the right side for easier defaults 2025-10-26 21:21:46 +01:00
tetektoza 0cfa5ba5fe Fix: Closed polylines import duplicate vertices
Similar case to the previous commit related to closed polylines having
coincident vertices, but this time for import. Basically if importing
DXF files containing closed polylines, FC would throw an exception.

This was because `BuildWireFromPolyline()` function in the DXF importer
attempted to create a closing edge for closed polylines by connecting
the last vertex back to first vertex.

So, this patch adds a skip for the closing edge if the vertices are
coincident.
2025-10-26 15:17:00 +01:00
Roy-043 b433350aff Change keyboard shortcut from 'I, P' to 'I, S' 2025-10-26 15:01:08 +01:00
tetektoza 01777cb320 Fix: Closed polylines export duplicate vertices
AS the title says - when exporting closed curves (ellipses for example)
as polylines with the "Treat ellipses and splines as polylines" option,
the generated DXF file contained duplicate vertices. For example, an
ellipse polyline would have vertex1 and vertex40 which are identical in
terms of coordinates. This has caused exception upon importing.

Cause of that was that discretizer was blindly iterating through all
discretized points without checking if the first and last points are
coincident.

So, this patch adds a check for that to detect and skip the last
coincident point if it is in fact coincident during Export.
2025-10-26 14:45:10 +01:00
tetektoza e221cfd47a Import: Export number of vertices in polylines as int instead of double 2025-10-26 14:29:24 +01:00
tetektoza 34eafe127e Import: Use proper location for DXF prefs
Currently if users enabled the "Treat ellipses and splines as polylines"
option in DXF export preferences and exported them, they were still
being exported as native primitives.

This was because we were reading from a wrong preferences location, UI
stored it in `BaseApp/Preferences/Mod/Draft`, but it was read from
`BaseApp/Preferences/Mod/Import`. Since the pref didn't exist, we were
taking default value which was set to `false`.

So the solution is obvious - just set it to the correct path.
2025-10-26 14:26:02 +01:00
Chris Hennes 4daf8d3b38 Remove Liberapay badge from README 2025-10-25 14:37:36 -05:00
Chris Hennes 99dee32e84 Remove Liberapay entry from FUNDING.yml
Removed Liberapay funding entry and updated formatting.
2025-10-25 14:29:14 -05:00
Roy-043 e366824b74 BIM: fix update of material tree icon 2025-10-25 20:04:12 +02:00
tetektoza 9e58650477 BIM: Fix beam rotation when Base property is cleared (#24831)
When a profile-based beam had its Base property cleared and the model
was recomputed, the beam would rotate 90 degrees, changing its direction
completely.

Profile objects are always created in the XY plane with Width along X,
height along Y and normal along Z. However, if Base is cleared, fallback
code always used YZ plane orientation for beams. This resulted in a
different orientation during cleaned Base property.

Fix is to check if we are profile-based or not and if yes, use XY plane
orientation, while we don't have this property then just use YZ plane
orientation (preserving traditional horizontal behavior).
2025-10-25 14:10:37 +02:00
Roy-043 4ef209cabe BIM: fix strict IFC drag and drop 2025-10-24 10:21:42 +02:00
Chris Hennes f6f919d229 Gui: Use postEvent instead of sendEvent for Esc handling
See https://github.com/FreeCAD/FreeCAD/pull/24277#issuecomment-3342091132

Co-authored-by: wwmayer <wmayer@freecad.org>
2025-10-23 14:39:31 -05:00
wwmayer 503ef79cea Gui: Do not accept changes when pressing ESC key in 3D view
Forward the ESC key event to the Task view to reject changes if needed. This fixes issue https://github.com/FreeCAD/FreeCAD/issues/23504
2025-10-23 14:35:40 -05:00
sliptonic c7c068be6e Merge pull request #24810 from tarman3/leadinout_fix_isActive
CAM: LeadInOut - Fix isActive()
2025-10-23 13:05:14 -05:00
tarman3 06e0fb4c19 CAM: LeadInOut - Fix isActive() 2025-10-23 15:16:02 +03:00
sliptonic 4b0259b57f Merge pull request #24666 from tarman3/leadinout_no_leadin
CAM: LeadInOut - Fix LeadIn off
2025-10-23 06:59:04 -05:00
Sebastian Ohl 70be188426 adding newline, as the Zero-4 machine controller don't like two M-commands in one line 2025-10-23 13:54:22 +02:00
PaddleStroke fce385dd73 Assembly: Fix Iisolate issue when obj and link both in assembly (#24781)
* Assembly: Fix Iisolate issue when obj and link both in assembly

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

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

* Update src/Mod/Assembly/Gui/ViewProviderAssembly.cpp

Co-authored-by: Kacper Donat <kadet1090@gmail.com>

* [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>
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-10-23 10:04:46 +00:00
tarman3 3ea894029f CAM: LeadInOut - Fix LeadIn off 2025-10-23 06:48:14 +03:00
sliptonic 70a7480601 Merge pull request #24471 from tarman3/leadinout_perp_tan
CAM: LeadInOut - Revert Perpendicular and Tangent styles
2025-10-22 19:23:02 -05:00
Leandro Heck 873fa449ce PD: Show custom direction settings on Pad/Pocket only when necessary. (#24642)
* PD: Show custom direction settings on Pad/Pocket only when necessary.

* Update the visibility of parameters.
2025-10-23 00:00:11 +02:00
PaddleStroke 498968b89c Sketcher: Do not open command if one is pending in doSetVisible (#24778)
* Sketcher: Do not open command if one is pending in doSetVisible

* [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-22 23:58:30 +02:00
tetektoza 1683f271c6 Import: Fix crash in glTF importer when removeSplitter() fails
Currently `removeSplitter()` function attempts to merge coplanar faces
by using `ModelRefine::FaceUniter`, which internally uses
`BRepBuilderAPI_Sewing`. This can fail in several scenarios, like
inability to produce a valid shell, failing in face unification due
to geometry incompatibilities, or when we have tolerance issue in the
reconstructed geometry from glTF triangulation that prevent us from face
merging.

That leads to the exception, which we are not handling correctly where
it's being handled the same way as this patch introduces in other parts
of FreeCAD.

So, this patch adds a try-catch block around `removeSplitter()` to
gracefully handle `Standard_Failure` exception and return the sewn shape
instead of crashing. Imported model will contain more individual faces
than necessary (since coplanar won't be merged), resulting in a more
complex topology in the places of those fails, but geometry and visual
appearance will be preserved.
2025-10-22 16:43:25 -05:00
tarman3 f8662d75eb CAM: LeadInOut - Revert Perpendicular and Tangent styles 2025-10-22 20:22:49 +03:00
sliptonic f1c7d91a74 Merge pull request #24433 from tarman3/leadinout_radius
CAM: LeadInOut - Radius and ToolController
2025-10-22 11:55:09 -05:00
Furgo 2096d0bd86 BIM: Implement double-click event for materials group (#24767)
* BIM: Implement double-click event for materials group

Add double-click handling for materials group in Tree View.

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

* [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-21 14:07:13 +02:00
PaddleStroke 529aae0238 Assembly: Prevent crash when toggling rigid of grounded sub assembly (#24761)
* Assembly: Prevent crash when toggling rigid of grounded sub assembly

* to squash

* to squash

* Update AssemblyLink.cpp
2025-10-21 07:51:15 +00:00
Chris Hennes d97c7cc95c Core: Switch away from deprecated wstring_convert and codecvt_utf8 2025-10-21 09:01:59 +02:00
Kacper Donat 3a6c75f5bd Merge pull request #24751 from tetektoza/fix/24009_clarify_selection_LMB_activated_by_accident
Gui: Add additional handling for Clarify Selection's long press
2025-10-20 23:22:17 +02:00
tetektoza 93f1cf717b Gui: Use assignment to auto in if statement
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-10-20 20:21:02 +02:00
tetektoza 58d319511a Gui: Add navigation modes to distinguish which nav mode requires CTRL 2025-10-20 20:18:28 +02:00
tetektoza 6a597a9277 Gui: Add additional handling for Clarify Selection's long press
This patch adds handling for different contexts that Clarify Selection's
long press may occur in. For example, different navigation styles,
transform tool, or dragger presence.

This way we are sure that the context menu for Clarify Selection won't
be popping up for the user when using one of the above-mentioned
contexts.

Also, this adds handling for different navigation styles, to accept
CTRL+LMB as the long press mouse-key combos, instead of just
long-pressing LMB, as in those navigation styles LMB is mostly used as
rotation.
2025-10-20 20:18:28 +02:00
tetektoza 5686d0a713 Gui: Add additional preferences for Clarify Select's long press to Prefs
As the title says. Two preferences, that reflect what has been added previously
- now the users can disable LMB at all, or increase the timeout through prefs.
2025-10-20 20:18:24 +02:00
Chris Hennes 5e63985fa7 Merge pull request #24749 from FreeCAD/BuildingEuroAreaDim2
Base, TechDraw: Use Unit Schema Values in Area Dimension
2025-10-20 11:37:55 -05:00
Petter Reinholdtsen 88d21ce70e Fixed inconsistent return types between several salomemesh methods and propotypes.
The prototypes in the header file did not match the implementation in the
C source.

These issues were discovered when enabling link time optimization.  There are
more LTO issues left to fix before it can be enabled, but these involve
mixing a C++ class and a pointer to floating point values and is a lot
more intrusive to fix.

This change is related to issue #13173, bringing LTO one step closer.
2025-10-20 11:09:56 -05:00
PaddleStroke 55d0e2b3ac Image: enable pasting image data directly (#24711)
* Image: enable pasting image data directly

* Update MainWindow.cpp
2025-10-20 17:59:49 +02:00
Chris 6fd6558040 Import: Export tip when body is selected (#24678) 2025-10-20 10:59:18 -05:00
Florian Foinant-Willig 7f6c39c358 PartDesign: fix MultiTransform from existant Transform 2025-10-20 17:55:01 +02:00
PaddleStroke 06c46bd352 Sketcher: Fix issue of reversed arcs input for polar pattern (#24351)
* Sketcher: Fix issue of reversed arcs input for polar pattern

* DrawSketchHandlerRotate: remove getRotatedPoint that is no longer needed

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

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

* Update Geometry.cpp

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-10-20 10:45:18 -05:00
Syres916 5ba4feac59 [PartDesign] create a new Gui Unit Test for the creation of a sketch … (#23601)
* [PartDesign] create a new Gui Unit Test for the creation of a sketch and...

...improve the Selection Filter syntax error to show where it's being generated from.

* [PartDesign] address Lint feedback

* PD/Tests: Ensure test file does not exist before SaveAs

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-20 10:34:05 -05:00
Roy-043 fa67c65da9 BIM: fix site error when creating project with default structure
Fixes #24543.
2025-10-20 17:21:56 +02:00
Kevin Martin 0334c145d0 Do not use the object's Name as a Label if that Label already exists 2025-10-20 17:07:42 +02:00
github-actions 50d1dec4e0 Update translations from Crowdin 2025-10-20 09:57:05 -05:00
Chris Hennes e806592d92 Merge pull request #24734 from Syres916/CAM_Fix_SetupSheet_Table_MinHeight
[Gui] fix Arch Grid QTableview height and buttons width...
2025-10-20 09:41:51 -05:00
Chris 129d64dd87 Sketcher: Resolve aggressive snapping (#24730)
Fixes #24690
2025-10-20 09:37:51 -05:00
sliptonic adb327d98e Merge pull request #24397 from LarryWoestman/epic
CAM:  Add proposed Epic for improving postprocessors
2025-10-20 09:31:11 -05:00
PaddleStroke 7023e83843 Sketcher: Add support for tangent singularity when concentric circles (#24227) 2025-10-20 09:28:37 -05:00
Kacper Donat a09de19764 Gui: Fix order of stylesheet applying 2025-10-20 09:26:22 -05:00
Roy-043 08aeb5d65b BIM: remove 'show this dialog' checkbox from IFC Import and IFC Export prefs (#24728)
Fixes #24551
2025-10-20 09:15:43 -05:00
Roy-043 4b1ce402ff Rebased 2025-10-20 09:00:22 -05:00
dependabot[bot] 31ed7d2b67 Bump prefix-dev/setup-pixi from 0.9.1 to 0.9.2
Bumps [prefix-dev/setup-pixi](https://github.com/prefix-dev/setup-pixi) from 0.9.1 to 0.9.2.
- [Release notes](https://github.com/prefix-dev/setup-pixi/releases)
- [Commits](https://github.com/prefix-dev/setup-pixi/compare/194d461b21b6c5717c722ffc597fa91ed2ff29fa...28eb668aafebd9dede9d97c4ba1cd9989a4d0004)

---
updated-dependencies:
- dependency-name: prefix-dev/setup-pixi
  dependency-version: 0.9.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-20 08:57:14 -05:00
wandererfan 0e7460496e [TD]use unit and text from schema 2025-10-20 08:55:44 -05:00
wandererfan c9fffa6789 [Base]retrieve unit text
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-20 08:54:52 -05:00
Kacper Donat e8aeffc096 PartDesign: Fix misplaced preview for Boolean operation 2025-10-20 08:46:28 -05:00
Chris Hennes 54535e072e Merge pull request #24752 from kadet1090/fix-various-stylesheet-issues
Stylesheets: Fix various stylesheet issues
2025-10-20 08:45:34 -05:00
Roy-043 2386ff1abc BIM: fix multi-material transparency IFC export issue (#24643)
* BIM: fix multi-material transparency IFC export issue

Fixes #22896.
2025-10-20 08:44:37 -05:00
Chris Hennes 98c9bca45a Merge pull request #24263 from captain0xff/gizmo4
Gui: Fix dependency issues with the interactive draggers
2025-10-19 23:47:45 -05:00
Roy-043 02d31f0457 BIM: fix Arch_RemoveShape attribute error
Fixes #24610.

Note that the command (after this PR) does not work properly (as was the case in v0.21).
2025-10-19 22:23:35 -05:00
Roy-043 f4bfbb47fa BIM: fix several dialog regressions (#24590)
* BIM: fix BIM_Classification dialog regression

* Fixed issues with more scenarios
2025-10-19 22:23:05 -05:00
captain0xff d08a7f1c0d Gui: change the group for the gizmo preferences 2025-10-19 22:19:21 -05:00
captain0xff 529c624afc Part: move GizmoHelper.h to src/Mod/Part/App 2025-10-19 22:19:11 -05:00
Steven James 5abf4da75e Building: Ubuntu environment needs python3-pyside2.qtnetwork for testing (#24493) 2025-10-19 21:41:50 -05:00
wandererfan 2172e82f23 [TD]fix area anno positioning 2025-10-19 21:40:25 -05:00
Chris d7b735ff95 GUI: Check correct parameter for pop-up notifications (#24727) 2025-10-19 21:04:06 -05:00
Lawrence Woestman fd2e4b1397 CAM: Incorporated the first round of feedback 2025-10-19 16:24:41 -07:00
Lawrence Woestman b8c6d59ab6 CAM: Add proposed Epic for improving postprocessors 2025-10-19 15:19:57 -07:00
Kacper Donat 06a9c56656 Stylesheets: Fix checked QToolButton style 2025-10-20 00:10:57 +02:00
Kacper Donat 777726f093 Stylesheets: Add styling for QPlainTextEdit 2025-10-20 00:10:57 +02:00
Kacper Donat c5ff1b4550 Stylesheets: Resreve space for right arrow 2025-10-19 23:09:21 +02:00
opgl fdd7dac561 CI (crowdin synchronization): Removed committing unneeded log file 2025-10-19 15:46:03 -05:00
tetektoza d5f9059199 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 a431ccc156 Quickmeasure: Allow measuring the length of a parabola 2025-10-19 12:31:47 -05:00
Furgo 2796296a24 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
opgl ac21faf35e CI (automated crowding synchronization): fix commiting additional log file 2025-10-18 14:37:10 -05:00
tarman3 68084b64c9 CAM: LeadInOut - Radius and ToolController 2025-10-18 18:37:37 +03:00
sliptonic a94382dd07 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 4ff8998198 [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 e28f54f598 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
Syres916 879c083abf Merge branch 'FreeCAD:main' into CAM_Fix_SetupSheet_Table_MinHeight 2025-10-18 11:27:03 +01:00
Syres916 36b263a906 [Gui] change global QPushbutton min-width from 64px to 80px 2025-10-18 11:26:50 +01:00
ebswift bbea8ace72 Fix compilation error in TaskFeatureParameters.cpp 2025-10-17 22:35:44 -05:00
theo-vt 171389d9d3 Measure: allow length measurement for ellipse, hyperbola and parabola (#24659) 2025-10-17 21:34:07 +00:00
Chris 65d166f356 PD: Fix uninfomative error message box (#24705) 2025-10-17 19:48:31 +00:00
David Kaufman 909cd46a9f fix bug opening job ui panel 2025-10-17 15:08:10 -04:00
sliptonic f3186f4dc0 remove old supplemental fixture 2025-10-17 12:10:22 -05:00
David Kaufman e3874a1973 [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 8df09d92c0 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 b72f83136c Merge pull request #24606 from tarman3/toggle
CAM: Toggle Operation improve
2025-10-17 10:41:00 -05:00
sliptonic 7bb4bacc11 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 855d76bb40 Addon Manager: Synchronize with 2025.10.16 version 2025-10-17 05:25:19 +02:00
Chris Hennes e4b6b32f11 Merge pull request #24684 from furgo16/patch-34
BIM: remove obsolete Python 2 urllib2 import
2025-10-16 15:48:43 -05:00
Furgo ae0946ac9d BIM: replace obsolete urllib2 in BimTutorial 2025-10-16 21:21:40 +02:00
Furgo da4832fb50 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 0e6d4aa1d7 Gui: Restore focus to tree upon deletion and move selection to next obj (#24679) 2025-10-16 13:13:08 -05:00
PaddleStroke e278d22d42 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 5e75a3ece9 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 8496d25279 Gui: fix null handling logic in Application::setEditDocument 2025-10-16 12:54:20 -05:00
Furgo a89c7eedcf 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 bdb817a6a1 BIM: improve MultiMaterial task panel
Update MultiMaterialColumnWidth values to 120
2025-10-16 15:00:35 +02:00
Roy-043 0bfc4ac41e 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
marcuspollio aef287cbb6 Update .git-blame-ignore-revs for BIM and Draft .pre-commit and Black format 2025-10-15 21:39:09 -05:00
Billy Huddleston 906edf7078 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 50e4864efb 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 87f88bba30 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 c995a331b6 CAM: Fix icon and Active state for class ObjectOp 2025-10-15 07:39:02 +03:00
Chris Hennes 41ce37233d 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 2b90740855 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 96b76b4e41 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
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 3f918a5d35 [ Surface ]: Updated SPDX (#24560) 2025-10-14 10:02:53 -05:00
PhoneDroid 7595a83f36 [ OpenSCAD ]: Updated SPDX 2025-10-14 10:01:41 -05:00
PhoneDroid d9cf2b65b5 [ MeshPart ]: Update SPDX 2025-10-14 10:01:02 -05:00
PhoneDroid 2a56489feb [ Base ]: Updated SPDX 2025-10-14 10:00:04 -05:00
dependabot[bot] 325dd3b701 Bump github/issue-metrics from 3.25.0 to 3.25.1
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.25.0 to 3.25.1.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/17c6bd18e923c2ec4161c6911f9b075908f7f090...c640329f02bd24b12b91d51cd385f0b1c25cefb9)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.25.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-14 15:53:53 +02:00
Chris Hennes 7bc525f885 Merge pull request #23592 from ryankembrey/td-vertices
TechDraw: Fix vertices regressions
2025-10-14 08:26:50 -05:00
Adrian Insaurralde Avalos 667b841de1 [Base] fix some unit tests that where dependent on user config
redundant and faulty test `imperial_decimal_1_mm_default_precision` removed, it is already covered by `imperial_decimal_1_mm_precision_2`
2025-10-14 12:42:24 +02:00
PaddleStroke 8275916601 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 9462c7bfb3 Gui: Fix supporting links in add property dialog 2025-10-14 11:56:47 +02:00
PaddleStroke 981daca351 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 1e56392c5c Tux: remove obsolete pythonToolbars function 2025-10-14 11:50:19 +02:00
PaddleStroke 6e090a2dad 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 d0c7b427ff 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 9fad915d0e Core: fix Std_Placement for multiple objects 2025-10-13 22:54:31 +02:00
PaddleStroke b82505e86c 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
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 546a43b8b8 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 558659d117 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 62c222c211 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 45401513b4 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 f4fe303829 Sketcher: rename DeriVector2::crossProdNorm to DeriVector2::crossProdZ 2025-10-13 17:57:51 +02:00
Chris Hennes f7b4372108 Gui: Fix string encoding for drag-and-drop 2025-10-13 17:34:59 +02:00
Furgo b23d580941 Add BIM workbench to .pre-commit-config.yaml (#21591)
* Add BIM workbench to .pre-commit-config.yaml

* pre-commit: ignore translations

* pre-commit: add additional ignore pattern

* [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 13:07:48 +02:00
Billy Huddleston 51b5870953 Added myself to CONTRIBUTORS 2025-10-13 00:21:06 -05:00
schmidtw 33aeb38f0c Add unit tests for CommandInsertLink fix
Add comprehensive unit tests to verify the fix prevents AttributeError
  when accessing non-existent nodes.
2025-10-12 14:50:03 -07:00
schmidtw 4b2131f501 Fix: Prevent attempting to access non-existent nodes
This is defensive code that protects against attempting to dereference
  nodes that are not present, preventing the python code from throwing an
  AttributeError.
2025-10-12 14:49:28 -07:00
Syres916 806e3e9eb0 [Gui] revert PR23067 and apply table height...
...directly in the Python code
2025-10-12 18:41:05 +01:00
Syres916 8d3a2e93fd Merge branch 'FreeCAD:main' into CAM_Fix_SetupSheet_Table_MinHeight 2025-10-12 18:38:46 +01:00
tarman3 f17c46f8ec CAM: Toggle Operation improve 2025-10-12 15:22:35 +03:00
Chris Hennes 7d811f2ab2 CI: Update CrowdIn Push to use pinned versions 2025-10-12 14:16:22 +02:00
Chris Hennes e89fcf29f7 CI: Update CrowdIn Fetch workflow to use pinned versions 2025-10-12 14:16:22 +02:00
DONGGEUN YOO 911d82f99b BIM: Fix IFC import options dialog not showing until Preferences are opened (#24574) 2025-10-11 18:22:55 +02:00
PaddleStroke 557f45587f TechDraw: fix setMask error in mrichtextedit.cpp 2025-10-09 21:16:50 -05:00
Pieter Hijma 90f9996fdb Gui: Fix too enthusiastic auto-collapse 2025-10-09 16:11:24 -05:00
PaddleStroke 8f3d9d9cdf Part: Offset tools: do not copy sketch colors. 2025-10-09 14:43:12 -05:00
PaddleStroke 98d64f9939 Sketcher: Element Task : clear selection when list selection is cleared 2025-10-09 14:06:10 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 084003e361 Tests: Add/update SPDX header (#24547) 2025-10-09 13:50:17 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ cab1261a42 CAM: Remove UTF-8 coding declarations (#24527)
These declarations are no longer needed for Python 3+.
2025-10-09 13:49:18 -05:00
dependabot[bot] b460e85abe Bump github/issue-metrics from 3.24.0 to 3.25.0
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.24.0 to 3.25.0.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/45a6cb314ddaa4c12eed570eb2739435d712d480...17c6bd18e923c2ec4161c6911f9b075908f7f090)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.25.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-09 20:03:16 +02:00
PaddleStroke ca8bfc6180 Sketcher: Make ctrlA work with filter (#24541) 2025-10-09 12:37:54 -05:00
PaddleStroke 331e51cdfc Sketcher: Fix toggle construction not undoable (#24539)
* Sketcher: Fix toggle construction not undoable

* [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-09 12:31:50 -05:00
Chris Hennes 02df83e19d Merge pull request #24446 from pieterhijma/fix-add-prop-dialog-py-console
Gui: Fix Python Console messages Add Property dialog
2025-10-09 10:29:37 -05:00
Pieter Hijma 9a09e8e321 Gui: Fix console messages Add Property dialog 2025-10-09 16:01:05 +02:00
Pieter Hijma 6af8e0b380 Gui: Add a possibility to redirect macro commands 2025-10-09 16:00:12 +02:00
Benjamin Nauck f3c043195f Gui: Enable quick measure and input hints by default 2025-10-09 15:56:43 +02:00
PhoneDroid e2e75f1039 Updated SPDX License Identifiers 2025-10-08 21:58:26 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 78f29138bc CAM: Updated SPDX License Identifiers (#24525) 2025-10-09 00:36:39 +00:00
PhoneDroid b5b9913293 Updated SPDX License Identifiers 2025-10-08 19:11:11 -05:00
PhoneDroid 78447d9800 Updated SPDX License Identifiers 2025-10-08 19:10:28 -05:00
johndoe2323 23297f5045 fix for #18165
calculation changed to incorporate scale for distanceDim.X and distanceDim.Y
2025-10-08 17:38:35 -05:00
PhoneDroid 1b16eeeeb9 Updated SPDX License Identifiers 2025-10-08 16:39:12 -05:00
wandererfan 46f4014647 [TD]fix subscript out of range on bad selection 2025-10-08 16:08:13 -05:00
marcuspollio 17c8da0244 BIM: add formatting off comments (#24502) 2025-10-08 21:48:08 +02:00
marcuspollio 4323840e8e Draft: add formatting off comments (#24503) 2025-10-08 21:43:38 +02:00
PhoneDroid 8912dfd7e1 Updated SPDX License Identifiers 2025-10-08 10:56:23 -05:00
PhoneDroid 661bdd999a Updated SPDX License Identifiers 2025-10-08 10:53:08 -05:00
PhoneDroid 372959ddee Updated SPDX License Identifiers 2025-10-08 10:51:06 -05:00
PhoneDroid ca4a8cd200 Updated SPDX License Identifiers 2025-10-08 10:49:52 -05:00
PhoneDroid c78b483dd5 Updated SPDX License Identifiers 2025-10-08 10:28:46 -05:00
PhoneDroid d33b4b38f7 Updated SPDX License Identifiers 2025-10-08 10:27:10 -05:00
dependabot[bot] 5467173e01 Bump ossf/scorecard-action from 2.4.2 to 2.4.3
Bumps [ossf/scorecard-action](https://github.com/ossf/scorecard-action) from 2.4.2 to 2.4.3.
- [Release notes](https://github.com/ossf/scorecard-action/releases)
- [Changelog](https://github.com/ossf/scorecard-action/blob/main/RELEASE.md)
- [Commits](https://github.com/ossf/scorecard-action/compare/05b42c624433fc40578a4040d5cf5e36ddca8cde...4eaacf0543bb3f2c246792bd56e8cdeffafb205a)

---
updated-dependencies:
- dependency-name: ossf/scorecard-action
  dependency-version: 2.4.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-07 19:43:41 -05:00
PaddleStroke 94fb19d9be Assembly: Fix dragger when assembly is transformed 2025-10-07 19:41:55 -05:00
opgl 68f083a6d1 CI: Automatically synchronize translations with CrowdIn 2025-10-07 17:49:55 -05:00
Syres916 3a8de56ee5 [Gui] fix the Preferences tree font 2025-10-07 12:47:29 -05:00
Chris Hennes 9780cf931f Update translations 2025-10-05 2025-10-07 19:21:58 +02:00
PaddleStroke 6282dd48bb Assembly: Make pre-solve and reverse move all the downstream parts (#24193) 2025-10-07 11:44:11 -05:00
dependabot[bot] c64f06c3ad Bump actions/stale from 10.0.0 to 10.1.0
Bumps [actions/stale](https://github.com/actions/stale) from 10.0.0 to 10.1.0.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/3a9db7e6a41a89f618792c92c0e97cc736e1b13f...5f858e3efba33a5ca4407a664cc011ad407f2008)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: 10.1.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-06 13:02:48 -05:00
PaddleStroke 96ca8a43a6 Assembly: Add tolerance to detect ground part movement 2025-10-06 13:02:24 -05:00
ᴩʜᴏɴᴇᴅʀᴏɪᴅ 01da3ddd35 Fix & update license to LGPLv2.1 2025-10-06 11:43:26 -05:00
IFo Hancroft e187e696b5 Added GPL-3.0-or-later to the list of licenses (#24447)
* Added GPL-3.0-or-later to the list of licenses

* Incremented number of licenses
2025-10-06 11:33:07 -05:00
PaddleStroke cb38761213 Assembly: replace properties float by propertylength & propertyangle (#24403)
* Assembly: replace properties float by propertylength & propertyangle

* [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-06 11:18:22 -05:00
sliptonic 6817ec7a78 Merge pull request #24374 from chennes/fix23777userEditMide
Part/PD: Send user edit mode to cmdSetEdit
2025-10-06 11:05:58 -05:00
sliptonic b93b67f1b6 Merge pull request #24014 from chennes/fixCopyMenuMisplaced23769
Gui: Ensure menus don't get moved inadvertently
2025-10-06 11:05:04 -05:00
PaddleStroke 365af33fc6 Sketcher: Symmetric arc when center is on symmetry line. (#24228)
* Sketcher: Symmetric arc when center is on symmetry line.

* [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-06 11:02:42 -05:00
Markus Reitböck 85776dd66b Gui: Fix unreadable button in Customize Dialog (#24285)
* Gui: Fix unreadable button in Customize Dialog

Also renamed Pixmap to Icon

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

* Update src/Gui/Dialogs/DlgActions.ui

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-06 10:59:29 -05:00
sliptonic 432583bb20 Merge pull request #24069 from tarman3/leadinout_fix2
CAM: LeadInOut - Fix SafeHeight
2025-10-06 10:58:21 -05:00
sliptonic b3f3bf5c0a Merge pull request #24177 from chennes/migrateLibE57ToSubtree
Migrate libE57Format to subtree
2025-10-06 10:56:18 -05:00
Sami Liedes 0a50bad4c0 Gui: Request 24-bit color depth if available
In some configurations, Qt apparently defaults to giving the "first
acceptable" buffer format. This often ends up being RGB565, which
gives us little color resolution.

Request 8-bit RGB samples to fix this.

This tends to happen easiest with
`QT_WAYLAND_DISABLE_WINDOWDECORATION=1` and `QT_QPA_PLATFORM=wayland`.
2025-10-06 10:48:30 -05:00
sliptonic 5e06ae1b4d Merge pull request #24179 from tarman3/oldsim
CAM: Old simulator - Fix z for G2,G3
2025-10-06 10:45:42 -05:00
sliptonic bc696ad89b Merge pull request #24016 from chennes/fixIgnoredFontPreference
Gui: Fix ignored font preference
2025-10-06 10:35:51 -05:00
sliptonic 1c816da43b Merge pull request #24114 from chennes/addDirectoryIsWritable
Base: Refine directory permissions test
2025-10-06 10:35:21 -05:00
Aqeel Labash 8fe4d67abe TechDraw: Make TaskWeldingSymbol buttons resizeable (#24395) 2025-10-05 21:09:26 -05:00
Furgo ffc6f840bd Core: FreeCadMacros.cmake:fc_copy_sources ensure parent directory is created before copy or symlink creation
Fixes: #24432
2025-10-05 21:08:34 -05:00
Pieter Hijma 532354c2a4 Gui: Exclude base type in Add Property dialog 2025-10-05 21:08:06 -05:00
wandererfan 9bae342c0d [TD]fix zero value on multi-face dimension 2025-10-05 21:06:03 -05:00
Chris Hennes 072f0b0fa3 Merge pull request #24438 from Rexbas/fix-openscad-transform-conflict
Gui: Fix transform tool conflict with OpenSCAD navigation style
2025-10-05 21:05:19 -05:00
Roy-043 6395af4113 BIM: fix BimMaterial dialog regression
Fixes #24381
2025-10-05 19:12:46 -05:00
PaddleStroke c2592271e8 Sketcher: remove edit tools from toolbar (#24229)
* Sketcher: remove edit tools from toolbar

* Update Workbench.h

* [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-05 19:11:46 -05:00
Syres916 ce8584c728 [Gui] Fix spreadsheet alias cells not being correctly set to the user's preference 2025-10-05 19:07:14 -05:00
Chris d2c306ce6a Packaging: Fix mac app bundling with homebrew (#24286) 2025-10-05 19:06:23 -05:00
Roy-043 abc8bb9849 BIM: fix update behavior of BIM views panel (#24273)
* BIM: fix update behavior of BIM views panel

Fixes #17415
Fixes #17868

To avoid unnecessarily updating the trees an `oldData` list is used.
2025-10-05 19:05:37 -05:00
Kacper Donat 8398ac7a81 Merge pull request #23620 from hyarion/fix/qm
Gui: Toggle quick measure and input hints from status bar context menu
2025-10-05 12:16:57 +02:00
Furgo 8e202d6aaf BIM: Fix ArchSite View Provider lifecycle, property constraints and defaults (#23844)
* BIM: Fix Site view provider initialization and constraints

This commit fixes bugs in the `_ViewProviderSite` lifecycle, ensuring
that sun path properties are correctly initialized with valid defaults
and that their constraints are reliably restored when a document is
opened.

Previously, two main problems existed:
1. New Objects: When a new `Site` object was created, its sun path
   properties (e.g., `SunDateMonth`) would default to 0, which is an
   invalid value. The property editor in the GUI would also lack the
   appropriate min/max constraints.
2. Restored Objects: When a document containing a `Site` was opened, the
   property constraints were not reapplied. This happened because the
   view provider's initialization logic was not being reliably triggered
   due to race conditions during the document deserialization process.

These issues are addressed now by a deferred initialization sequence:

- For New Objects: In `_ViewProviderSite.__init__`, constraint and
  default value setup is deferred using `QTimer.singleShot(0)`. The
  `restoreConstraints` method also now sets sensible defaults (e.g.,
  month 6, day 21) when it detects a new object.
- For Restored Objects: The data object's `_Site.onDocumentRestored`
  hook is now used as a trigger to start the view provider's
  initialization. This is a necessary workaround, as the `ViewProvider`
  lacks its own restoration hook. This method now ensures the view
  provider's properties are present and then schedules
  `restoreConstraints` to run via `QTimer`.

* BIM: add ArchSite GUI tests and fixtures

- Additionally clean up and document the CMakeLists.txt file for better
  maintainability and readability

* BIM: Enable GUI tests on CI

- The line to enable the BIM workbench has been commented out, as
  previously it occasioned a timeout error on CI
- The BIM GUI tests have been uncommented out to enable them
2025-10-05 11:47:56 +02:00
paul 960434f7e5 [ArchStairs] Fix Blondel Ratio and Winders (#24350)
* [ArchStairs] Fix Blondel Ratio and Winders

Fix #24065
Fix #24051

1. Blondel Ratio is not calculated, this if fixed now.  Blondel Ratio property is changed to Length following wiki's descripition.
2. Winders is not implemented as commented in wiki.  The property is not added at the moment until it is implemented.

* [ArchStairs] Fix Blondel Ratio and Winders - Remove old Property

For existing Stairs object, remove old property which is Float and add new propety which is Length.
2025-10-05 09:29:40 +02:00
Benjamin Nauck c4213b21ad Gui: Store visibility of status labels (quick measure and input hints) 2025-10-04 21:48:48 +02:00
Benjamin Nauck 99c24f1c2b Measure: Remove from menu + transfer ownership back
As discussed in 23399, discoverability is really poor as users doesn't know what Quick Measure is,
neither is it easy to find out as there's no visual feedback when toggling this feature.
The intension was to keep the command and only remove it from the menu, but that wasn't possible
due to ownership of quick measure object was inside the command. In addition the parameter had to
be renamed as well as mashing the qm button made them end up in an unknown state.

As the measurement can be disabled now by simply hiding the info text from context menu, we don't
need to keep the old toggling functionality.
2025-10-04 21:48:48 +02:00
Benjamin Nauck 6aff735482 Gui: Only measure with Quick Measure if showing in status bar 2025-10-04 21:48:48 +02:00
Benjamin Nauck e82b81c8c0 Gui: Make it possible to hide/show info labels in status bar 2025-10-04 21:48:23 +02:00
Bas Ruigrok 5e6fd1aeda Gui: Fix transform tool conflict with OpenSCAD navigation style 2025-10-04 13:50:53 +02:00
Bas Ruigrok 090a5a6995 Gui: Move isDraggerUnderCursor from Gesture to NavigationStyle 2025-10-03 20:01:29 +02:00
sliptonic eba0450647 Merge pull request #24392 from Connor9220/FixToolbitTopo
CAM: Fix Topo recomputation by only updating when values change in Toolbits
2025-10-03 12:20:10 -05:00
sliptonic 10f5cb7479 Merge pull request #24323 from tarman3/leadinout_fix6
CAM: LeadInOut - Fix ZeroDivisionError for LineZ
2025-10-03 11:30:24 -05:00
sliptonic ec0a78280b Merge pull request #24216 from tarman3/leadinout_threshold
CAM: LeadInOut - Fix RetractThreshold in Task panel
2025-10-03 11:28:59 -05:00
PaddleStroke 9c1454385e Assembly: Isolate joint components during selection and edit. (#23680)
* Core: Add signalBeforeOpenTransaction

* Assembly: Isolate

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

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

* Update src/App/AutoTransaction.cpp

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-02 21:07:06 -05:00
Chris Hennes c0c561d6b1 Merge pull request #24376 from pyro9/ReprFix
Improve the string representation of a few key FreeCAD Python objects.
2025-10-02 20:58:52 -05:00
dependabot[bot] 6c2a2116f7 Bump peter-evans/create-issue-from-file from 5.0.1 to 6.0.0
Bumps [peter-evans/create-issue-from-file](https://github.com/peter-evans/create-issue-from-file) from 5.0.1 to 6.0.0.
- [Release notes](https://github.com/peter-evans/create-issue-from-file/releases)
- [Commits](https://github.com/peter-evans/create-issue-from-file/compare/e8ef132d6df98ed982188e460ebb3b5d4ef3a9cd...fca9117c27cdc29c6c4db3b86c48e4115a786710)

---
updated-dependencies:
- dependency-name: peter-evans/create-issue-from-file
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-02 20:54:43 -05:00
Billy Huddleston 4a6991b771 CAM: Fix Topo recomputation by only updating when values change in Toolbits
- Use PathUtil.setProperty instead of direct setattr for schema properties to ensure proper FreeCAD notifications.
- Only update custom shape properties if the value has changed, reducing unnecessary recomputation.
- For SpindleDirection and Material, only update the property if the new value differs from the current value, and use PathUtil.setProperty for consistency.
- This prevents overwriting existing values with defaults and avoids triggering unwanted recomputation.
2025-10-02 18:56:53 -04:00
Chris Hennes f34f15dc60 Part/PD: Send current edit mode to cmdSetEdit 2025-10-02 17:49:24 -05:00
dependabot[bot] bae76a4dc0 Bump korthout/backport-action from 3.3.0 to 3.4.1
Bumps [korthout/backport-action](https://github.com/korthout/backport-action) from 3.3.0 to 3.4.1.
- [Release notes](https://github.com/korthout/backport-action/releases)
- [Commits](https://github.com/korthout/backport-action/compare/ca4972adce8039ff995e618f5fc02d1b7961f27a...d07416681cab29bf2661702f925f020aaa962997)

---
updated-dependencies:
- dependency-name: korthout/backport-action
  dependency-version: 3.4.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-10-02 11:38:37 -05:00
sliptonic 51ffac77cf Merge pull request #24372 from FreeCAD/speedUpPreCommitRun
Change black repo to black-pre-commit-mirror
2025-10-02 08:49:57 -05:00
Steven James 17e8092643 Make repr for a TaskDialog indicate the associated document. 2025-10-02 04:27:59 -04:00
Steven James 9ff4a40bc2 Fixing repr for App/Document and Gui/Document 2025-10-02 04:22:24 -04:00
Chris Hennes 04c466260c Gui: Ensure menus don't get moved inadvertently
Co-authored-by: depthoffocus <depthoffocus@users.noreply.github.com>
2025-10-01 21:46:39 -05:00
Chris Hennes 5cc7d1a869 Change black repo to black-pre-commit-mirror
Updated the pre-commit configuration to use the black-pre-commit-mirror repository instead of the original black repository. Also omit scanning the Fem examples directory.
2025-10-01 20:58:39 -05:00
Chris Hennes b08a0f87d6 Merge pull request #24108 from WandererFan/DxfDimensionExport
[TD]fix no dimension in DXF export
2025-09-30 18:55:55 -05:00
Chris Hennes 9d232222df Addon Manager: Add defusedxml dependency 2025-09-30 19:59:12 -03:00
Chris Hennes 1f57d10bdd Merge pull request #22894 from tetektoza/fix/22545_fix_ovp_being_validated_too_early
Sketcher: Unset labels that are below confusion point before enforcing
2025-09-30 16:07:32 -05:00
wandererfan 3d7db8fb83 [TD] Use isProjectGroupItem() in remaining cases
- isDerivedFrom<DrawProjGroupItem>() is no longer reliable due to smart
  view creation changes.
2025-09-30 13:56:45 -05:00
wandererfan bbb15ea940 [TD]fix dimension not exported to dxf 2025-09-30 13:36:30 -05:00
Chris Hennes 33dd8e2f45 Build: Don't remove the doc directory
It contains the ThirdPartyLibraries.html file.
2025-09-30 15:31:16 -03:00
paddle f90e73f64b Sketcher: Force OVP visibility for offset and scale. 2025-09-30 13:27:18 -05:00
Roy-043 fc5e6dcf8b PartDesign: iso10642-fine.json wrong M5 diameter
Compare iso10642.json:
https://github.com/FreeCAD/FreeCAD/blob/efbe579e25b993a9a26ef45491387a19b14d1f59/src/Mod/PartDesign/Resources/Hole/iso10642.json#L11
2025-09-30 13:25:20 -05:00
Chris Hennes b215adf723 Addon Manager: Sync with upstream 2025-09-23 2025-09-30 20:09:26 +02:00
PaddleStroke db00a9b8e2 Merge pull request #24162 from PaddleStroke/asm_linkgroup_asmlink
Assembly: Add support to Link groups in sub-assemblies.
2025-09-30 13:02:47 -05:00
Chris Hennes 60c8c51d49 Merge pull request #24178 from FlachyJoe/non-recursive-freeze
Core: Freeze state enhancement
2025-09-30 13:01:15 -05:00
wandererfan e8e5fc79ea [TD]prevent area dim crash on multiple faces 2025-09-30 12:59:17 -05:00
Chris Hennes efbe579e25 Merge pull request #24333 from PaddleStroke/patch-83
PartDesign: Pocket Through all: Taper should be writable and offset hidden
2025-09-30 11:51:52 -05:00
PaddleStroke 5264cb1f9e PartDesign: Pattern: Fix occurences not taken into account when pressing enter 2025-09-30 11:44:33 -05:00
PaddleStroke ef10f20351 Sketcher: Prevent non-edit toolbars from showing up when switching tab (#24202)
* Sketcher: Prevent non-edit toolbars from showing up when switching tab

* [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-09-30 11:36:27 -05:00
Michael Marais cbe93b3b56 Merge pull request #23915 from Mikestriken/project_utility_fix
Fixed createDocument() utility importing phantom '\.' files with 0 bytes
2025-09-30 11:04:08 -05:00
dependabot[bot] 32712dcd8e Bump github/issue-metrics from 3.23.3 to 3.24.0 (#24338)
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.23.3 to 3.24.0.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/c2ad23cdf3192065f868ff0ece4e91e4077a4f73...45a6cb314ddaa4c12eed570eb2739435d712d480)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.24.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-30 16:02:32 +00:00
Chris Hennes 703d9ebd12 Merge pull request #23735 from longrackslabs/feature/sketcher-hints-comprehensive-coverage-22282
Feature/sketcher hints comprehensive coverage 22282
2025-09-30 09:51:50 -05:00
Chris Hennes 2b1a3aedbe Merge pull request #23770 from PaddleStroke/patch-59
PartDesign: FeatureExtrude fix symmetric + custom dir
2025-09-30 08:55:18 -05:00
longrackslabs 99f27f1a56 Add 'or click to finish' to Sketcher_Dimension hints
After selecting first geometry, users can now see that they can
click empty space to finish the dimension and set its value,
rather than having to pick additional geometry.

Added PICK_SECOND_POINT_OR_EDGE_OR_CLICK_TO_FINISH constant and
updated all selection cases in DrawSketchHandlerDimension::getToolHints().
2025-09-30 08:47:43 -05:00
longrackslabs a940181998 Fix ConstrainSymmetric hint for point→edge→point workflow
Change 'pick symmetry point' to 'pick point' when the workflow is
point → symmetry line → point, since the final selection is a
regular point, not a special 'symmetry point'.
2025-09-30 08:47:43 -05:00
George Peden 1ac117f1c8 Add MODE_HINT to dimension tool
- Add MODE_HINT constant to DrawSketchHandlerDimension class
- Shows 'switch mode' hint for M key in dimension tool
- Addresses reviewer feedback for missing M key hint
2025-09-30 08:47:43 -05:00
George Peden abf9762abb Fix ConstrainSymmetric two points + symmetry point workflow
- Fix hint text to say 'pick symmetry line or symmetry point' for two points + symmetry point workflow
- Add missing sequence {SelVertexOrRoot, SelVertexOrRoot, SelVertexOrRoot} to allowedSelSequences
- Add case 8 to handle two points + symmetry point constraint creation
- Fix duplicate constraint creation by adding return statement in case 8
- Add getSelection().clearSelection() for consistency

Fixes reviewer comment #2 from PR #22282
2025-09-30 08:47:43 -05:00
George Peden b82408c545 Fix Sketcher Dimension hints - add context-aware hints based on selection
- Add PICK_POINT_OR_EDGE constant to DrawSketchHandlerDimension class
- Implement nuanced hints for Dimension tool based on selected geometry:
  - Empty selection: 'pick point or edge'
  - Single point/line/circle: 'pick second point or edge'
  - Multiple selections: 'pick second point or edge'
- Remove stray character causing build error
- Addresses feedback on issue #22282 for comprehensive Sketcher hints coverage
2025-09-30 08:47:43 -05:00
George Peden dbd72f9c60 Improve context-aware hints for Sketcher constraints
- ConstrainDistanceX/Y: Fix hints to show 'pick second point' instead of 'pick second point or edge' when first selection is a point
- ConstrainPerpendicular: Add context-aware hints for edge+point+edge workflow
- ConstrainTangent: Add context-aware hints for edge+point+edge workflow
- ConstrainSymmetric: Fix hints to show 'pick edge or second point' instead of 'pick edge or first point' when first selection is a point
- ConstrainSymmetric: Fix hints to show 'pick symmetry line' instead of 'pick symmetry line or point' for point+point+edge workflow

All changes are hint improvements only - no functionality changes to existing workflows.
2025-09-30 08:47:43 -05:00
George Peden 584472f779 Refactor: Replace all literal hint strings with constants
- Added class-level static constexpr constants for all hint strings
- Replaced all QObject::tr("%1 pick...") with constants in both DrawSketchHandlerGenConstraint and DrawSketchHandlerDimension classes
- Eliminates string duplication and improves maintainability
- Addresses Copilot's PR feedback on string refactoring
2025-09-30 08:47:43 -05:00
George Peden 8b36da6782 Refactor hint strings to use constants
- Add class-level constants for all hint texts
- Replace all hardcoded strings in static table and context-aware hints
- Eliminate duplication and improve maintainability
- Addresses Copilot PR review feedback on code duplication

All hint strings are now defined once and reused consistently.
2025-09-30 08:47:43 -05:00
George Peden 17533deb50 Add context-aware hints for remaining constraint tools
- Add context-aware hints for ConstrainPerpendicular
- Add context-aware hints for ConstrainTangent
- Add context-aware hints for ConstrainSymmetric
- All hints now remember user selections to provide appropriate guidance
- Covers all workflows mentioned in issue #22282 feedback
- Completes comprehensive coverage of missing constraint hints
2025-09-30 08:47:43 -05:00
George Peden 871ee4ca32 Add context-aware hints for ConstrainAngle tool
- Add special case for Sketcher_ConstrainAngle in getToolHints()
- Hints now remember what user has selected to provide appropriate guidance
- Step 0: 'pick edge or first point' (covers all workflows)
- Step 1: Context-aware based on first selection:
  - If point first: 'pick first edge' (point+edge+edge workflow)
  - If line first: 'pick second line or point' (line+line or edge+point+edge)
- Step 2: Context-aware based on selection history:
  - Point+edge+edge: 'pick second edge'
  - Edge+point+edge: 'pick second edge'
- Fixes part of issue #22282 - missing angle constraint hints
2025-09-30 08:47:43 -05:00
George Peden 582eae5ba3 Add missing hints for ConstrainRadiam tool
- Add hints entry for Sketcher_ConstrainRadiam in hints array
- ConstrainRadiam now shows 'pick circle or arc' hint like other radius/diameter tools
- Fixes part of issue #22282 - missing radius constraint hints
2025-09-30 08:47:43 -05:00
PaddleStroke 6d238a93e1 PartDesign: TaskExtrudeParameters : offset should not be visible for throughall 2025-09-30 10:19:26 +02:00
PaddleStroke d52260b2f4 PartDesign: FeatureExtrude: Taper should not be read-only when throughall. 2025-09-30 10:17:36 +02:00
pre-commit-ci[bot] 65b7b5d4bd [pre-commit.ci] pre-commit autoupdate
updates:
- [github.com/psf/black: 8a737e727ac5ab2f1d4cf5876720ed276dc8dc4b → af0ba72a73598c76189d6dd1b21d8532255d5942](https://github.com/psf/black/compare/8a737e727ac5ab2f1d4cf5876720ed276dc8dc4b...af0ba72a73598c76189d6dd1b21d8532255d5942)
- [github.com/pre-commit/mirrors-clang-format: 86fdcc9bd34d6afbbd29358b97436c8ffe3aa3b2 → 719856d56a62953b8d2839fb9e851f25c3cfeef8](https://github.com/pre-commit/mirrors-clang-format/compare/86fdcc9bd34d6afbbd29358b97436c8ffe3aa3b2...719856d56a62953b8d2839fb9e851f25c3cfeef8)
2025-09-29 19:31:32 -05:00
Sami Liedes b3e8ed7814 Gui/Application, QuarterWidget: request OpenGL compatibility profile (#23768)
On Wayland with Qt, the default OpenGL context often ends up being
OpenGL ES. ES is a stricter API based on the "core" profile and lacks
many legacy functions (e.g. glEnd). FreeCAD relies on some of these
functions, which work under Mesa’s permissive stack but fail outright
with NVIDIA’s proprietary drivers, resulting in a blank 3D view.

Fix this by explicitly requesting a desktop OpenGL compatibility
profile both before QApplication creation and in QuarterWidget. This
ensures the presence of the legacy entry points required by Coin/SoQt.

(NB: both requests appear to be necessary; a single change was not
sufficient in testing.)
2025-09-29 19:22:29 -05:00
tetektoza f2af5b7e7f Sketcher: Remove isSet checks that were replaced by hasFinishedEditing 2025-09-29 20:41:53 +02:00
dependabot[bot] e38a8d8eeb Bump actions/dependency-review-action from 4.7.3 to 4.8.0
Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 4.7.3 to 4.8.0.
- [Release notes](https://github.com/actions/dependency-review-action/releases)
- [Commits](https://github.com/actions/dependency-review-action/compare/595b5aeba73380359d98a5e087f648dbb0edce1b...56339e523c0409420f6c2c9a2f4292bbb3c07dd3)

---
updated-dependencies:
- dependency-name: actions/dependency-review-action
  dependency-version: 4.8.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-29 12:57:10 -05:00
PaddleStroke f67b854aad Assembly: Fix errors on solve when limits 2025-09-29 12:46:19 -05:00
sliptonic f45408053c CAM: Fixes #11163
Changes default scale from 2.0 to 3.0  Adds a parameter. DefaultArrowScale
to control.
2025-09-29 11:37:06 -05:00
Chris Hennes 8b759af395 Part: Fix 'Copy' item text 2025-09-29 18:17:12 +02:00
Ryan Kembrey e26a47d96c TechDraw: Fix selections not clearing when subelements are also selected 2025-09-29 11:11:34 -05:00
tarman3 4d5ad23cce CAM: LeadInOut - Fix ZeroDivisionError for LineZ 2025-09-29 19:09:15 +03:00
sliptonic 5349b819b0 Merge pull request #24046 from Connor9220/FixCAMSanityReport
CAM: Fix CAM Sanity Report
2025-09-29 11:09:06 -05:00
Kacper Donat 9d61aeb04b Compiler warning cleanup (#22997)
* Part: Remove unused arguments from isLinearEdge

* Gui: For Qt 6.5 and later, use ParseOptions in xml

* Gui: Remove unused variable from fuzzyMatch()

* Sketcher: Remove unused parameter from *ReferenceSelection

* PD: Remove unused parameter from *ReferenceSelection

* Part: Rename layout to avoid conflict

* FEM: remove unused variable from handlePropertyChange

* CAM: Eliminate C++11 compiler warning by explicitly defaulting copy
2025-09-29 18:05:58 +02:00
sliptonic b18a3b3536 Merge pull request #24148 from Connor9220/ConvertTappingOpToExperimental
CAM: Convert tapping operation to experimental feature, Add tap pitch / spindle speed, Fix toolbit schema bugs, update legacy linuxcnc post
2025-09-29 11:03:13 -05:00
sliptonic 68bb3b2af7 Merge pull request #24234 from Connor9220/FixTooLibrarySpindleDirection
CAM: Fix SpindleDirection and Material not updating from toolbit files; reduce log noise
2025-09-29 11:02:58 -05:00
Chris Hennes f7e6b94aba Merge pull request #21713 from 3x380V/pd_fixes
PartDesign: Random fixes
2025-09-29 10:54:46 -05:00
Chris Hennes 0b14e8e24b Assembly: Fix translatable strings (#24243)
* Assembly: Fix translatable strings

* [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-09-29 17:48:01 +02:00
Krzysztof 861470c6ac FEM: Restore and harmonize FEM Task selection hints (#23678)
* FEM: Add hint about selectable geometry types in 'Geometry reference selector'

* FEM: Harmonize selection hint in FEM Task dialogs

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

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

FEM: Add translation support, correct selectable geometry

FEM: Harmonize selection hint in FEM Task dialogs

* [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-09-29 10:43:23 -05:00
Roy-043 e1a3b1cbe7 BIM: Arch_MergeWalls: issue message when walls are not the same
Fixes #21228.
2025-09-29 17:28:53 +02:00
Chris Hennes 274cd094d8 Merge pull request #23230 from tetektoza/fix/22070_fix_deleting_compound_not_deleting_children
Core: Allow users deleting objects under group recursively
2025-09-29 10:14:11 -05:00
luzpaz 42cf50cc57 FEM: fix source comment typos
Fix various source comment typos introduced recently.
2025-09-29 08:47:20 -05:00
PaddleStroke 94750baa6b PartDesign: FeatureExtrude: single prism for modes that can 2025-09-29 13:24:55 +02:00
PaddleStroke a01cab21cc PartDesign: FeatureExtrude: Make single prism if both modes are length and no taper 2025-09-29 09:33:53 +02:00
captain0xff d8d32c1b3a Gui: set focus to the corresponding property when a gizmo is released 2025-09-28 21:39:34 -05:00
Kacper Donat dc2aec50d4 Sketcher: Do not force visibility of planes on edit
This updates the logic that had special handling for planes for the
temporary visibility feature of sketcher which was mishandled after move
to core datums.
2025-09-28 18:59:37 -05:00
Bas Ruigrok df2df0905d Don't inform Coin to use EGL for Coin 4.0.6+
Coin figures it out automatically starting from 4.0.6. Only for Coin 4.0.4 and 4.0.5 it is needed to explicitly tell Coin to use EGL.
2025-09-28 18:57:18 -05:00
marioalexis 633817ceac Fem: Add tensor components to calculator variables 2025-09-28 18:55:48 -05:00
tetektoza 9be5c97fcf Sketcher: Unset labels that are invalid only after user finished editing
As the title says, currently if user tries to type "0", nothing gets
typed because the OVP automatically invalidates the "0" as an invalid
value in most of the cases.

The solution to that is to only validate it if user has finished editing
OVP, not earlier when they are only typing.
2025-09-28 19:50:16 +02:00
marcuspollio 4393f3bd72 Draft: update Group icons (#23771)
* Draft: update Group icons

* Draft: update Group icons after feedback
2025-09-28 15:10:00 +02:00
Chris Hennes 75c8749189 GUI: Fix some translatable text (#24289) 2025-09-28 10:47:16 +02:00
tetektoza 247e725ad3 Part: Allow deleting children recursively
Add feature to allow deletion of all children of compounds and booleans.
2025-09-27 19:10:42 -05:00
tetektoza 8e00addabf Core: Allow deleting objects in group recursively
Add a special marker that will signal to VPs that they should delete
their children recursively under the group.
2025-09-27 19:09:55 -05:00
Kacper Donat d712537638 PartDesign: Fix crash on editing feature outside of body 2025-09-27 15:21:59 -05:00
Ladislav Michl 7a266b1d78 PartDesign: Microoptimize updateSpacings()
This also fixes "comparison of integer expressions of different
signedness: ‘int’ and ‘size_t’" warning.

Fixes: 5d2037c820 ("PartDesign: Transform rework")
2025-09-27 11:40:07 -05:00
Syres916 e77f181393 [Part] Fix Part Boolean operations Refine incorrectly set for new users (#24256)
* [Part] Fix Part Boolean operations Refine incorrectly set for new users

* [Part] update tests to specify Refine to be...

...false where necessary
2025-09-27 00:33:57 -05:00
luzpaz cfb1810d92 Docs: update stylesheet doc (fixes #22717) (#23056)
* Docs: update stylesheet doc (fixes #22717)
Fixes #22717

* Refined instructions to be more OS agnostic

* Update src/Gui/Stylesheets/FreeCAD.qss

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
Co-authored-by: Beep6581 <Beep6581@noreply.users.github.com>
2025-09-27 02:52:13 +00:00
Tiago-Almeida007 0d48351c9e Gui: Organize tree view preferences (#21867)
* feat #18649: Organize tree options in one single preference page
-Removed tree view related code from all DlgSettingsAdvanced files
-Added Font size and Item Background Padding to DlgSettingsUI

Co-authored-by: Tiago Cardoso <tiagomiguelcardoso@tecnico.ulisboa.pt>

* fix #18649: Organize tree options in one single preference page
-Added new line at the end of file DlgSettingsAdvanced.cpp
-Added new line at the end of file DlgSettingsAdvanced.py
-Added new line at the end of file DlgSettingsUI.ui
-Delete trailing space on file DlgSettingsAdvanced.py
-Delete extra line on file DlgSettingsAdvanced.h

Co-authored-by: Tiago Almeida <tiago.c.almeida@tecnico.ulisboa.pt>

* Gui: Remove over-advanced UI prefs

---------

Co-authored-by: Tiago Cardoso <tiagomiguelcardoso@tecnico.ulisboa.pt>
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-27 02:33:04 +00:00
wandererfan 919f5fd265 [TD]fix uncommanded leader position change 2025-09-26 21:24:49 -05:00
Chris Hennes 140de440cc Merge pull request #21541 from furgo16/bim-refactor-arch-iter-2
BIM: Arch module refactor, Arch.makeWindow documentation and tests - iteration 2
2025-09-26 19:58:49 -05:00
Roy-043 17f01bb88c BIM: fix linked document of BIM_Library task panel (#24169)
* BIM: fix linked document of BIM_Library task panel

Fixes #22437.

The task panel of the BIM_Library command would be linked to the active document, which would to be the temporary Viewer document if that option was checked. Closing that document in the `Insert` function would therefore also close the task panel resulting in errors for following code.

Additionally:
The code to close the temporary Viewer document was moved to the `Reject` function. Otherwise that document would stay open if the task panel was closed without inserting.
2025-09-27 00:54:31 +00:00
marioalexis 406c3ba42c PartDesign: Use AllowCompound user parameter along the workbench - fixes #23596 2025-09-26 19:50:21 -05:00
tetektoza 68b754effd Gui: Fix clarify selection menu HiDPI positioning issues
On HiDPI screens, the Clarify Selection context menu appears
far to the right of the intended position when triggered via
right-click, which was making it really problematic to select entities.

So the easiest solution is to apply `devicePixeLRatio` scaling when
converting the stored right-click postiion from device pixels to Qt
logical coordinates before calling `mapToGlobal()`.
2025-09-26 19:19:04 -05:00
Kacper Donat b3fd31b108 Gui: Render profile preview in proper coordinate space 2025-09-26 17:00:53 -05:00
wmayer 20a4dc3839 PD: Restore GUI commands for PartDesign datum objects
With PR 19114 the commands to create PD datum objects are replaced with
the counterparts of Part. However, PD datum objects are much more powerful
than the Part datum objects.
(see e.g. https://forum.freecad.org/viewtopic.php?p=806960)

So, this change brings these commands back to the task panel.
2025-09-26 23:46:27 +02:00
wmayer ab60695ef9 PD: Show commands in task panel when selecting (sub) shape binders
This fixes issue 19098
2025-09-26 23:46:27 +02:00
wmayer df5c75d6b0 PD: Improve groove feature
The only difference between groove and revolution is that for the former
the revolved face is removed from the base shape instead of added.

Thus, the code of the Revolution and Groove classes should be almost
identical. This allows it in a further step to refactor the code and
make a common base class.

This fixes issue 18842.
2025-09-26 23:46:25 +02:00
wmayer 4d80f3ec28 PD: Improve revolution feature
* Allow a minimum angle of 0.0 as this is needed in 'Two Angles' mode
* Set the default value of Angle2 to 0.0
* Check for valid input in 'Angle' and 'Two Angles' mode
* Replace the confusing enum labels 'Dimension' and 'TwoDimensions'
2025-09-26 23:45:53 +02:00
wmayer 5a3fafcc55 PD: Remove unneeded class member 'isApplying' from 'TaskHoleParameters' 2025-09-26 23:45:23 +02:00
wmayer cf0412b7e2 PD: Support of plane in linear pattern feature 2025-09-26 23:45:23 +02:00
wmayer a539e5e460 PD: Fix support of datum lines in draft 2025-09-26 23:45:23 +02:00
wmayer a2c5788a98 PD: SubtractivePipe Fails
Fixes issue 18003
2025-09-26 23:45:20 +02:00
wmayer 796f5b1cfd PD: Positive offset on a binder shouldn't turn holes into squares
Fixes issue 18776
2025-09-26 23:44:28 +02:00
Frank David Martínez M 05707c61fb Fix Refine in Cut Compound test 2025-09-26 16:12:56 -05:00
theo-vt a41159a043 Sketcher.Scale: Add case for distance of a single curve 2025-09-26 15:45:22 -05:00
Frank Martinez c3348bc823 Fix #24257: findSubShapesWithSharedVertex signature parsing 2025-09-26 15:38:19 -05:00
Chris Hennes 9f25cb9d40 Merge pull request #24201 from marioalexis84/fem-fix_plane_function
Fem:Fix plane manipulator - fixes #14523
2025-09-26 15:13:24 -05:00
Roy-043 5d26e2f0f6 BIM: prevent dialogs being opened twice
Fixes #20403
Partly fixes issue #17983

I have basically copied Yorik's solution (#22446), but have added a call to `raise_()`.
2025-09-26 15:09:38 -05:00
PaddleStroke 91017606aa Sketcher: Fix crash on Sketcher.Constraint (#24269)
* Sketcher: Fix crash on Sketcher.Constraint

* [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-09-26 20:08:08 +00:00
PaddleStroke af4ed78c01 Sketcher: Slot tool: fix redundant horizontal (#24248)
* Sketcher: Slot tool: clean vertical/horizontal mess.

* Update DrawSketchHandlerSlot.h

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

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

* Update DrawSketchHandlerSlot.h

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

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

* Clean removeRedundantHorizontalVertical

* [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-09-26 15:05:55 -05:00
marioalexis b9ab71e606 Fem: Fix memory leaks and error handling 2025-09-26 14:41:43 -05:00
Chris Hennes 16906e93db Merge pull request #24240 from mrpilot2/cmake_pch_mods_part_2
Mods: use CMake to generate precompiled headers on all platforms
2025-09-26 09:46:26 -05:00
Furgo b3147b6b11 BIM: DEBUG, disable part of the Gui tests 2025-09-26 12:07:23 +02:00
Furgo 09944fde79 BIM: set up TestArchGui, clean up CLI/GUI tests
- Also update TechDraw templates path after reorganization from https://github.com/FreeCAD/FreeCAD/pull/23719
2025-09-26 00:46:16 +02:00
Furgo 7994e411b7 BIM: ArchWindow, add unit tests
TODO: check comments on test_create_with_width_height_no_baseobj_initially
2025-09-26 00:46:01 +02:00
marioalexis84 3db74dee60 Fem: Remove pipeline from analysis highlighter - fixes #23466 (#23984)
* Fem: Remove pipeline from analysis highlighter - fixes #23466

* FEM: Clean up lint

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-25 22:06:51 +00:00
dependabot[bot] 370c9bc1c7 Bump actions/cache from 4.2.4 to 4.3.0
Bumps [actions/cache](https://github.com/actions/cache) from 4.2.4 to 4.3.0.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/0400d5f644dc74513175e3cd8d07132dd4860809...0057852bfaa89a56745cba8c7296529d2fc39830)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 4.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-25 16:14:51 -05:00
captain0xff a678d8ec7f Gui: hide the gizmos in case of any errors 2025-09-25 16:14:09 -05:00
marioalexis 014edacf1b App: Fix GroupExtension finding wrong group for objects 2025-09-25 15:52:43 -05:00
Billy Huddleston cbeb67b509 CAM: Convert tapping operation to experimental feature, Add tap pitch support, improve tapping logic, and update toolbit schema and legacy linuxcnc post
CAM/App/PathSegmentWalker.cpp
- Add G74 to drill/tap/bore G-code recognition for tapping cycles

CAM/InitGui.py
- Move CAM_Tapping command behind experimental feature flag
- Only group drilling/tapping commands if both are enabled

CAM/Path/Base/Generator/tapping.py
- Add pitch and spindle_speed parameters to tapping.generate
- Output S (spindle speed) and F (pitch) in generated G-code

CAM/Path/Op/Tapping.py
- Require Pitch property for tap tools and SpindleSpeed for tool controllers
- Pass pitch and spindle speed to tapping.generate
- Use SpindleDirection to determine right/left hand tap

CAM/Path/Post/scripts/linuxcnc_post.py
- Handle G84/G74 tapping cycles: convert pitch and spindle speed to feed rate
- Remove F and S from output and recalculate F as needed

CAM/Path/Tool/shape/models/tap.py
- Add Pitch property to ToolBitShapeTap schema
- CAM/Path/Tool/toolbit/models/tap.py
- Show pitch and rotation in tap tool summary
- Use is_imperial_pitch to format pitch as TPI or mm

CAM/Path/Tool/toolbit/util.py
- Add is_imperial_pitch utility to classify pitch as imperial or metric

CAM/Tools/Bit/375-16_Tap.fctb
- Remove unused parameters (Coating, Rotation, TPI, Type)
- Keep only relevant tap parameters for new schema
2025-09-25 16:26:03 -04:00
Kacper Donat 5bf0e30676 Gui: Check for every VP expiration in TaskAttacher 2025-09-25 14:09:07 -05:00
Billy Huddleston 695cb49345 CAM: Fix SpindleDirection and Material not updating from toolbit files; reduce log noise
- Change missing property log in shape/doc.py from warning to debug
- Ensure SpindleDirection property exists and is set, defaulting to "Forward"
- Ensure Material property exists and is set, defaulting to "HSS"
- Update SpindleDirection and Material from toolbit file parameters if provided
2025-09-25 13:21:57 -04:00
Furgo a9f8993237 BIM: Arch.makeWindow, expand docstring, add examples 2025-09-25 18:51:33 +02:00
Furgo 3e37cbcfc0 BIM: Arch.makeWindow, add type hinting 2025-09-25 18:51:33 +02:00
Chris Hennes 39d39f34c3 Update translations 2025-09-25 2025-09-25 17:25:13 +02:00
FEA-eng 702eb9f5af FEM: Update commands.py 2025-09-25 08:46:41 -05:00
Chris Hennes 864cde5aed Gui: Improve file corruption checks 2025-09-25 14:37:38 +02:00
Gaël Écorchard c32628c61c BIM: fix regression in DAE import, support for polylists (#24031)
* BIM: fix regression in DAE import, support for polylists

The support for non-triangular faces was remove in
commit 346c7581d4.
Now, the support for them is restored, by triangulating them
during the import (with a warning and changing the object name).

Signed-off-by: Gaël Écorchard <gael@km-robotics.cz>

* BIM: Remove translation calls console

Use raw strings for console messages, as they are usually not
translated.

---------

Signed-off-by: Gaël Écorchard <gael@km-robotics.cz>
Co-authored-by: Gaël Écorchard <gael@km-robotics.cz>
2025-09-25 14:28:05 +02:00
Furgo e4881dd92f Apply wording suggestions from code review
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-25 14:26:54 +02:00
Furgo 948916b888 BIM: enable live updates of the cut when changing placement 2025-09-25 14:26:54 +02:00
Furgo edf1c82b9f BIM: redesign rotation, center and resize controls 2025-09-25 14:26:54 +02:00
Furgo c60dadf147 BIM: separate scope and placement & visuals in Task panel 2025-09-25 14:26:54 +02:00
Furgo 1a2cd1befc BIM: Fix inverted cut direction for rotated SectionPlane
Rotating an ArchSectionPlane object caused its cutting effect to flip,
affecting both the live `CutView` and 2D projections. The
`_SectionPlane.execute()` method incorrectly tried to auto-correct the
orientation of a temporary plane before applying the object's final
placement. The fix refactors this to a "transform-then-verify" pattern:
the object's full `Placement` is now applied to the temporary plane
first, and only then is the resulting face's actual normal validated
against the intended normal from the `Placement`. This ensures the
`Shape` is always geometrically consistent with the `Placement`, making
the cut direction predictable at all angles.
2025-09-25 14:26:54 +02:00
Furgo 0c71c05c06 BIM: make cut view a toggle button 2025-09-25 14:26:54 +02:00
Furgo c64ed630cd BIM: Use correct icon for SectionPlane 2025-09-25 14:26:54 +02:00
Furgo 673f6664bd BIM: Change SectionPlane task panel button from OK to Close 2025-09-25 14:26:54 +02:00
Furgo 94d893bbe6 BIM: Fix SectionPlane's label being editable on double-click 2025-09-25 14:26:54 +02:00
Furgo 9b4f336eba BIM: add Cut View toggle on SectionPlane task panel 2025-09-25 14:26:54 +02:00
Roy-043 1d38352607 Draft: Update Draft example file (#23284)
* Draft: Update Draft example file

Fixes #23198

I have added osifont-lgpl3fe.ttf to the example folder. The ShapeString in draft_test_objects.FCStd references it using a
relative path. I am not sure if including the font here is allowed though.

Additionally: The example file showed up an error in view_wire.py. It is also used for fillets (which do not have a Points property).

* Updated

* Also use a relative path for the PAT file.
* Subfolder for the PAT and TTF files.

* Update CMakeLists.txt

* Update CMakeLists.txt

* Update CMakeLists.txt

* Update CMakeLists.txt

* Update CMakeLists.txt

* Update CMakeLists.txt
2025-09-25 14:21:12 +02:00
tarman3 aa7b8f977c CAM: LeadInOut - Fix RetractThreshold in Task panel 2025-09-25 11:37:39 +03:00
Furgo 26995b7f67 Theme: bring back visual feedback on toolbar button press
And also on toolbar button hover.
Fixes: https://github.com/FreeCAD/FreeCAD/issues/22747
2025-09-24 22:48:34 -05:00
PaddleStroke 001bab4439 Core: Add signalAboutToOpenTransaction (#24049)
* Core: Add signalAboutToOpenTransaction

* change name to squash

* Update AutoTransaction.cpp

* Update Application.h

* reorder

* Update AutoTransaction.cpp

* Update Application.h
2025-09-24 22:45:57 -05:00
Chris Hennes 80449715c6 Merge pull request #23729 from marioalexis84/fem-loggin_error
Fem: Better error handling in task panels with logging
2025-09-24 22:44:44 -05:00
Furgo 5a6af2e41f Assembly: fix delete shortcut parameter mismatch
Fixes: https://github.com/FreeCAD/FreeCAD/issues/23792
2025-09-24 22:19:00 -05:00
Chris Hennes 02bbc77f3c Merge pull request #23823 from marioalexis84/fem-remove_elmer_filter_parameter
Fem: Remove dependency of the ViewProviderFemPostObject class on user parameters
2025-09-24 22:18:19 -05:00
Chris Hennes 9fdbbe44ee Merge pull request #23803 from 3x380V/py
Py3.13: fix warnings
2025-09-24 22:16:30 -05:00
chris 0f6d00d2a5 fix issue #23829 build with boost v1.89 and greater 2025-09-24 22:12:47 -05:00
matt-git 06ad520851 Fix shortcuts for grouped Python commands
- Add shortcut setting for individual actions in PythonGroupCommand::createAction()
- Update PythonGroupCommand::languageChange() to include default command shortcut in group tooltip
- Fix variable redefinition error in languageChange() function
- Ensure shortcuts work and display in tooltips for grouped commands like Arch_Nest
2025-09-24 22:12:04 -05:00
marioalexis 8547e798fb CMake: Fix Eigen3 version search 2025-09-24 21:56:56 -05:00
Markus Reitböck 2ce0323b8f cleanup remaining implementations of precompiled headers 2025-09-24 20:08:57 +02:00
Markus Reitböck abc6b9e7d0 Test: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:57 +02:00
Markus Reitböck 2150afc470 Sandbox: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:57 +02:00
Markus Reitböck b864ccda60 CAM: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:56 +02:00
Markus Reitböck b15f3c1155 Robot: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:56 +02:00
Markus Reitböck 8fa48b25b4 Part: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:56 +02:00
Markus Reitböck ba03cf1ed6 JtReader: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:55 +02:00
Markus Reitböck 499742eea2 Draft: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:54 +02:00
Markus Reitböck 550786e6b0 Cloud: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-24 20:08:54 +02:00
PaddleStroke 5194dfc18a Assembly: fix onChanged crash 2025-09-24 10:59:41 -05:00
sliptonic 902079af20 Merge pull request #24167 from pmjdebruijn/cam-clearingpattern
CAM: fix PocketShape OffsetPattern broken by #23649
2025-09-24 10:48:30 -05:00
marioalexis ca286fb5be Fem: Set autoscale to false in Plane function and remove unnecessary code 2025-09-24 12:26:10 -03:00
marioalexis b23491901f Fem: Align plane translator to Z-axis 2025-09-24 12:26:10 -03:00
PaddleStroke 2aa8f133f3 Sketcher: Fix crash on constraint selection 2025-09-24 10:21:22 -05:00
PaddleStroke c384a52fa5 Feature Extrude: Make Length mode act as it did before. 2025-09-24 09:22:05 +02:00
PaddleStroke 155edc0f53 Sketcher: Fix is active. (#24124)
* Sketcher: Fix is active.

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

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

* Sketcher: Delint and compiler warning cleanup

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Chris Hennes <chennes@gmail.com>
2025-09-23 19:10:44 -05:00
PaddleStroke 27806651b4 Assembly: Fix subassembly linkgroups not moving with dragger 2025-09-23 19:07:25 -05:00
Chris Hennes b06bafe3cd libE57Format: Check for IPO before enabling 2025-09-23 17:46:18 -05:00
tarman3 7205191f81 CAM: Old simulator - Fix z for G2,G3 2025-09-24 00:34:52 +03:00
Chris Hennes 4b98ebe4f2 libE57Format: Remove gtest submodule 2025-09-23 16:20:44 -05:00
Florian Foinant-Willig 09ab65ce1a Core: freeze is no more recursive on children 2025-09-23 22:42:56 +02:00
Florian Foinant-Willig d15d9948bc Core: set properties of frozen object read-only 2025-09-23 22:42:14 +02:00
Markus Reitböck 015896f4e4 MeshPart: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:36 +02:00
Markus Reitböck 5b6a0b1852 PartDesign: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:36 +02:00
Markus Reitböck cfe0d9ffac Surface: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:36 +02:00
Markus Reitböck 914f6bec44 ReverseEngineering: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:35 +02:00
Markus Reitböck 93830929ae Measure: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:35 +02:00
Markus Reitböck 4bc92384b7 Inspection: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:35 +02:00
Markus Reitböck 7051848d10 Import: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:35 +02:00
Markus Reitböck 59724846e3 Assembly: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 22:39:34 +02:00
Chris Hennes 86048e7482 libE57Format: Accumulated FreeCAD changes before subtree 2025-09-23 14:50:19 -05:00
Chris Hennes 0da017a6f9 Merge commit '82927817b878295060edd8fc57b3e384404dc277' as 'src/3rdParty/libE57Format' 2025-09-23 14:20:50 -05:00
Chris Hennes 82927817b8 Squashed 'src/3rdParty/libE57Format/' content from commit d51a32d6ab7
git-subtree-dir: src/3rdParty/libE57Format
git-subtree-split: d51a32d6ab7c5dde5e1c68d0ec8ec61d980f06a3
2025-09-23 14:20:50 -05:00
Chris Hennes 11f6f498ab 3rdParty: Remove original libE57Format 2025-09-23 14:17:47 -05:00
Ryan Kembrey e9ce06155d TechDraw: Fix double drag in projection groups 2025-09-23 13:47:15 -05:00
luzpaz d092a94902 Techdraw: fix dialog text in Gui/Command.cpp (#24165) 2025-09-23 18:47:02 +00:00
dependabot[bot] 520dafa03c Bump prefix-dev/setup-pixi from 0.9.0 to 0.9.1
Bumps [prefix-dev/setup-pixi](https://github.com/prefix-dev/setup-pixi) from 0.9.0 to 0.9.1.
- [Release notes](https://github.com/prefix-dev/setup-pixi/releases)
- [Commits](https://github.com/prefix-dev/setup-pixi/compare/fef5c9568ca6c4ff7707bf840ab0692ba3f08293...194d461b21b6c5717c722ffc597fa91ed2ff29fa)

---
updated-dependencies:
- dependency-name: prefix-dev/setup-pixi
  dependency-version: 0.9.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-23 13:43:39 -05:00
Pascal de Bruijn 3e6eacbf76 TechDraw: reorganize Templates (#23719) 2025-09-23 13:40:13 -05:00
wandererfan 22af5df757 [TD]fix FileChooser mode in preferences 2025-09-23 13:00:44 -05:00
theo-vt c6c084f22c Sketcher: fix split breaking sketch (#23711)
* Sketcher: Scale: Reorder operations and delete original modified constraints to ensure validity

* Sketcher: replace boolean parameters for deletion with enum and expose solver override on some deletion functions in the python API

* Use correct flag in ::delGeometry

* Set default value of false to noSolve

* Sketcher: autoscale: use deleteAllGeometry

* Sketcher: Scale: revert to checking constraints for geoId validity and handle horizontal&vertical

* Sketcher.Split: Avoid early solve that can break sketch

* Avoid reintroducing a typo

* [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-09-23 12:00:36 -05:00
matthiasdanner 5961651547 Sketcher: Display non-empty Sketch when having external geometry (#23660) 2025-09-23 11:58:26 -05:00
Roy-043 ae29b67041 Part: fix copy_visual_attributes in BOPFeatures.py
Fixes #23900.

The ShapeAppearance related code should be removed. It is atypical that the result of a boolean operation has the same number of faces as one of its source objects, therefore simply applying its ShapeAppearance to the new object does not make sense in most cases.

The ShapeAppearance of Fusion objects gets overwritten by other code. For Cut objects this does not happen anymore (Used to happen in V0.21).
2025-09-23 11:30:08 -05:00
PaddleStroke ff1bde69fc Assembly: Prevent crash when link to linkgroup in subassembly (#24125)
* Assembly: Prevent crash when link to linkgroup in subassembly

* ViewProviderAssembly: Additional crash failsafe.
2025-09-23 11:06:01 -05:00
PaddleStroke e72834b94c Assembly: Fix LinkElement dragger 2025-09-23 10:39:28 -05:00
Pascal de Bruijn a3ebead67f CAM: fix PocketShape OffsetPattern broken by #23649 2025-09-23 17:25:44 +02:00
sliptonic 66c7f82f4a Merge pull request #22336 from dbtayl/fix_22177
[CAM] Correctly process Adaptive extensions
2025-09-23 09:24:01 -05:00
sliptonic a7abaaef23 Merge pull request #23575 from tarman3/stock1mm
CAM: Fix stock create for flat objects
2025-09-23 09:22:30 -05:00
sliptonic 4c04586d1e Merge pull request #21756 from papaathome/CAM-fix-for-3Dsurface,-rotational-path,-#21556
CAM: Update PathUtils.py
2025-09-23 09:21:41 -05:00
sliptonic fc71a76f50 Merge pull request #24070 from tarman3/leadinout_fix3
CAM: LeadInOut - Remove useless var
2025-09-23 09:20:59 -05:00
sliptonic 91489bcf18 Merge pull request #24138 from pmjdebruijn/cam-stepover
CAM: Pocket sensible default StepOver
2025-09-23 09:20:17 -05:00
sliptonic 73bbaac919 Merge pull request #24141 from Connor9220/FixPropertyBagEnum
CAM: Fix group dropdown showing individual letters by ensuring groups is a list
2025-09-23 09:19:30 -05:00
Chris Hennes d1ca523ca7 Merge pull request #24107 from mrpilot2/cmake_pch_mods
Mods (Part 1): use CMake to generate precompiled headers on all platforms
2025-09-23 08:35:43 -05:00
PaddleStroke c3707cc4a5 PartDesign: Enable child reorder
Enable dragging a sketch within a body.
2025-09-23 00:03:49 -05:00
marioalexis def22ad234 Fem: Better VTK version check 2025-09-22 22:46:20 -05:00
wandererfan c75bb47bff [TD]fix balloon auto-placement 2025-09-22 22:10:55 -05:00
PaddleStroke d5db01d3d4 Assembly: Simulation: Fix motion double click (#23778)
* Assembly: Simulation: Fix motion double click

* [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-09-22 21:22:29 -05:00
Markus Reitböck c3805ecf4a fix duplicate include guards in precompiled headers 2025-09-23 00:51:00 +02:00
Markus Reitböck c1be416c7f Fem: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 00:51:00 +02:00
Markus Reitböck ef670e7880 Sketcher: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 00:51:00 +02:00
Markus Reitböck 0019739095 TechDraw: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 00:50:59 +02:00
Markus Reitböck 62b915ee7b Spreadsheet: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
 should be considered an optimization, not a requirement. In particular, do not explicitly include a
 precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
 generated precompile header on the compiler command line instead. This is more portable across
 the major compilers and is likely to be easier to maintain. It will also avoid warnings being
 generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-23 00:50:59 +02:00
PaddleStroke b905c0dd95 Link: make OverrideMaterial use the per-face override. (#23544)
* Link: make OverrideMaterial use the per-face override.

* Fix small issue on per face transparency

* update names

* Update ViewProviderExt.cpp
2025-09-22 22:47:12 +00:00
marioalexis 0c5746fe7a Fem: Remove dependency of the ViewProviderFemPostObject class on user parameters 2025-09-22 18:27:18 -03:00
marioalexis b9129f4453 Fem: Add upstream vtkCleanUnstructuredGrid class source files 2025-09-22 18:27:18 -03:00
marioalexis 3e1741dfea Fem: Move FemFrameSourceAlgorithm class to its own source files 2025-09-22 18:27:18 -03:00
Markus Reitböck f323323e8b Web: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-22 23:17:40 +02:00
Markus Reitböck 13c8b52a6a Mesh: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-22 23:17:40 +02:00
Markus Reitböck a6f7cb950a Points: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-22 23:17:40 +02:00
Markus Reitböck 412b72d8d6 Start: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-22 23:17:39 +02:00
Markus Reitböck 05a706697b Material: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-22 23:17:39 +02:00
Billy Huddleston c2d8077d96 CAM: Fix CAM Sanity Report
Fix base template substitution and improve tool/op formatting in sanity report, also update HTML/CSS and image handling.

- Major HTML/CSS refactor for CAM Sanity Report template:
  - Rewrote HTMLTemplate.py with modern, responsive CSS, semantic HTML, and accessibility improvements.
  - Added CSS reset, responsive image handling, and improved table/list styling.
  - Introduced .heading-container and .top-link for right-aligned "Top" navigation links on all major sections and tool headers (hidden in print).
  - Updated all section and tool headers to use new navigation and layout.
  - Cleaned up legacy markup, removed inline styles, and standardized variable substitution using string.Template syntax (${key}, ${val}).
  - Updated base_template in HTMLTemplate.py to use string.Template syntax (${key}, ${val}) instead of %{key}, %{val} for correct variable substitution.

- Enhanced image generation and embedding:
  - Updated ImageBuilder to support high-DPI (800x800) images and direct byte output for embedding.
  - All report images (base, stock, datum, tool) now use in-memory bytes for embedding when possible.
  - Tool images support a toggle for using toolbit thumbnails or fallback head-on renders.
  - ReportGenerator now embeds images as base64 when requested, with correct HTML tags.

- Improved squawk, tool, and operation data formatting:
  - Squawk dates now use localized string formatting.
  - Tool diameter and feedrate now use .UserString for better display.
  - Spindle speed now formatted as integer with "rpm" suffix.
  - Operation feed and speed values also use .UserString and "rpm" formatting.
  - Fixed _format_bases in ReportGenerator.py to iterate over base_data.items() and pass {"key": key, "val": val} to the template, ensuring all bases are listed correctly.
  - General code cleanup and improved maintainability throughout the CAM Sanity reporting stack.
2025-09-22 13:44:53 -04:00
Billy Huddleston 69ba0d2241 CAM: Fix group dropdown showing individual letters by ensuring groups is a list
- Add type check in PropertyCreate to wrap CustomPropertyGroups as a list if not already
- Prevents dropdown from displaying each character of a string as a separate group option
2025-09-22 12:59:26 -04:00
tarman3 544605bde7 CAM: LeadInOut - Remove useless var 2025-09-22 19:50:11 +03:00
sliptonic 3ffb861d11 Merge pull request #23892 from alihantadal/feature_23649_update_confusing_nomenclature_offset_pattern
CAM: Improve confusing nomenclature: Offset Pattern (#23649)
2025-09-22 11:42:31 -05:00
sliptonic 873210d190 Merge pull request #23957 from tarman3/leadinout_fix
CAM: LeadInOut - Fix for rapid move in end
2025-09-22 11:33:12 -05:00
PaddleStroke 2e5b02e52c Link: Fix Selectable (#23567)
* Link: Fix Selectable

* to squash

* squash

* squash
2025-09-22 18:25:16 +02:00
xtemp09 aeddcaec27 Remove unused file 2025-09-22 11:20:26 -05:00
Chris Hennes a23bd23159 Gui: Remove references to the Addon Manager if no Std_AddonMgr (#23167)
* Gui: Remove references to the Addon Manager if no Std_AddonMgr

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

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

* Gui: Switch to disabling controls rather than hiding

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-22 18:20:07 +02:00
Kacper Donat 707ee60d64 Gui: Fix transform of link sub-elements 2025-09-22 11:17:04 -05:00
Chris Hennes 29c18019ae Merge pull request #23710 from kadet1090/fix-transform-basefeature-outside-body
Gui: Add handling for BaseFeatures outside of Body edge case
2025-09-22 11:15:53 -05:00
André Althaus 1b799ad355 PartDesign: Fix mirror Add/remove buttons 2025-09-22 11:12:31 -05:00
MisterMakerNL 26863fe895 Remove default close icon from OverlayToolButton styles
Eliminates the default and hover close icon image assignments for Gui--OverlayToolButton in all theme and overlay QSS files. This change likely delegates icon handling to a different mechanism or improves theme consistency.
2025-09-22 11:11:40 -05:00
Alfredo Monclus 0dc6cbd16f PD: hole prefer finding closest diameter if pitch is 0 2025-09-22 11:10:54 -05:00
Alfredo Monclus 7faf899b8d PD: fix hole thread depth being reset when changing to through all
the property is correctly updated by the updateThreadDepthParam below
2025-09-22 11:09:27 -05:00
Chris Hennes f6128e5fab Merge pull request #24113 from sliptonic/versions
[CAM]: Asset versions and Various Fixes
2025-09-22 11:04:09 -05:00
matthiasdanner 46ec53f4da Fix "Show only Visible Constraints" option (#23187)
Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
2025-09-22 10:54:24 -05:00
Pieter Hijma 9d11551972 Merge pull request #23648 from pieterhijma/fix-enabled-ok-expr-editor
Gui: Fix issues with Expr dialog with VarSets
2025-09-22 10:51:35 -05:00
theo-vt 7a672a3207 PartDesign: Hole: Print error when no axis was found (#23659)
* PartDesign: Hole: Print error when no axis was found

* Remove unrelated string update
2025-09-22 10:47:20 -05:00
Pascal de Bruijn 2ce559834b CAM: Pocket sensible default StepOver 2025-09-22 17:46:16 +02:00
Chris Hennes 90e9533df3 Merge pull request #23709 from marioalexis84/fem-solver_file_chooser
Fem: Fix use of file chooser Qt signals in solvers preferences.
2025-09-22 10:41:42 -05:00
Chris Hennes da380d8b64 Merge pull request #24017 from sliptonic/betterunitschema
[CAM] change dialog to allow directly switching unit schema
2025-09-22 10:40:24 -05:00
marioalexis df82e7b71c Fem: Do not allow selection of external objects for analysis objects - fixes #23834 2025-09-22 10:38:01 -05:00
David Kaufman a85f53d0bb [CAM] reorder job tabs to put Setup first 2025-09-22 10:37:27 -05:00
drwho495 9f2d212b12 Toponaming: Don't add empty tags past the threshold 2025-09-22 10:35:13 -05:00
Roy-043 99812e3ed8 Draft: fix snapper lagging (#24081)
* Draft: fix snapper lagging

The `WorkingPlane.get_working_plane()` function is too slow to be called repeatedly by `_get_wp`. That function has been reverted to what it was before #19728.

* Draft: fix snapper lagging

Using WorkingPlane.get_working_plane(update=False) instead of reverting.
2025-09-22 17:31:24 +02:00
Paul Lee 3569e77172 [ArchCurtainWall] Regression Curve Support
Fix https://github.com/FreeCAD/FreeCAD/issues/23945

"Arch_CurtainWall results in an error when trying to create it based on a sketch consisting of spline or arc."

This fixes the regression introduced in -
https://github.com/FreeCAD/FreeCAD/commit/147e97d40740230e59f17397652cc8811ed98344#diff-b4849bbc0941a0f60f25d13c40d4bfeca94171f55bd78a6196362343c3fdcf6fR287
2025-09-22 17:30:35 +02:00
Roy-043 d666e8db11 BIM: fix material handling of equipment 2025-09-22 17:26:58 +02:00
Chris Hennes 4ff209197f Merge pull request #23535 from pieterhijma/prop-view-expansion
Gui: Property View Expand/Collapse
2025-09-22 09:20:49 -05:00
PaddleStroke 3872d0682d Sketcher: Improve circle constraint position (#23569)
* Make prevCursorPosition protected so tools can use it

* DrawSketchHandlerCircle : Position constraint on prevCursorPosition

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

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

* [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-09-22 09:01:29 -05:00
pre-commit-ci[bot] af592924b6 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-09-22 13:51:05 +00:00
sliptonic 21fa5facbf codeQl and suggestions from discussion. 2025-09-22 08:47:48 -05:00
sliptonic 9c81c71728 fix default library name on import 2025-09-21 13:32:31 -05:00
Chris Hennes 465bd7ef5c Base: Refine directory permissions test 2025-09-21 13:16:35 -05:00
sliptonic 260aa3abf1 refactor migration 2025-09-21 13:14:13 -05:00
sliptonic fbd81cf4f8 Versioning directories 2025-09-21 12:01:27 -05:00
sliptonic f65a826b08 library and bit import improvements 2025-09-21 12:01:27 -05:00
sliptonic 2dee048f0e template directory to camassets 2025-09-21 12:01:27 -05:00
Ryan Kembrey eb58e2e343 TechDraw: Fix vertices hiding on cosmetic object removal 2025-09-22 01:01:33 +10:00
Furgo 7640a03cc8 Sketcher: improve Make Internals property tooltip (#23636)
* Sketcher: improve Make Internals property tooltip

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

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

* Sketcher: reword final MakeInternals tooltip

* Sketcher: apply final code review suggestion

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-21 08:24:30 +00:00
sliptonic f51893fbc6 Merge pull request #24087 from chennes/fixIsVersionedPathPythonWrapper
App: Fix the Python wrapper for isVersionedPath
2025-09-20 14:17:29 -05:00
Chris Hennes 6a8cfed1d6 App: Fix the Python wrapper for isVersionedPath 2025-09-20 11:46:11 -05:00
sliptonic 636bd90d4d Merge pull request #23585 from chennes/extractVersionMigrator
Gui: Improve version migration UX
2025-09-20 10:01:40 -05:00
captain0xff 5be668b696 Gui: fix a lifetime issue with the draggers 2025-09-20 14:03:33 +02:00
tarman3 4f955a8b2a CAM: LeadInOut - Fix SafeHeight 2025-09-19 23:06:01 +03:00
tarman3 37eefde380 CAM: LeadInOut - Fix for path without rapid move in the end 2025-09-19 22:59:10 +03:00
sliptonic 4911c23d1f Merge pull request #23718 from pmjdebruijn/cam-pocketshape-offset
CAM: PocketShape defaults to Offset and 50% StepOver
2025-09-19 14:27:02 -05:00
pre-commit-ci[bot] dfb3ae2ef4 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-09-19 19:17:09 +00:00
sliptonic b7153e12e0 [CAM] Robustly test schemas to find the ones that work.
Robustly test current schema.

Fixes #22549
2025-09-19 14:14:08 -05:00
sliptonic 5f909452d2 [CAM] change dialog to allow directly switching unit schema 2025-09-19 14:12:50 -05:00
sliptonic 31d609eec8 Merge pull request #23720 from davidgilkaufman/leadinout_migration
[CAM] add missing migration from intermediate version for lead in/out dressup
2025-09-19 11:29:38 -05:00
sliptonic 8df2a54ccd Merge pull request #21578 from lagnat/main
CAM: Dragknife dressup adds unnecessary maneuvers
2025-09-19 11:24:43 -05:00
matt-taylor-git 38785ddd96 Fix: Update tooltip for grouped commands (#24043)
When a command is part of a toolbar group, the tooltip for the group's button was not correctly updated with the shortcut of the selected command. This was happening because the tooltip generation was using the shortcut of the group itself, not the selected child command.

This commit fixes the issue by ensuring that the tooltip of the group action is updated with the full tooltip of the child action, which already contains the correct shortcut information. This is done in both 'ActionGroup::onActivated' (for when a new tool is selected) and 'ActionGroup::setCheckedAction' (for the initial default tool).
2025-09-19 15:20:39 +00:00
Roy-043 6ce59d2475 Draft: fix working plane tooltip (#24040)
* Draft: fix working plane tooltip

Related to #24033.

* Update WorkingPlane.py: remove trailing blank line
2025-09-19 09:17:45 -05:00
paddle 9ba65136d1 Core: Add beforeDelete python interface. 2025-09-19 09:13:20 -05:00
PaddleStroke 750c2a0c4d Sketcher: Offset: fix bad arcs (#24053) 2025-09-19 09:09:22 -05:00
PaddleStroke 6e4d2a94d5 Core: GeoFeature::getPlacementFromProp prevent potential crash 2025-09-19 08:40:06 -05:00
luzpaz ea08cb6776 BIM: Pin upstream pyshp shapefile.py URL to version 2.4.1
This is the safest solution for now until someone can vet the upstream breaking changes (https://github.com/GeospatialPython/pyshp/blob/master/README.md#breaking-changes)
2025-09-19 09:58:43 +02:00
luzpaz d9124497d3 BIM: Update shapefile import URL to latest version
Fixes #23911
2025-09-19 09:58:43 +02:00
Chris Hennes 929bd5090b App: Sanitize all paths for null characters (#23821)
* App: Sanitize all paths for null characters

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

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

* Apply suggestions from code review

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-09-18 17:37:33 +00:00
Chris Hennes a63cbd7057 Gui: Fix ignored font preference 2025-09-18 11:45:45 -05:00
dependabot[bot] dd08f6c845 Bump github/issue-metrics from 3.23.2 to 3.23.3
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.23.2 to 3.23.3.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/e8f19041d9996b64cd5eebd653f065adb6d0e195...c2ad23cdf3192065f868ff0ece4e91e4077a4f73)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.23.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-18 16:00:14 +02:00
Furgo 0bea8ac10d CI: run exclusively GUI tests in the GUI test steps (#23933)
* CI: run exclusively GUI tests in the GUI test steps

* Fix linter error

Fix the unsupported operand type(s) for | (unsupported-binary-operation) linter error. It appears the linter uses or assumes Python <3.10.

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

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

* CI: move __future__ import to the top of the module...

... to fix linter error.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-18 14:39:58 +02:00
jffmichi f31bd4a1c0 PartDesign: fix crash when creating new sketch 2025-09-17 22:34:00 -05:00
sliptonic c9e7da359a Fixes #23015
The standard in FreeCAD is that workbench preference pages get loaded when the module gets loaded.
That behavior was altered by PR 21981 which attempted to load CAM preference pages at startup even if CAM was not loaded.
The result was that pages were only partially loaded and the result was a confusing mess.

There is some discussion about future enhancements to allow workbench preferences to be loaded early.
When that is implemented, CAM will adjust to be compliant with FreeCAD standard.

This effectively revertts PR #21981
2025-09-17 18:21:16 -05:00
sliptonic 79640fd18a Merge pull request #23885 from chennes/pythonInterfaceToApplicationDirectories
App: Add Python interface to ApplicationDirectories
2025-09-17 18:11:41 -05:00
Chris Hennes 8f128f21f9 Tests: Update to match new behavior 2025-09-17 17:02:35 -05:00
Pieter Hijma ec6cadc01d Gui: Fix segfault DlgPropertyLink
In some cases FreeCAD can segfault when signals to the selection model
aren't blocked.
2025-09-17 16:50:24 -05:00
theo-vt fa2e5cd5fe Sketcher: Use the right delete flag for delConstraints 2025-09-17 16:42:40 -05:00
sliptonic 12a7151806 Merge pull request #23724 from davidgilkaufman/adaptive_reenable_profile
[CAM] regression fix: re-enable adaptive profile mode
2025-09-17 16:41:51 -05:00
Chris Hennes a6c5e9f08e App: Remove manual PCH entries 2025-09-17 16:18:10 -05:00
Chris Hennes b64b0f528b App: Address reviewer comments 2025-09-17 16:08:07 -05:00
Chris Hennes cdb4da3cc7 Gui: Address review comments 2025-09-17 15:45:07 -05:00
sliptonic a8c1c2f9dd Merge pull request #23902 from deimi/fix-import-snapmaker-post
CAM: fix library import in snapmaker postprocessor
2025-09-17 15:43:50 -05:00
Pascal de Bruijn d1f5437002 Material PMMA generic (#24006)
* Materials: Add PMMA-Generic

* Materials: Add PMMA-Generic to CMakeLists

* Materials: Fix PMMA-Generic Description
2025-09-17 18:54:32 +00:00
Pascal de Bruijn 255aaabf7b Materials: Update Aluminum-6061-T6 (#23977)
* Materials: Update Aluminum-6061-T6

* Materials: Update Aluminum-6061-T6 fixups
2025-09-17 12:54:47 -05:00
Chris Hennes eed3e09792 Gui: Migration complete wording tweak 2025-09-17 12:16:24 -05:00
Kacper Donat bc01dc17a4 Gui: Support for default and flat buttons in QSS 2025-09-17 12:08:26 -05:00
Chris Hennes 909464c17b Gui: Add window title 2025-09-17 12:07:00 -05:00
Chris Hennes 26ba6969f6 Gui: Migration UI take 2 2025-09-17 10:43:16 -05:00
Chris Hennes 3dd12e5da1 Gui: Improve version migration UX 2025-09-17 10:43:16 -05:00
captain0xff 2cab5e7b64 Gui: refactor gizmo attachment code 2025-09-17 15:46:35 +02:00
Pascal de Bruijn fcd9a416d2 Materials: Add Aluminum-7075-T6 (#23976) 2025-09-17 08:37:07 -05:00
Roy-043 1c591cd43a Sketcher: fix some prefs texts (#23992)
* Sketcher: fix some prefs texts

* Sketcher: fix some prefs texts
2025-09-17 14:50:26 +02:00
Ryan Kembrey e91751bceb TechDraw: Update missed UI strings to Title Case 2025-09-17 14:50:17 +02:00
Roy-043 bac49e4659 Sketcher: context menu of Elements section in task panel to Title Case 2025-09-16 22:38:23 +02:00
Roy-043 4bb387dd0b Sketcher: titles of parameter sections to Title Case (#23936)
* Sketcher: titles of parameter sections to Title Case

* Update src/Mod/Sketcher/Gui/DrawSketchHandlerBSpline.h

Co-authored-by: Max Wilfinger <6246609+maxwxyz@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: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-16 21:03:16 +02:00
Pieter Hijma ade4e4d96a Gui: Enable single click expand property editor 2025-09-16 11:47:40 +02:00
Pieter Hijma 8e1f983e37 Gui: Create a Property View submenu for expansion
The Property View's context menu has a submenu for property expansion
that allows you set the property expansion to default (remembers state),
to expand all and to collapse all.  Then there are toggles for
default/auto expand/auto collapse that always collapses or expands or
remembers the state.
2025-09-16 11:47:22 +02:00
Alex Tran 76e43efdc6 Read auto collapse user preferences 2025-09-16 11:29:49 +02:00
Alex Tran 2c9056255a Expand/Collapse Property Editor 2025-09-16 11:29:48 +02:00
Chris Hennes 29c69a4689 Update translations 2025-09-15 2025-09-16 09:55:13 +02:00
FEA-eng 29dc9ebcdb Fix typos in the strings reported in Crowdin (#23956)
* BIM: Update dialogWelcome.ui

* BIM: Update dialogWelcome.ui

* Mesh: Update Command.cpp

* MeshPart: Update Tessellation.cpp

* Mesh: Update Selection.ui

* Robot: Update TaskTrajectoryDressUpParameter.ui

* Core: Update MayaGestureNavigationStyle.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-09-15 21:51:56 -05:00
sliptonic e2ca3cce4b Merge pull request #23916 from davidgilkaufman/remove_qsignalblocker
[CAM] bugfix: replace python uses of QSignalBlocker
2025-09-15 14:10:54 -05:00
sliptonic 15eeb8ab1f Merge pull request #23776 from davidgilkaufman/fix_missing_tool_proxy
[CAM] regression fix: migrate old tools to new system
2025-09-15 14:08:47 -05:00
Roy-043 9c4bafc28f Sketcher: Add 'Toggle' to 'Construction Geometry' menu texts (#23944)
* Sketcher: Add 'Toggle' to 'Construction Geometry' menu texts

* Sketcher: Add 'Toggle' to 'Construction Geometry' menu texts

* Update TaskSketcherElements.cpp

* Update CommandAlterGeometry.cpp
2025-09-15 19:38:13 +02:00
Roy-043 010e7fc45f Sketcher: Change "By control points" and "By knots" texts (#23943)
* Sketcher: Change "By control points" and "By knots" texts

Elsewhere in the Sketcher GUI texts, "By" has been replaced by "From". For example "Arc From Center". It makes sense to also do that for the B-spline modes "By control points" and "By knots".

* [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-09-15 17:12:58 +00:00
Pieter Hijma 11ec98ede3 Gui: Remove internal prop types Add Prop dialog
This commit removes types from the list that have no editor and are
meant for internal use.
2025-09-15 19:00:10 +02:00
sliptonic c7936ddcf4 Merge pull request #22500 from jffmichi/drilling_select_line
CAM: select rows instead of cells in drilling panel
2025-09-15 10:46:52 -05:00
sliptonic 768cbbc85b Merge pull request #23856 from Connor9220/library-editor
CAM: Replace the main library editor dialog and add copy & paste & drag & drop support
2025-09-15 10:37:19 -05:00
Roy-043 eec6f4ec0d BIM: fix material handling of component 2025-09-15 15:29:55 +02:00
Furgo c4b2dad89a BIM: fix double click both editing label and opening task panel 2025-09-15 15:28:58 +02:00
Roy-043 68f4a30a1b BIM: fix issues with T-slot profile (#23813)
* BIM: fix issue with T-slot profile

* BIM: fix issue with T-slot profile

* BIM: fix issue with T-slot profile

* Update ArchProfile.py: remove temp print
2025-09-15 15:28:16 +02:00
Furgo a0787e988a BIM: fix double click both editing label and opening task panel 2025-09-15 15:24:11 +02:00
Paul Lee b10fa7fb34 [Arch] Fix makeStairs Move & Addition Behaviour Consistency
Consistent Addition

1. Additions are hidden by onChanged()
2. makeStairs() previously made 1st segment of a Complex Stairs went to Base and the rest segments went to Additions
3. For consistency in grouping and visibility, all segments in go to Additions with this commit

Consistent Move With Host

1. A Complex Stairs has multiple segment (in Additions) and railings (in RailingLeft/Right), they should move togther.
2. All segments and Railing set MoveWithHost to True upon creation, and thus move together, regardless system setting default with this commit

Other Associated Inconsistency

    Other visibility default behaviour as discussed in https://forum.freecad.org/viewtopic.php?p=844965#p844920 would be added in subsequent PR

Last associated PR/commits :
2025-09-15 15:19:49 +02:00
Ryan Kembrey 5642620281 TechDraw: Fix projection groups not recursively deleting 2025-09-15 09:36:42 +02:00
David Kaufman 2cb86f259e also add qt5 compatibility for checkbox state change signal 2025-09-14 14:59:21 -04:00
Ryan K 6bed5b4255 TechDraw: Add number decimals and reference dimension options to dimension task panel (#23501)
* TechDraw: Add num decimals option to task panel

* TechDraw: Add Reference option for dimensions

* Update src/Mod/TechDraw/Gui/TaskDimension.cpp

Co-authored-by: Kacper Donat <kadet1090@gmail.com>

* Update src/Mod/TechDraw/Gui/TaskDimension.cpp

Co-authored-by: Kacper Donat <kadet1090@gmail.com>

---------

Co-authored-by: Ryan Kembrey <ryan.kembrey@student.uts>
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-09-14 18:14:10 +02:00
Chris Hennes a6ab6f510e Merge pull request #23906 from mrpilot2/cmake_pch_core
Core: use CMake to generate precompiled headers on all platforms
2025-09-14 09:24:40 -05:00
Pascal de Bruijn 651c2d500c Materials: Add POM-(Homopolymer|Copolymer)-Generic followup (#23922)
* Materials: Add POM-(Homopolymer|Copolymer)-Generic

* Materials: Adjust CMakeLists for POM-(Homopolymer|Copolymer)-Generic

* Materials: fixups for POM-(Homopolymer|Copolymer)-Generic

* Materials: Fix POM-(Homopolymer|Copolymer)-Generic UUID
2025-09-14 09:17:50 -05:00
Pascal de Bruijn d09b632cf5 Materials: Add PEEK-Generic (#23779) 2025-09-14 09:16:49 -05:00
Ryan Kembrey 34173f5d3a TechDraw: Fix selections not clearing 2025-09-14 09:15:49 -05:00
Roy-043 f7f3c18e52 Sketcher: QMessageBox titles to Title Case (#23925)
* Sketcher: QMessageBox titles to Title Case

* Sketcher: QMessageBox titles to Title Case

* Sketcher: QMessageBox titles to Title Case

* Update Command.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-09-14 11:59:20 +00:00
Roy-043 4dbdd1031d Sketcher change "don't attach" (#23924)
* Update Command.cpp

* Update Command.cpp
2025-09-14 11:31:11 +00:00
Roy-043 5b59d94d55 Sketcher: Update text in prefs (Title Case related) 2025-09-14 12:31:52 +02:00
Roy-043 57ee6870b4 Sketcher: QInputDialog titles to Title Case (#23920)
* Sketcher: QInputDialog titles to Title Case

* Remove 2nd trailing blank line
2025-09-14 10:21:33 +00:00
Markus Reitböck 6ef07bb358 Gui: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-14 09:47:03 +02:00
Markus Reitböck d05e2a0431 App: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-14 09:47:02 +02:00
Markus Reitböck f0eca551b3 Base: use CMake to generate precompiled headers on all platforms
"Professional CMake" book suggest the following:

"Targets should build successfully with or without compiler support for precompiled headers. It
should be considered an optimization, not a requirement. In particular, do not explicitly include a
precompile header (e.g. stdafx.h) in the source code, let CMake force-include an automatically
generated precompile header on the compiler command line instead. This is more portable across
the major compilers and is likely to be easier to maintain. It will also avoid warnings being
generated from certain code checking tools like iwyu (include what you use)."

Therefore, removed the "#include <PreCompiled.h>" from sources, also
there is no need for the "#ifdef _PreComp_" anymore
2025-09-14 09:47:01 +02:00
David Kaufman 9ce9c6b99a [CAM] replace python uses of QSignalBlocker 2025-09-13 22:13:55 -04:00
Matthias Deimbacher c0c9212c97 CAM: fix library import in postprocessor 2025-09-13 21:33:31 +02:00
Pascal de Bruijn 2458f47550 Materials: Add POM-(Homopolymer|Copolymer)-Generic (#23820)
* Materials: Add POM-(Homopolymer|Copolymer)-Generic

* Materials: Adjust CMakeLists for POM-(Homopolymer|Copolymer)-Generic

* Materials: fixups for POM-(Homopolymer|Copolymer)-Generic
2025-09-13 14:27:47 -05:00
Markus Reitböck b2c8f4b084 CMake: fix disable msvc warning on wrong target 2025-09-13 12:35:43 -05:00
tetektoza 817ffc5782 Gui: Make Report View properly claim Select All (Ctrl+A) shortcut
Currently if user tries to use CTRL+A on Report View while having
document opened, it rejects the action and nothing happens.

This happened during the introduction of Select All (CTRL+A) behavior in
Sketcher. Basically, before Report View was not catching the event, but
neither any widget, resulting in QTextEdit catching it at the end of the
chain. Now, after enabling it for the whole document,
Report View rejected it, but we have registered it throughout the
document, so another widget was intercepting the event.

So, fix for that is simple - add a check for Select All shortcut on
Report View level, so the event will get consumed instead of being
rejected and propagated to further widgets.
2025-09-13 13:39:09 +02:00
PaddleStroke 37b4560893 Sketcher: Coin resize when screen change. Fix #23267 (#23865)
* Sketcher: Coin resize when screen change. Fix #23267

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

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

* Update ViewProviderSketch.cpp

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-13 12:03:39 +02:00
PaddleStroke 37de4ce264 PartDesign: remove duplicate scale during sketch creation with attach task 2025-09-13 11:43:17 +02:00
Kacper Donat 470ad2a874 Merge pull request #23426 from pieterhijma/reconcile-add-prop-dialogs
Gui: Reconcile Add Property Dialogs
2025-09-13 11:26:52 +02:00
Alihan Tadal 6bb3a39e39 CAM: Let old files adapt OffsetPattern property changes 2025-09-13 11:53:39 +03:00
Alihan Tadal c9001c103c Merge branch 'main' into feature_23649_update_confusing_nomenclature_offset_pattern 2025-09-13 08:42:34 +03:00
Alihan Tadal afff03c38b CAM: Improve confusing nomenclature: Offset Pattern (#23649) 2025-09-13 08:35:29 +03:00
Billy 60bcf64a01 CAM: Consistently rename "Tool" to "Toolbit" in UI and code
- Updated all user-facing strings from "Tool" to "Toolbit" for clarity and consistency.
- Changed combo box filtering logic to use index for "All Toolbit Types" (localization-safe).
- Improved visual distinction for "All Toolbits" in library editor (bold/italic).
- Reduced default SVG icon size in ShapeWidget for a more compact display.
- Updated window titles, labels, tooltips, and placeholder texts to use "Toolbit".
- Removed obsolete string comparisons in filtering logic.
- Change the Menu item from "Toolbit Library Editor" to "Toolbit Library Manager"
2025-09-12 18:04:57 -04:00
Pieter Hijma f0a9b5ea01 Part: Add deprecation warning for import/export 2025-09-12 16:30:25 -05:00
PaddleStroke 061e185e7f Sketcher: Fix ctrl A (#23866) 2025-09-12 15:40:24 -05:00
Chris Hennes 0dcbac7b30 App: Add Python interface to ApplicationDirectories
The Python version of this class is entirely static: no instance is
required. Internally it accesses th pre-constructed instance of the C++
ApplicationDirectories class that is instantiated at program startup by
the Application class.
2025-09-12 15:25:47 -05:00
sliptonic 4ae36283d0 Ensure Qt5 compatibility with enums
Correct LGPL headers

rework bullnose  Fixes #19050
2025-09-12 15:24:16 -04:00
George Peden f2803283b8 Fix B-spline keyboard focus issue (#23859) (#23860)
* Fix B-spline keyboard focus issue (#23859)

- Restore keyboard focus after command restart in changeConstructionMethode()
- Fixes M key mode switching and R toggle periodic functionality
- Uses direct MDI view focus restoration instead of private ensureFocus() method

Fixes issue where keyboard shortcuts stop working after first mode switch.

* Address Copilot feedback: Add null check for activeDocument()

- Use ternary operator for cleaner null safety
- Prevents potential crash if activeDocument() returns null
- More idiomatic C++ code style

* Improve variable scope per @chennes feedback

- Use if-with-initialization to scope doc and mdi variables
- Variables now only exist where needed instead of leaking into function scope
- More idiomatic C++ code style
2025-09-12 18:26:39 +00:00
sliptonic db5117e1ae Update src/Mod/CAM/Gui/Resources/panels/LibraryProperties.ui
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Update src/Mod/CAM/Gui/Resources/panels/ToolBitLibraryEdit.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-12 14:19:30 -04:00
sliptonic 78bd46f815 fixes
fix duplicate toolbits
add tools to 'all tools'
context menus and deletion
/CamAssets/Tool/  directory structure
Assets and preferences
2025-09-12 14:19:30 -04:00
Billy 81faf7727c CAM: Remove hardcoded style for Tool Number, Fix TestPathToolBitSerializer
Fix issue with toolshapes
Renamed fillet to radius
Added Tool Type Filter to library
Fix units so that they honor user preference
Remove the QToolBox widget from the Shape Selector page and combine into a single page.
Fix issue with PropertyBag so that CustomPropertyGroups as a string is converted to enum and enums are handled correctly.
Update TestPathPropertyBag test for enum changes.
Update TestPathToolBitListWidget
Update TestPathToolLibrarySerializer to match new LinuxCNC output
Fix LinuxCNC export too handle ALL tool types, use user preferences for units, and include all lcnc fields
2025-09-12 14:18:33 -04:00
Matthias Danner 95840a79d3 Sketcher: Fix Select all with BSplines and clean up selection logic 2025-09-12 12:56:41 -05:00
PaddleStroke ee44d265c8 Sketcher: Bspline tool: prevent double click failure (#23872)
* Sketcher: Bspline tool: prevent double click failure

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

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

* Update DrawSketchHandlerBSpline.h

* [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-09-12 16:51:31 +00:00
PaddleStroke 547c97fc79 Sketcher: Fix arc double click bug (#23873) 2025-09-12 11:20:43 -05:00
Pieter Hijma 1a9247d393 Gui: Fix disabling editing Property View
This commit fixes an issue that blocks editing values after pressing F2.
2025-09-12 11:05:33 -05:00
matthiasdanner 5d76be01e1 Sketcher: Fix Freeze in Offset with too large negative value (#23467)
* Sketcher: Fix Freeze in Offset with too large negative value

* Remove ErrorMessages when offsetting circles with too large negative value

* fix linting comment

* Add Error feedback

---------

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
2025-09-12 10:52:33 -05:00
tarman3 34f4f16383 CAM: Clean DogboneDressup after PR#22250 (#23752) 2025-09-12 09:43:18 -05:00
tarman3 0336185ec1 CAM: Improve SelectLoop (#23275) 2025-09-12 09:42:20 -05:00
Connor9220 fff2e2daf9 CAM: Reorder the Clearance height and Safe Height spinners in task panel (#23727)
Co-authored-by: Billy <billy.huddleston@preparis.com>
2025-09-12 09:40:08 -05:00
matthiasdanner 34747719fb Sketcher: Fix use after free Bug when commiting value with enter in OVP (#23853)
* Sketcher: Fix use after free Bug when commiting value with enter

* Fix new use after free bug

---------

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
2025-09-12 09:18:09 -05:00
dependabot[bot] b66d44ac49 Bump github/issue-metrics from 3.23.1 to 3.23.2
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.23.1 to 3.23.2.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/6fa9041b3ea7b6a9dafbdc388d25d86d06b2b6af...e8f19041d9996b64cd5eebd653f065adb6d0e195)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.23.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-12 08:54:47 -05:00
Pieter Hijma 1edacbf508 Gui: Small refactor of Tree.cpp selecting docs
Based on review comment, a small refactoring of code that was duplicated
when adding functionality to select documents.  The duplication has been
removed in this commit.
2025-09-12 10:59:17 +02:00
Pieter Hijma 12b7699800 Gui: Process minor review comments
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-09-12 10:58:34 +02:00
Markus Reitböck 952bff5b63 Mesh: give evaluation panel a title (#23423)
* Mesh: give evaluation panel a title

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

* Mesh: Evaluation panel - move refresh button beside selection box

as per request in pull request #23423

* Mesh: replace ampersand with 'and' in Evaluate and Repair dialog
2025-09-11 22:41:38 -05:00
Chris Hennes 112e22b639 Merge pull request #23837 from longrackslabs/feature/sketcher-keyboard-shortcuts-hints-23815
Feature/sketcher keyboard shortcuts hints 23815
2025-09-11 22:37:55 -05:00
Markus Reitböck 749ac36615 do not use precompiled header for setting global compiler definitions and to disable compiler warnings
only 4 of these warnings are still relevant, CMake shall be used to disable them

Compiler definitions:

  NOMINMAX:
    * is already globally defined in SetGlobalCompilerAndLinkerSettings.cmake

  WIN32_LEAN_AND_MEAN:
    * use CMake target_compile_options on relevant targets

Warnings that still occur:

  C4251, C4273, C4275: all related to dllimport / export
    * use CMake target_compile_options on relevant targets

  C4661: no suitable definition provied for explicit template instantiation request
    * triggered in Mesh because of Vector3D in Base - not all functions are defined in header
    * use CMake target_compile_options on relevant targets

Warnings that are Currently not triggered (fix code if they appear again):

  C4005: macro redefinition

  C4244: argument conversion, possible loss of data

  C4267: conversion from size_t to type, possible loss of data

  C4305: truncation from type1 to type2
    * only occurrence disabled in Reader.cpp

  C4522: multiple assignment operator specified

  C5208: unnamed class in typedef name

Obsolete Compiler warnings:

  C4181: not mentioned in Microsoft docs anymore

  C4290: C++ exception specification ignored except to indicate a function is not __declspec(nothrow)
    * throw(optional_type_list)  deprecated in C++17

  C4482: nonstandard extension used: enum 'enumeration' used in qualified name
    * not generated for compilers that support C++11

  C4503: 'identifier': decorated name length exceeded, name was truncated
    * obsolete since Visual Studio 2017

  C4786: not mentioned in Microsoft docs anymore
2025-09-11 20:21:04 -05:00
Markus Reitböck 965109dd73 missing includes in Base, App and Gui headers (#23854)
* missing includes in Base, App and Gui headers

header should be self contained

* use cstddef header instead of stddef.h

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-11 18:58:44 -05:00
marioalexis 7387fc2210 Fem: Force utf8 encoding for Netgen Python process 2025-09-11 18:28:17 -03:00
marioalexis 7d1e05f21d Fem: Better error handling in task panels with logging 2025-09-11 18:28:08 -03:00
sliptonic 10d1031e9b Make default postprocessor empty string. (#23706)
* Make default postprocessor empty string.

Default post when creating a job is now not set.  This will cause the user to be prompted for a post instead
This PR also cleans up some unit tests to avoid loading from disk

* [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-09-11 16:07:38 -05:00
captain0xff 603e0bc6e5 Gui: update gizmo state based on new property 2025-09-11 22:54:47 +02:00
Kacper Donat 1f96b30832 Merge pull request #23510 from pieterhijma/modify-property-tooltip
Gui: Add editing a property tooltip in Property View
2025-09-11 22:14:08 +02:00
Ryan K f7a85081e8 TechDraw: Fix tree view selection not showing on page (#23593) 2025-09-11 12:35:19 -05:00
Ryan Kembrey caa009036a TechDraw: Fix selection regressions 2025-09-11 12:34:37 -05:00
Roy-043 1bbc1c805d Spreadsheet: fix Split Cell name in context menu 2025-09-11 12:32:23 -05:00
Samuel Abels 2168e3cd99 CAM: Add AssetManager.copy() and .deepcopy()
CAM: Add copy/paste support for the ToolBitBrowser

CAM: Move library dropdown and sort order combo to dedicated row to give them more space

CAM: Fix: PathAssetManagerTest failed

CAM: Add YamlSerializer

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

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

CAM: Fix CodeQL complaints

CAM: add LibraryProperties dialog

CAM: Replace the LibraryEditor

CAM: allow for editing tool number in the tool editor dialog

CAM: Remember last selected library and sort order in preferences

CAM: support natural sort order in tool and library lists

CAM: Fix CodeQL complaints

CAM: Fix: not all attributes included in YAML serialization

CAM: Fix: UTF8 chars not included in LinuxCNC export

Fix: tool library not displayed when loading it for the first time

CAM: Fix: custom shape class not found

CAM: Check dependencies on import for friendlier error messages

CAM: Open file dialogs in home by default

CAM: Show "All Tools" entry in library list in the library editor

CAM: fix: error on sorting tools with no tool number

CAM: Fix: traceback if library contained tool number as string

CAM: Fix: Linter errors in manager.py

CAM: Fix: separator between library and tool buttons

CAM: Add drag & drop support to the library editor

CAM: Fix numerous linter errors on the AssetManager

CAM: Show current library in library editor window title

CAM: Add dedicated icons for library add + remove

CAM: Support F2 key in library editor

CAM: library editor handles delete key when library list is in focus; focus search field by default

CAM: fix: tool list in dock initially not loading

CAM: Fix: library editor did not open from "all tools" list

CAM: Increase precision of parameters in tool summary to 3 digits

fix TestToolBitListWidget
2025-09-11 10:45:41 -05:00
marioalexis a4ca9a0526 Fem: Fix regression in netgentools 2025-09-11 10:21:08 -05:00
PaddleStroke d5929bcdbf PartDesign: NewSketch: fix crash when no body 2025-09-11 16:23:48 +02:00
Roy-043 a4b659fcbf Spreadsheet: message box titles to Title Case (#23842) 2025-09-11 14:45:37 +02:00
George Peden ed444318e4 Fix inconsistent keyboard shortcut hints in Rectangle tool
- Add missing U (rounded corners) and J (frame) hints to ThreePoints method
- Add missing U (rounded corners) and J (frame) hints to CenterAnd3Points method
- Now all four construction methods show consistent keyboard shortcut hints
- Addresses Copilot feedback on PR
2025-09-10 20:40:18 -10:00
George Peden 343bd6c77c Add keyboard shortcuts to fillet/chamfer hints
- M key for switching between Fillet and Chamfer modes
- U key for toggling preserve corner option
- Hints are shown in all states (SeekFirst, SeekSecond, End)
- Addresses issue #23815 for missing keyboard shortcuts in hints
2025-09-10 19:59:49 -10:00
George Peden 80290baaf6 Add mode-aware keyboard shortcuts to B-spline hints
- Control Points mode: U/J for degree control (+ degree, - degree)
- Knots mode: R for periodic toggle
- Hints are now context-aware based on construction method
- Addresses issue #23815 for missing keyboard shortcuts in hints
2025-09-10 19:34:53 -10:00
George Peden d524b9ceef Add M (Mode) keyboard shortcut to arc slot hints
- Add switchModeHint constant with M key
- Include mode shortcut in all arc slot states (SeekFirst through SeekFourth)
- Addresses issue #23815 for missing keyboard shortcuts in hints
2025-09-10 19:13:15 -10:00
George Peden 23ea8ce37b Add U (rounded corners) and J (frame) keyboard shortcuts to rectangle hints
- Add roundedCornersHint and frameHint constants
- Include U and J shortcuts in all rectangle construction method states
- Addresses issue #23815 for missing keyboard shortcuts in hints
2025-09-10 19:08:59 -10:00
Roy-043 770f769b1f Draft: fix issue with ContinueMode 2025-09-10 22:30:26 -05:00
Ryan Kembrey 7a0b93cabe TechDraw: Fix spreadsheet incorrect render due to cell merges 2025-09-10 22:28:20 -05:00
Chris Hennes 3d65ae46d5 Merge pull request #23746 from 3x380V/cmake
CMake: Use scoped include and library directories
2025-09-10 21:54:51 -05:00
PaddleStroke d8640019e5 Assembly: Fix simulation crash with limits 2025-09-10 21:54:20 -05:00
FEA-eng 3df7bb34bf Update CommandFilter.cpp 2025-09-10 21:52:50 -05:00
wandererfan f2ac9e2baa [TD]fix TheoreticalExact frame color 2025-09-10 21:50:59 -05:00
FEA-eng 689740d3d3 Sketcher: Remove redundant title case from task panel option of the Mirror tool (#23822)
* Sketcher: Update DrawSketchHandlerSymmetry.h

* [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-09-10 18:07:42 +00:00
dependabot[bot] 0b5552f375 Bump github/issue-metrics from 3.23.0 to 3.23.1
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.23.0 to 3.23.1.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/63da87a2ab16c720cf9199a73c11f56a42f39cd4...6fa9041b3ea7b6a9dafbdc388d25d86d06b2b6af)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.23.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-10 12:40:14 -05:00
dependabot[bot] 6483675405 Bump step-security/harden-runner from 2.13.0 to 2.13.1
Bumps [step-security/harden-runner](https://github.com/step-security/harden-runner) from 2.13.0 to 2.13.1.
- [Release notes](https://github.com/step-security/harden-runner/releases)
- [Commits](https://github.com/step-security/harden-runner/compare/ec9f2d5744a09debf3a187a3f4f675c53b671911...f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a)

---
updated-dependencies:
- dependency-name: step-security/harden-runner
  dependency-version: 2.13.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-10 12:39:56 -05:00
PaddleStroke aef10a1bc8 PartDesign: Extrude: Fix twoLength/uptoshape broken (#23812)
* PartDesign: Extrude: Fix twoLength/uptoshape broken

* Update FeaturePocket.cpp

* Update FeatureExtrude.cpp

* fix test
2025-09-10 19:12:02 +02:00
PaddleStroke 8aa527119b Core: Add btn_rotate.svg (#23781)
* Core: Add btn_rotate.svg

* Add files via upload

* Update resource.qrc
2025-09-10 15:35:35 +02:00
FEA-eng 2073ccf8e2 Update DlgSettings3DView.ui 2025-09-10 10:43:48 +02:00
Ladislav Michl 8e7e9c4bbc Gui: check for null document name
Make the check for null document name more obvious.
2025-09-10 10:08:04 +02:00
Chris Hennes 58a8d589a7 Update translations 2025-09-09 2025-09-10 08:53:41 +02:00
Ladislav Michl ea9cdfd962 Py3.13: Initialize field tp_versions_used 2025-09-10 08:49:31 +02:00
wmayer 692d40916a Py3.13: Disable Py_UNICODE support in PyCXX 2025-09-10 08:49:30 +02:00
Kacper Donat 0677982c8b Gui: Fix segfault in ViewProviderPlane::getRole 2025-09-10 06:16:02 +02:00
David Kaufman 874fe54053 [CAM] migrate old tools to new system 2025-09-09 11:49:55 -04:00
PaddleStroke 02479a1528 PartDesign: FeatureExtrude fix symmetric + custom dir 2025-09-09 15:25:00 +02:00
marioalexis d1dae5af1c Fem: Fix Gmsh preferences file chooser 2025-09-09 07:30:10 -03:00
marioalexis 1ee3992436 Fem: Fix Elmer preferences file chooser 2025-09-09 07:30:01 -03:00
marioalexis 31ff4124f2 Fem: Fix Mystran preferences file chooser 2025-09-09 07:29:56 -03:00
marioalexis 9efc0d77a0 Fem: Fix Z88 preferences file chooser 2025-09-09 07:29:51 -03:00
Benjamin Nauck c1dd116e1e Revert "Part: Remove mode from Offset, keep in Offset2D"
This reverts commit b13b78b2e1.
2025-09-09 08:43:51 +02:00
Benjamin Nauck b400cdcec7 Merge pull request #23274 from kadet1090/enlarge-planes
Gui: Enlarge planes on mouse over and selection
2025-09-09 06:20:15 +02:00
marioalexis 344f93c2da Fem: Fix CalculiX preferences file chooser 2025-09-08 23:47:20 -03:00
PaddleStroke dc22fb4b9b Sketcher: Constraint symbol size follow-up (#23590)
* Sketcher: Constraint symbol size follow-up

* Update SketcherSettings.cpp

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

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

* Update SketcherSettingsDisplay.ui

* Update EditModeCoinManager.cpp

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

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

* remove enabled property

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-09 01:00:26 +02:00
Kacper Donat 50865e3ee9 CI: Disable implicit bool conversion linter warning
Implicit conversion from integer to boolean and vice versa is very
common in FreeCAD due to SbBool (from coin) being defined as int. This
creates a lot of false positives that should not be addressed in code
reviews. We also use such implicit coversions in FreeCAD often in
general so that warning is usually ignored.
2025-09-08 17:18:51 -05:00
Kacper Donat b942275957 Gui: Make datum planes bigger 2025-09-08 23:16:29 +02:00
captain0xff 341f352864 Gui: add theming abilities to interactive gizmos 2025-09-08 20:59:16 +02:00
wmayer b1a37aebbb CMake: Replace link_directories with target_link_directories 2025-09-08 19:04:38 +02:00
wmayer 93db4c7d8a CMake: Replace include_directories with target_include_directories 2025-09-08 19:04:34 +02:00
PaddleStroke 7e57b6e7b0 PartDesign: FeatureLinearPattern fix Axis-Y not working (#23637)
* PartDesign: FeatureLinearPattern prevent error message

* To squash
2025-09-08 18:26:30 +02:00
Kacper Donat 51650e7bcc Gui: Fix segfault in TaskAttacher on cancel 2025-09-08 11:20:43 -05:00
zophon 1f32565819 Update KineticNCBeamicon2_post.py (#23602)
Added a return in the postamble to separate M05 and M09 GCode as beamicon2-basic doesn't like having both M-code on the same line.
2025-09-08 11:07:01 -05:00
Chris Hennes 84c810dc4a Merge pull request #23521 from z0r0/python-interface-bindings-final
Core: Python interface bindings cleanup
2025-09-08 10:58:15 -05:00
tarman3 d87fe5084a CAM: Dogbone - fix for Pocket (#22250) 2025-09-08 10:52:03 -05:00
PaddleStroke c3a6d0b03a Part: Remove transparency cap at 50% for face color override 2025-09-08 10:49:56 -05:00
Kacper Donat f0d43b0ca9 PartDesign: Reorder fields in Hole dialog
This makes order of fields in Hole Parameters more natural with typical
input flow of the parameters, i.e. moves the size of the hole more to
the top as it is the most important parameter.
2025-09-08 10:48:13 -05:00
PaddleStroke ff86b537e0 Core: Fix alpha-transparency issue in face color override. (#23532)
* Core: Fix alpha-transparency issue in face color override.

* Fix color picker opening wrongly with alpha reversed
2025-09-08 17:46:05 +02:00
Benjamin Nauck b13b78b2e1 Part: Remove mode from Offset, keep in Offset2D 2025-09-08 10:42:15 -05:00
Chris Hennes 39f37fde17 TD: Finish removal of Link and Landmark from GUI 2025-09-08 17:38:00 +02:00
Roy-043 45629f7599 Draft: Remove relative to WP option from Draft_Scale (#23716)
* Draft: Remove relative to WP option from Draft_Scale

* Draft: Remove relative to WP option from Draft_Scale
2025-09-08 14:38:38 +02:00
Roy-043 e63819ca4c BIM: fix transparency of windows 2025-09-08 14:36:18 +02:00
Roy-043 b8f5e6848c Draft: fix display of Building US dim text (#23674)
* Draft: fix display of Building US dim text

* Fix UnitSystem check
2025-09-08 14:35:21 +02:00
Paul Lee 41358863f6 [ArchStairs] Fix-hideSubobjects
Arch Objects usually has hideSubobjects to hide children.

ArchStairs does not have this and children (e.g. Additions, Subtraction [Railing to be added]) does not hide; this fix the problem.

Other Associated Inconsistency
- Other movable childre and visibility behaviour (like Railing of Stairs should be children) as discussed in https://forum.freecad.org/viewtopic.php?p=844965#p844920 would be added in subsequent PR
2025-09-08 14:34:33 +02:00
Roy-043 0d431ae628 Draft: fix focus on Length input behavior 2025-09-08 14:33:23 +02:00
Paul Lee d54db8c223 [ArchComponent] Fix 1st Addition Placment & MovableChildren Includes Railings
I.  Fix 1st Addition Placement

1. Arch Object can have no Base.
2. ArchComponent.processSubShapes() would keep the placement of Additions by treating with inverse placement when the parent Arch Object placemnet is changed.
3. However, when there is not base/Base, 1st Addition becomes 'base' and the placement is not treated by inverse placement and the displacement is doubled
4. This commit identify the above case and apply same inverse placment

II.  MovableChildren Includes Railings

1. getMovableChildren() does not includes Railing (on top of Additions/Subtraction)
2. This commit fix the behaviour to make it consisteny

Other Associated Inconsistency
- Other visibility default behaviour as discussed in https://forum.freecad.org/viewtopic.php?p=844965#p844920 would be added in subsequent PR

Last associated PR/commit -  https://github.com/FreeCAD/FreeCAD/pull/23556
2025-09-08 14:32:16 +02:00
Roy-043 d58f9c56e9 BIM: fix Arch_Reference colors 2025-09-08 14:30:40 +02:00
Roy-043 4677bfef79 BIM+Draft: change object related version info to log messages
To inform the user warnings are shown if an object has new or modified properties in the current version. These warnings can however be confusing, especially if there are many. With this PR they are turned into log messages. They are also moved out of translation, and instead of the object Label the object Name is displayed.

Additionally:
Zero path length warnings for path arrays are now only displayed if the Align property is True.

See: #21180.
2025-09-08 10:58:28 +02:00
Roy-043 999a6d2631 Draft: Improve ShapeString execute function 2025-09-08 10:58:06 +02:00
Furgo e767e932b7 BIM: Fix sun ray creation in Arch Site solar study, suppress ladybug log messages (#23524)
* BIM: disable root logger propagation to imported modules

Prevents noisy log messages from third-party modules, such as ladybug,
from appearing in the console. A context manager temporarily sets the
root logging level to WARNING during the import process, which avoids
altering the application's permanent logging configuration. Ultimately,
this is a workaround: FreeCAD seems to set the root logging level to
INFO at least, which propagates to all loaded modules. It should set it
to WARNING or ERROR at least, but changes outside the BIM module were
out of scope for this PR.

* BIM: make module import error explicit, do not mask exceptions

* BIM: adapt code to the new Draft.Line properties (PR #11941)

Adapts the code to a Draft.Line API change. Property names for the sun
ray object are updated (e.g., from ArrowType to ArrowTypeEnd) to align
with the new definitions, which prevents errors and ensures the sun
ray's arrow displays correctly.

* BIM: do not update sun position until all properties are initialized

Prevents an AttributeError error when loading files. During the loading
sequence, the onChanged callback is triggered for related properties
until they all have been initialized. A hasattr guard is added to ensure
the dependent logic is not executed until the object is in a consistent
state.

* BIM: restore property constraints at the right time

Fixes an unconstrained properties issue when loading files. Constraint
metadata is not saved in files, and the UI is built before the Python
code can re-apply it. The fix defers the constraint restoration using
QTimer.singleShot(0) to run after the file has fully loaded. The
restoration logic also correctly preserves user-saved values by reading
them from the object before re-applying the non-persistent constraints.
2025-09-08 10:57:50 +02:00
luzpaz d9da6c8def Fix various typos
Found via codespell
2025-09-08 00:21:16 -05:00
Chris Hennes 1f05f5eda4 Merge pull request #23351 from 3x380V/fileinfo
Core: Modernize Fileinfo
2025-09-07 21:28:11 -05:00
wandererfan 3f84a7695a [TD]fix horizontal/vertical test for dimensions 2025-09-07 20:42:09 -05:00
drwho495 55b3ab0489 Toponaming: Remove updateElementReferences call in getLinks methods. (#23525)
* remove calls to updateElementReferences in getLinks

* add description of the bug for future developers' sake
2025-09-07 20:40:47 -05:00
marioalexis 414943f4f9 Fem: Add default solver to new analysis - fixes #23043 2025-09-07 20:33:17 -05:00
marioalexis cf61dfab38 Fem: Update old ElementGeometry*D with new properties 2025-09-07 20:32:42 -05:00
Adrian Insaurralde Avalos 8a73146311 FEM: improve gmsh binary lookup logic
fixes https://github.com/flathub/org.freecad.FreeCAD/issues/28
also remove unnnecessary/redundant UseStandardGmshLocation preference
2025-09-07 20:32:07 -05:00
marioalexis cd0502a155 Fem: Use Netgen bindings entirely in external program 2025-09-07 20:31:53 -05:00
FEA-eng f18cff3b27 FEM: Fix the shell to shell contact example (#23533)
* FEM: Update constraint_contact_shell_shell.py

* FEM: Update constraint_contact_shell_shell.inp
2025-09-07 20:31:38 -05:00
FEA-eng 40011e8f7e FEM: Better defaults for mesh export (#23553)
* FEM: Update mesh_gmsh.py

* FEM: Update DlgSettingsFemExportAbaqus.ui

* FEM: Update DlgSettingsFemExportAbaqus.ui

* FEM: Update DlgSettingsFemExportAbaqusImp.cpp

* FEM: Update AppFemPy.cpp
2025-09-07 20:31:20 -05:00
Chris Hennes aee2226d60 Merge pull request #23494 from marioalexis84/fem-calculix_default_time_increment
Fem: Use default CalculiX time increments for thermo-mechanical steady state analysis
2025-09-07 20:31:06 -05:00
Chris Hennes 325730dd9c Merge pull request #23384 from 3x380V/units
Base: Units update
2025-09-07 20:22:54 -05:00
Chris Hennes 2d17ed4fb5 Merge pull request #22340 from maxwxyz/3d-nav-cursors
Gui: Change navigation cursors to SVG
2025-09-07 19:11:14 -05:00
marioalexis 4d25baf1ee Fem: Add support for 2D geometries to Centrif constraint 2025-09-08 00:25:55 +02:00
theo-vt eab485656f Sketcher: fix invalid constraint on first dimension (#23024)
* Sketcher: Scale: Reorder operations and delete original modified constraints to ensure validity

* Sketcher: replace boolean parameters for deletion with enum and expose solver override on some deletion functions in the python API

* Use correct flag in ::delGeometry

* Set default value of false to noSolve

* Sketcher: autoscale: use deleteAllGeometry

* Sketcher: Scale: revert to checking constraints for geoId validity and handle horizontal&vertical
2025-09-07 18:03:15 +02:00
Kacper Donat 6c5469560b Merge pull request #22964 from B0cho/bugfix/CORE-Expression-dialog-widgets
Core: Enhance 'Expression editor' input and resize behavior
2025-09-07 17:35:29 +02:00
PaddleStroke dad181b8e1 Fix Link MaterialOverride 0.0 transparency bug 2025-09-07 17:33:52 +02:00
Kacper Donat 465ca23cd3 Merge pull request #22029 from tetektoza/realthunder_multiselect_without_pie
Gui: Add a context menu to select obstructed items (from RT's fork Pick Geometry)
2025-09-07 17:27:18 +02:00
David Kaufman 24c382232a [CAM] re-enable adaptive profile mode 2025-09-07 10:55:24 -04:00
Kacper Donat 2bcfe3f2b1 Gui: Add generic getViewProvider<T> 2025-09-07 16:17:44 +02:00
David Kaufman 1182e38fd1 [CAM] add missing migration from intermediate version for lead in/out dressup 2025-09-07 09:38:36 -04:00
Ryan Kembrey 415fa0a415 TechDraw: Fix center marks not showing 2025-09-07 23:15:32 +10:00
Pascal de Bruijn 839ccb5e3a CAM: PocketShape defaults to Offset and 50% StepOver 2025-09-07 14:35:50 +02:00
Kacper Donat 288255f074 Gui: Disallow dragging features outside of body 2025-09-07 01:26:14 +02:00
Kacper Donat 5fbe1b66a8 Gui: Add handling for BaseFeatures outside of Body edge case 2025-09-07 01:25:24 +02:00
tetektoza 06f0a6a428 Gui: Correct linter problems 2025-09-06 17:13:05 +02:00
David Kaufman 2aac5f6b33 [CAM] fix to ensure tool change command is issued forsame tool number, new spindle speed (#23691) 2025-09-06 10:00:37 -05:00
David Kaufman e5e1732896 [CAM] change default TC name to 5mm endmill (#23692) 2025-09-06 09:56:52 -05:00
tetektoza a4f851c501 Gui: Handle proper naming for Link objects in Clarify Selection 2025-09-06 15:55:39 +02:00
tetektoza 1d4d7303c7 Gui: Skip creating submenu for Object and Other types in Clarify Select 2025-09-06 15:55:39 +02:00
tetektoza f44bb78faa Gui: Remember right click position before menu pop-up for ClarifySelect 2025-09-06 15:55:35 +02:00
tetektoza c191e256b6 Gui: Move Clarify Selection higher in Tools submenu hierarchy 2025-09-06 13:55:17 +02:00
tetektoza 214e68db99 Gui: Add Clarify Selection radius multiplier option 2025-09-06 12:09:36 +02:00
Kacper Donat 8f96856019 Gui: Fix preview rendering issues 2025-09-06 01:27:06 +02:00
B0cho 21c58687d3 Core: Fix 'Expression editor' handling with keyboard 2025-09-05 21:59:08 +02:00
Weston Schmidt 140c9febc4 Add test causing crash and fix map sorting function. (#22889)
* Add test causing crash and fix map sorting function.

When opening a model from FreeCAD 0.7, the model would crash when I
changed some of the parameters.  This turned out to be due to the
ElementNameComparator::operator() not correctly sorting the items going
into the map, which caused the map to be invalid.

This change adds a test that represented the exact names causing the
crash as well as a fix for the problem.  Names are now sorted:

1. Empty names first
2. Identifier based names second.
3. Hex based names last.

Identifiers are sorted lexicographically for the name portion and
numerically for the number portion, smallest to largest.

Hex based names are sorted by the value of the hex number, smallest to
largest.

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

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

* Fix lint issues.

* Add another test form to the mix.

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-05 14:07:02 -05:00
David Kaufman 6d71a564d5 [CAM] create adaptive epic (#23414)
* [CAM] create adaptive epic

* update adaptive epic
2025-09-05 11:49:51 -05:00
David Kaufman 51f49d92d4 [CAM] LeadInOut new features (#22669)
* CAM: Improve LeadInOut

* rebuild/fix task panel UI

* migrate old LeadInOut parameters to the new properties

* Keep original Lead-in and/or Lead-out

* LeadInOut Rename None/Original to No Retract/None

* merge in changes from tarman/leadovertravel

* LeadInOut update names to No Change/Suppress Retraction

* Remove IncludeLayers option from LeadInOut (always true)

* [CAM] Fix offset entrance UI string

* [CAM] improve handling of step angle on lead in/out ArcZ

* resolve merge conflicts

* finish pulling in tarman's updates

* switch back from 'No Change' style to enable checkbox

* 'Suppress Retraction' -> 'No Retract'

* fix documentation string for lead in/out dressup

---------

Co-authored-by: tarman3 <joice501790018@tutamail.com>
2025-09-05 11:24:42 -05:00
J-Dunn 97c41149ba CAM: fix G0 regression in drilling (#22602)
* CAM: fix G0 regression in drilling

At some point the initial rapid to Safe Height got dropped from drilling cycles. 
This leads to excessive air drilling.
It also alters "OLD_Z" which sets the Retraction plane under G98.

The defect is causing much confusion and time wasting in the roadmap discussions

This PR fixes the G0 regression.

* [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-09-05 11:14:58 -05:00
Ladislav Michl 88f76f3605 Base: UnitsSchema: use basic imperial conversion constants
Use well defined basic constants for conversion of imperial units.
This makes code hopefully easily readable and verificable.
2025-09-05 17:31:55 +02:00
Ladislav Michl 1cd47c2dd4 Base: add back Imperial for Civil Engineering unit conversions
Fixes: 1155f0d752 ("Base: simplify UnitsSchemas management")
2025-09-05 17:31:54 +02:00
Ladislav Michl 02e02b56a9 Base: pass format specifiers to UnitsSchemasData::runSpecial
Make toFractional() aware of desired fractional inch denominator.

Fixes: 1155f0d752 ("Base: simplify UnitsSchemas management")
2025-09-05 17:31:54 +02:00
Ladislav Michl 01b547912f Base: QuantityFormat: avoid storing formatting defaults
User defined precision and fractional inch are stored on QuantityFormat
construction making changes persistent to object life time.
Change that so until not explicitely overriden, user defined values
are always returned.

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
2025-09-05 17:31:54 +02:00
Ladislav Michl e7cd72b2e0 Base: refactor unit formatting defaults
Defaults for both precision (number of digits after decimal point)
and denominator (number of fractions) are defined on various places
making difficult to find which default is used for various tasks.
Store these values at one central place: UnitsApi. Unless overriden
by user, default values are defined by unitSchemasDataPack.
2025-09-05 17:31:54 +02:00
Ladislav Michl 28c256ba07 Gui: fix 'Minimum fractional inch' preference visibility
Default Unit Schema is not yet changed in onUnitSystemIndexChanged
callback handler, so index needs to be used to request currently
selected one.

Fixes: 1155f0d752 ("Base: simplify UnitsSchemas management")
2025-09-05 17:31:54 +02:00
Ladislav Michl afa5be6ff5 Base: Quantity: attribute pressure quantities to pressure unit
Although CompressiveStrength is of the same dimension as Pressure,
make it more straightforward and use base unit.
2025-09-05 17:31:54 +02:00
Ladislav Michl 2d6a946949 Base: Quantity: remove redundant 'this' 2025-09-05 17:31:54 +02:00
Ladislav Michl a067083a0b Base: UnitsApi: remove nowhere called init() 2025-09-05 17:31:54 +02:00
Ladislav Michl 8eea79fe05 Base: make UnitsApi::toNumber method of Quantity
This static method takes Quantity as a parameter, so make it
method of Quantity directly.
2025-09-05 17:31:54 +02:00
Ladislav Michl e3852f7732 Base: make UnitsApi::toString method of Quantity
This static method takes Quantity as a parameter, so make it
method of Quantity directly.
2025-09-05 17:31:54 +02:00
Ladislav Michl 9cfd5c7f48 Gui: do not misuse UnitApi to format numbers in property editor 2025-09-05 17:31:54 +02:00
Kacper Donat 1d597a789b Merge pull request #23677 from PaddleStroke/patch-58
Part: do not copy visual of sketch
2025-09-05 16:54:55 +02:00
PaddleStroke de607c1c30 Part: Revolution: do not copy style of sketches 2025-09-05 15:37:55 +02:00
PaddleStroke a32466fc40 Part: do not copy visual of sketch 2025-09-05 15:29:21 +02:00
Roy-043 b3ac2ec070 Update gui_groups.py 2025-09-05 14:49:11 +02:00
dependabot[bot] 29bac92bad Bump actions/labeler from 6.0.0 to 6.0.1
Bumps [actions/labeler](https://github.com/actions/labeler) from 6.0.0 to 6.0.1.
- [Release notes](https://github.com/actions/labeler/releases)
- [Commits](https://github.com/actions/labeler/compare/f1a63e87db0c6baf19c5713083f8d00d789ca184...634933edcd8ababfe52f92936142cc22ac488b1b)

---
updated-dependencies:
- dependency-name: actions/labeler
  dependency-version: 6.0.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-05 07:28:27 -05:00
tetektoza b55de1f9c1 Tests: Correct testcases after scene graph reordering in Clarify Select 2025-09-05 10:42:02 +02:00
tetektoza adb6d63f9c Gui: Add solid selection spport for top-lvl objects in pick menu 2025-09-05 02:24:53 +02:00
tetektoza 789b782b68 Gui: Break up condition for Clarify Selection to separate variables 2025-09-05 02:13:13 +02:00
tetektoza 745629d000 Gui: Allow long press timeout for Clarify Selection to be configurable 2025-09-05 02:05:52 +02:00
tetektoza 7dd0a90bea Gui: Align to use translated strings in SelectionView 2025-09-05 01:52:16 +02:00
tetektoza ccb42780c2 Gui: Add variable names for grouping thresholds in SelectionView 2025-09-05 01:41:51 +02:00
tetektoza 529f5be4a4 Gui: Replace usage of dynamic_cast with freecad_cast in SelectionView 2025-09-05 01:03:50 +02:00
tetektoza a99b6f9f41 Gui: Use cleaner variable naming for menu items in SelectionView 2025-09-05 01:00:37 +02:00
tetektoza 13f00488cb Gui: Use assignment in if statement for menus iterator 2025-09-05 00:49:24 +02:00
tetektoza 96dc1b7162 Gui: Convert Clarify Selection usage in SelectionSingleton to instance 2025-09-05 00:48:02 +02:00
tetektoza 572db4db80 Gui: Merge standard delayed paths with delayed priority paths 2025-09-04 23:42:11 +02:00
PaddleStroke 09128636ad PartDesign: Fix pattern Add/remove buttons #23626 2025-09-04 22:24:37 +02:00
Max Wilfinger 9815682b8d Part: Make dragger attach to the midpoint / axis for circular edges and faces 2025-09-04 22:23:46 +02:00
marcuspollio b543993a1b BIM: update Views Panel and Status Bar icons and some more (#23561)
* BIM: update View Panel and Status Bar icons and some more

* BIM: update icons - address review

* Update src/Mod/BIM/bimcommands/BimViews.py

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

* Update src/Mod/BIM/bimcommands/BimViews.py

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

---------

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-04 19:37:45 +02:00
dependabot[bot] e3a9045c0b Bump actions/labeler from 5.0.0 to 6.0.0
Bumps [actions/labeler](https://github.com/actions/labeler) from 5.0.0 to 6.0.0.
- [Release notes](https://github.com/actions/labeler/releases)
- [Commits](https://github.com/actions/labeler/compare/8558fd74291d67161a8a78ce36a881fa63b766a9...f1a63e87db0c6baf19c5713083f8d00d789ca184)

---
updated-dependencies:
- dependency-name: actions/labeler
  dependency-version: 6.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-04 12:01:02 -05:00
dependabot[bot] 42557f2772 Bump actions/stale from 9.1.0 to 10.0.0
Bumps [actions/stale](https://github.com/actions/stale) from 9.1.0 to 10.0.0.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/5bef64f19d7facfb25b37b414482c7164d639639...3a9db7e6a41a89f618792c92c0e97cc736e1b13f)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-version: 10.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-09-04 18:23:55 +02:00
FEA-eng b9efb481a2 PartDesign: Correct typo in multiple solids error (#23642)
* PartDesign: Update FeatureFillet.cpp

* PartDesign: Update FeaturePipe.cpp

* PartDesign: Update FeatureLoft.cpp

* PartDesign: Update FeatureExtrude.cpp

* PartDesign: Update FeatureGroove.cpp

* PartDesign: Update FeatureBoolean.cpp

* PartDesign: Update FeatureChamfer.cpp

* PartDesign: Update FeatureHole.cpp

* PartDesign: Update FeatureDraft.cpp

* PartDesign: Update FeatureRevolution.cpp

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor
2025-09-04 14:36:15 +00:00
FEA-eng 583dd38e08 FEM: Add property to disable PaStiX mixed precision for the ccx solver (#23539)
* FEM: Update solver_calculix.py

* FEM: Update solver.py

* FEM: Update calculixtools.py

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

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

* FEM: Update calculixtools.py

* FEM: Update task_solver_ccxtools.py

* FEM: Update task_solver_ccxtools.py

* FEM: Update solver_calculix.py

* FEM: Update solver.py

* FEM: Update calculixtools.py

* FEM: Update task_solver_ccxtools.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-04 09:23:08 -05:00
PaddleStroke 0f07a936d9 PartDesign: Polar pattern: Spacings off by one. 2025-09-04 13:56:06 +02:00
Chris Hennes fd20bdd6d8 Update translations 2025-09-03 2025-09-04 11:37:11 +02:00
FEA-eng f00aa86afc FEM: Amplitude support for final temperature field (#23530)
* FEM: Update FemConstraintInitialTemperature.cpp

* FEM: Update FemConstraintInitialTemperature.h

* FEM: Update write_amplitude.py

* FEM: Update write_constraint_finaltemperature.py
2025-09-03 22:15:25 -05:00
pre-commit-ci[bot] d59babd8d3 [pre-commit.ci] pre-commit autoupdate
updates:
- [github.com/pre-commit/mirrors-clang-format: 182152eb8c5ce1cf5299b956b04392c86bd8a126 → 86fdcc9bd34d6afbbd29358b97436c8ffe3aa3b2](https://github.com/pre-commit/mirrors-clang-format/compare/182152eb8c5ce1cf5299b956b04392c86bd8a126...86fdcc9bd34d6afbbd29358b97436c8ffe3aa3b2)
2025-09-03 22:14:55 -05:00
Roy-043 9aa7358530 Draft: check if autogroup exists 2025-09-03 22:11:48 -05:00
luzpaz 0367e5f791 CI: Add new entries to codespellignore file
Added several more typos for codespell to ignore.
2025-09-03 22:05:22 -05:00
sliptonic 0020057f83 [CAM] Make sure CAMAsset location exists (#23618)
* Fixes #22858

Ensure that the default CAM asset location exists and is created in the user data location

* Update src/Mod/CAM/Path/Preferences.py

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-03 15:32:33 -05:00
Max Wilfinger a0761c4cfa Fix missed string update 2025-09-03 13:35:10 -05:00
Ryan Kembrey c61eef3688 TechDraw: Remove duplicate import 2025-09-03 18:40:01 +02:00
Roy-043 2fa4934e3f Draft: change task panel title of Draft_CubicBezCurve to Title Case 2025-09-03 16:44:04 +02:00
Pieter Hijma 459a8bc4c8 Gui: Adjust size of the Add Property dialog 2025-09-03 15:33:45 +02:00
Pieter Hijma 66df6b39c8 Gui: Select the VarSet when clicking Std_VarSet
To make clear which VarSet is being added to, the VarSet is being
selected.
2025-09-03 11:51:14 +02:00
Pieter Hijma 550aac53a7 Gui: Improve adding multiple properties
This is based on a review of the DWG suggesting to remove the checkbox
for adding multiple properties and change the Ok button to an Add
button.

To make the impact of an extra click to cancel adding properties, the
Cancel button is the default right after adding a property (which
already disabled the Ok/Add button).
2025-09-03 11:51:14 +02:00
Pieter Hijma 93a73d55e1 Gui: Move DlgAddPropertyVarSet -> DlgAddProperty 2025-09-03 11:50:49 +02:00
Pieter Hijma 37e8a753b6 Gui: Disallow adding props to multiple objects
This commit is in preparation for switching the old Add Property dialog
to the Add Property VarSet dialog.  For now, this dialog does not handle
adding properties for multiple objects.
2025-09-03 10:24:54 +02:00
Pieter Hijma 65a8597ad8 Gui: Generalize add property VarSet dialog
This commit ensures that the adding properties does not work only for
VarSets, but also for generic property containers.
2025-09-03 10:21:07 +02:00
Pieter Hijma 35cd20bb17 Gui: Simplify title Add Property VarSet dialog 2025-09-03 10:21:07 +02:00
Ryan Kembrey a8d8d59f2e TechDraw: Fix regression in hiding vertices 2025-09-03 16:17:25 +10:00
tetektoza ec8cff9e5f Measurement: Provide correct VP name for COM (#23329)
* Measurement: Provide correct VP name for COM

This patch tries to provide proper ViewProvider name for COM, which
results in a proper pixmap assignment, which won't fallback to the
default measurement's tool icon for COM.

Since MeasurePython runs before actual COM python proxy assignments,
we can't access proxy easily from this point of code.

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

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

* Measure: Use starts_with instead of find

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>

* Update src/Mod/Measure/App/MeasureBase.cpp

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-03 05:17:24 +00:00
mosfet80 9c02cd0014 TechDraw: Remove unused functions (#21483)
* removed unused functions

remode update

* removed unused function

removed     CreateTechDrawCommandsDims()
clean code

* removed unused function

removed     CreateTechDrawCommandsDims()
clean code

* TD: Restore CreateTechDrawCommandsDims() function

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-02 23:45:40 -05:00
George Peden eef738b312 Feature/sketcher constraint symbol size (#23366)
* Sketcher: Initial wiring up of independent contraint symbol size.

* Sketcher: Align constraint symbol size controls with other preferences

- Refactored the Sketcher preferences UI to place the "Constraint symbol size" checkbox and spinbox in separate grid columns, matching the layout of other settings.
- Ensured the spinbox aligns visually with other value fields for a more consistent and professional appearance.
- Preserved the enable/disable behavior of the spinbox based on the checkbox state.

* Update constraint size label

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

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

* style: simplify constraint icon size logic and remove stray blank line

* Sketcher: optional constraint symbol size defaults to font size preference (per PR comment)

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-02 22:58:56 -05:00
tetektoza dd466ac8e7 Gui: Use QByteArray directly in setData without intermediate variable 2025-09-03 01:24:58 +02:00
tetektoza c0763302df Gui: Use variable assignment directly in if statement 2025-09-03 01:24:58 +02:00
tetektoza 91b4719e30 Gui: Use copy for currentSelections in Clarify Selection tool 2025-09-03 01:24:58 +02:00
tetektoza 8bc6ab2eef Gui: Add a comment explaining invoke(0) call in NavigationStyle 2025-09-03 01:24:58 +02:00
tetektoza 1a6a28f9a0 Gui: Extract helper methods for navigation context menu 2025-09-03 01:24:58 +02:00
tetektoza 5a17297f5e Gui: Use QStringLiteral for selected element 2025-09-03 01:24:58 +02:00
tetektoza 644e7ae5af Gui: Fix typo in SelectionView 2025-09-03 01:24:58 +02:00
tetektoza 52a64aa5b7 Gui: Check for nullptr in activeWindow in CommandView directly 2025-09-03 01:24:58 +02:00
tetektoza 2905476491 Gui: Use freecad_cast where possible in CommandView for ClarifySelection 2025-09-03 01:24:58 +02:00
tetektoza c3c0644020 Gui: Use designated initializer in CommandView 2025-09-03 01:24:58 +02:00
tetektoza 72008cb7f6 Gui: Initialize SbVec2s point directly in CommandView 2025-09-03 01:24:58 +02:00
tetektoza 6f0dd99819 Part/Gui: Rename Pick Geometry tool to Clarify Selection
Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:58 +02:00
tetektoza 0608f3b56c Gui: Add support for toggling PickGeometry with long-press LMB
Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:58 +02:00
tetektoza edfeff975e Core/Gui: Render primitives on top of the scene in PickGeometry
+ added some better grouping for items, which are assigned per object
  right now. For example, if we exceed 10 items per object it gets an
  additional group.

Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:58 +02:00
tetektoza 5e0b74dce6 Core: Add preselect on hovered menu items in PickGeometry tool
Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:57 +02:00
tetektoza b3f9eba742 Core: Respect highlighting for preselection too
Co-authored-by: realthunder <realthunder@users.noreply.github.com>
2025-09-03 01:24:57 +02:00
realthunder c52bfd37de Gui: Add a context menu to select obstructed items (from RT fork)
As the title says, this is from RT's fork. I only adjusted it a little
bit and removed pie selection which was previously in the
implementation.

To activate context menu - "G, G", then if it can't resolve edges vs
faces, it adds QMenus on top to let user decide which one to select.

Co-authored-by: tetektoza <tetektoza@users.noreply.github.com>
2025-09-03 01:24:57 +02:00
Benjamin Nauck 04e085cba3 Merge pull request #23344 from 3x380V/moment
Core: Distinguish between energy and torque physical quantities
2025-09-02 23:58:19 +02:00
Kacper Donat a581ade312 PartDesign: fix the draggers for pad type and hole (#23582)
* PartDesign: fix the draggers for pad type and hole

* Gui: remove duplicated checkbox
2025-09-02 23:28:23 +02:00
captain0xff 6057e4a7ad Gui: remove duplicated checkbox 2025-09-03 01:11:16 +05:30
Chris Hennes 62ec6f773c App: Fix safe mode and home directory 2025-09-02 21:39:09 +02:00
Roy-043 09b97e0bfd Draft: Fix some prefs GUI texts (related to Title Case) (#23573)
* Draft: Fix some prefs GUI texts (related to Title Case)

* Draft: Fix some prefs GUI texts (related to Title Case)

* Draft: Fix some prefs GUI texts (related to Title Case)
2025-09-02 21:18:57 +02:00
captain0xff 599d82488d PartDesign: fix the draggers for pad type and hole 2025-09-03 00:42:39 +05:30
tarman3 d2f5dcebc2 CAM: Create stock height 1 mm for flat objects 2025-09-02 20:50:44 +03:00
tarman3 e248f98097 CAM: Fix Task panels for expression in App::PropertyLink (#22955) 2025-09-02 11:22:32 -05:00
tarman3 4fc408910c CAM: Fix uccnc postprocessor for G2|G3 (#23194) 2025-09-02 11:20:14 -05:00
J-Dunn 96f32cae5a CAM: correct grbl_post retract heights (#23010)
* CAM: correct grbl_post retract heights

Some small corrections to retraction heights in expansion of G8x drilling cycles for GRBL machines. 

Add comment blocks from NIST definitions to aid maintenance and understanding. 
Rename some variables for clarity and ease of future maintenance.

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

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

* correct typo which prevented final retract move

* [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-09-02 11:15:37 -05:00
tarman3 dfcaeaa5d2 CAM: Fix missed gcode save dialog (#23517) 2025-09-02 11:02:24 -05:00
captain0xff d37230175f Part: disable dragger for the thickness operation 2025-09-02 17:39:17 +02:00
David Kaufman f156e467c9 [CAM] Fix ramp dressup performance (#21944)
* [CAM] fix biggest performance problems in ramp dressup

key items:

- finding the index of the current edge with edeges.index(edge) was very
  expensive; fixed by tracking the index while looping

- checking which edges were rapids with edge equality was also
  expensive; fixed by keeping a list of indexes of rapid input edges,
and tagging output edges with whether or not they are rapids

* [CAM] comment out Path.Log.debug in hot segments of ramping code

Even when low level logs are supposed to be suppressed, Path.Log.debug
takes take invoking traceback.extract_stack. This time adds up if logs
are invoked in frequently run loops.

* Fix CAM test

* [CAM] reimplment ramp method 1 with faster code

* [CAM] reimplement ramp methods 2, 3, and helix

* [CAM] patch to make output match original

* [CAM] ramping full performance + functionality fix
2025-09-02 10:32:03 -05:00
David Kaufman 540ce39cb1 [CAM] Add UI elements for viewing and editing tool controller parameters from within the operation edit UI (#23180)
* [CAM] extract tool controller ui elements into their own file

* [CAM] make the changes in the tool controller UI only apply when ok is clicked

* [CAM] Add tool controller edit panel to the Profile operation

* [CAM] Add copy button to in-operation tool controller editor

* [CAM] clean up changes

* [CAM] Add tool controller edit UI to all operations

Notes on changes that were not a simple copy/paste job from the changes
I made for Profile:

- Deburr: changed TC/coolant rows from 1 and 2 to 0 and 1

- Probe: didn't work at all initially due to bug in main where ShapeName
  changed to ShapeType. I added a utility for reading either a ShapeType
or a ShapeName (check for both properties, convert ShapeType to lower
case) and applied it to probe and camotics

- Drilling: moved Keep Tool Down checkbox up from row 8 to row 2 (all
  intermediate rows were missing) and added the edit checkbox in row 3
below it

- VBit, Probe (or anything else that requires a specific tool type): in
  Base.py setupToolController(), I added a check to see if the currently
selected tool is an invalid type, and if so and there is a valid tool,
then change to that one. This fixes two UI bugs. Plausibly pre-existing,
if there is one valid tool and an invalid tool is selected, it's
impossible to switch to the valid one because you can't generate a combo
box change event for the new tool. Definitely new: if an invalid tool is
selected and there are no valid tools, the combo box will be empty but
the new tool controller edit utility will let you edit the current TC
anyway.

- Thread Milling: replaced the Tool Controller GroupBox with the
  standard QFrame layout, and added the checkbox. Note that this
operation doesn't have a UI element for coolant -- likely a bug, but I
didn't look into it

- Surface: Changed from form layout to grid layout. Deleted an old
  SurfaceEdit.ui file -- it was replaced with PageOpSurfaceEdit.ui in
2017 but not deleted (commit 8637831132)

- Waterline: Changed from form layout to grid layout

* [CAM] Bug fixes

setupUi() wasn't called on the tool controller editor, preventing
changes in its UI from being written back to the object immediately.
This caused weird behavior where if you edited a field twice it would
reset the second time it was focused

Added a hook to automatically update the TC combo box when the TC name
(or anything else about it, since that was easier) changes

* Fix usage of QSignalBlockers

* [CAM] Block scroll events on tool number and spindle direction when not
focused

Specifically, if you mouse over either of these UI elements and use the
scroll wheel, it used to focus the element and change its value. This
commit makes it do neither of those things, for these specific elements,
as a measure against users accidentally changing these values.

* disable tcNumber edit field in operations panel

* Add "New tool controller" option to TC combo box

When selected, it opens (toggles, technically) the tool bit dock and
returns to the previous selection. Adding a new tool controller using
the dock (already, before this commit) automatically switches the
operation's tool controller to the new one

* Add "Copy" option to tool controller combo box

* Copy TC function only in combo box, no button

* [CAM] update in-operation "new tool controller" function to use a dialog

* [CAM] make the tool selector always a dialog and never a dock

* remove spacer from ToolControllerEdit.ui to fix exces white space

* [CAM] change tool dialog default sizing/spacing

* [CAM] fix bug where copying tool controller doesn't copy all values
2025-09-02 10:19:33 -05:00
marioalexis bfb912b38e Fem: Update CalculiX test 2025-09-02 10:33:35 -03:00
marioalexis 3207ca6b4a Fem: Use maximum increments for electromagnetic mode 2025-09-02 10:33:35 -03:00
marioalexis c779bc1374 Fem: Rename CalculiX time properties 2025-09-02 10:33:35 -03:00
marioalexis a98500cc05 Fem: Enable time increments for non-transient analysis 2025-09-02 10:33:35 -03:00
Benjamin Nauck 3e73005653 Merge pull request #23519 from kadet1090/show-axis-cross-on-top
Gui: Show Axis Cross on top
2025-09-02 15:12:39 +02:00
PaddleStroke a9065a33c5 Syntax error 2025-09-02 14:40:37 +02:00
Ian 'z0r0' Abreu 0217c1ef97 updating docblock locations. 2025-09-02 08:28:47 -04:00
Ian 'z0r0' Abreu 8d56e3e529 reverting author metadata 2025-09-02 08:25:37 -04:00
luzpaz e1dcb21165 AddonManager: ignore everything but dirs in getVerboseAddOnsInfo
Before this PR addon manager was displaying manifest.json files along with backup files. Now those are ignored.
Fixes #23545
2025-09-01 22:32:23 -05:00
Ian 'z0r0' Abreu b24040ee52 Adding license documentation to interface class docblocks. 2025-09-01 21:50:59 -04:00
B0cho cc46344f6b Core: Move 'Result' message below 'Expression' input 2025-09-02 01:09:12 +02:00
B0cho 8450fbae97 Core: Show 'Expression' completer under cursor position 2025-09-02 01:09:12 +02:00
B0cho 56be60c639 Core: Fix 'QTextEdit' background-color
Suggested and Co-authored-by: @MisterMakerNL
2025-09-02 00:41:39 +02:00
B0cho 8b1dc9a913 Core: Make too long 'Result' message elide in Expression editor 2025-09-02 00:41:39 +02:00
B0cho 1f4b1d85c2 Core: Remove redundant spacers from Expression editor 2025-09-02 00:41:39 +02:00
B0cho 2ab3eaba21 Core: Fix 'Result' message text not wrapped in Expression editor 2025-09-02 00:36:16 +02:00
Kacper Donat 6c49ff9b5b Merge pull request #23549 from captain0xff/gizmo
PartDesign: improve the interactive draggers
2025-09-02 00:25:55 +02:00
B0cho 8b93ec2eb2 Core: Switch widget from 'ExpressionLineEdit' to 'ExpressionTextEdit'
+ minor dialog layout adjustments
2025-09-01 23:47:16 +02:00
PaddleStroke 3ce9452771 Assembly: Solver message taskbox. UI setup, App not implemented yet. (#23420)
* Assembly: Solver message taskbox. UI setup, App not implemented yet.

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

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

* Update TaskAssemblyMessages.cpp

* Update ViewProviderAssembly.cpp

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-09-01 21:29:06 +00:00
Kacper Donat 821e79b58a Merge pull request #23552 from pieterhijma/delete-key-prop
Gui: Add a binding for the Delete key to remove a property
2025-09-01 23:18:15 +02:00
Kacper Donat 682ba64c46 Gui: Show Axis Cross on top 2025-09-01 23:07:53 +02:00
Kacper Donat 45103d866d Gui: SoFCPlacementIndicatorKit add missing headers 2025-09-01 23:07:32 +02:00
Benjamin Nauck e5ed0b3cb9 Merge pull request #23399 from wwmayer/quick_measure
Measure: Fix quick measure command
2025-09-01 21:11:26 +02:00
captain0xff afdeacee05 PartDesign: set the linear dragger increment based on the zoom level 2025-09-02 00:32:25 +05:30
Pieter Hijma f552808811 Gui: Add Property View delete key binding
This commit adds a binding for the delete key to delete properties from
property containers.
2025-09-01 20:53:32 +02:00
captain0xff 37100c6179 PartDesign: fix draggers for chamfer with two dimensions 2025-09-01 23:20:18 +05:30
jffmichi a353ef9307 CAM: use dict constructor for Command in VCarve 2025-09-01 11:24:32 -05:00
Chris Hennes 423ea14ff2 Core: Record module failure information during startup 2025-09-01 18:10:04 +02:00
drwho495 c01b12044a PartDesign: Fix revolution's Toponaming support (#23342)
* PartDesign: Fix revolution's Toponming support

* fix test
2025-09-01 10:56:43 -05:00
tetektoza 7c4131c4ef Sketcher: Disable autoscale if new constraint value is below precision
As the title says - we can get into a scenario where user can specify
constraint equal to 0.0, or similar small value and the scale factor
will become 0 as well, resulting in all geometry trying to be rescaled
to degenerate geometry.

So this patch filters those values out, and bails out from auto-scaling
leaving only solver to handle this value.
2025-09-01 10:55:12 -05:00
Edgar Robles 5287e3f4a6 BIM: Add T slot profile option (#23334)
* feat(profiles): Add square metric t-slot profiles

Request also allows to use profiles in quetzal workbench

* fix(ProfileTaskPanel): fix class name on proxy & sufix

* refactor(ArchProfile, Arch): Modify T-s to TSLOT

and also fix hole_diameter not assigned

* fix(ArchProfile,profiles): Change t slot profile class Name
2025-09-01 17:54:20 +02:00
Chris Hennes d7e2c42f45 Update clang-tidy checks to remove avoid-do-while
While the advice is good, the overwhelming majority of "do-while" warnings that come up in our codebase are macros using a standard pattern using a do-while loop to encapsulate the macro's work.
2025-09-01 17:51:51 +02:00
Benjamin Nauck 14f9e85600 Merge pull request #23502 from maxwxyz/issue-20633
Part: Improve TopoShape::findPlane
2025-09-01 17:47:32 +02:00
Chris Hennes e706122bbb Update translations 2025-08-30 2025-09-01 17:44:54 +02:00
Kacper Donat 767c3f1f67 PartDesign: Highlight profile for profile based features
This adds highlight for sketches etc that are used to create certain
featuires.
2025-09-01 10:44:29 -05:00
Roy-043 23691409e0 BIM: fix self.Type regression for Wall, Stairs and Structure (#23476)
* BIM: fix self.Type regression for Wall

* BIM: fix self.Type regression for Stairs

* BIM: fix self.Type regression for Structure
2025-09-01 17:44:10 +02:00
Adrian Insaurralde Avalos ff91ce148f Mesh: fix #18801 - simply call gmsh if gmsh executable path is empty 2025-09-01 10:43:00 -05:00
PaddleStroke f51e1eeb22 PartDesign: Enable selecting a sketch as base plane of another sketch (#23428)
* PartDesign: Enable selecting a sketch as base plane of another sketch

* to squash

* Part: Attacher: enable attaching to empty objects such as empty Sketch or Body.

* Update SketchWorkflow.cpp
2025-09-01 17:39:51 +02:00
David Balch 7d38cc45ec BIM: Remove wrong IfcType for Column/Beam
Removes check on function parameters for height & length (first
introduced in commit 5217b24), relying on values assigned in "obj".

If those params are present, they're assigned to "obj" anyway, so
the check is redundant.

Fixes #22585
2025-09-01 17:38:27 +02:00
FEA-eng 0a392c2a3f FEM: Add support for CalculiX truss elements (#23224)
* FEM: Update element_geometry1D.py

* FEM: Update write_femelement_geometry.py

* FEM: Update write_mesh.py

* FEM: Update solver.py

* FEM: Update solver_calculix.py

* FEM: Update element_geometry1D.py
2025-09-01 10:37:44 -05:00
FEA-eng a5751e5a3b FEM: Update DlgSettingsFemZ88.ui 2025-09-01 17:18:57 +02:00
Pieter Hijma 14087606f6 Gui: Fix Property View copy bug
The context menu of the property view shows a "Copy" action for
properties with which the value of the property can be copied to the
clipboard.  When multiple properties are selected, this menu item
appears multiple times and in that case it copies the name of one of the
properties.  This commit fixes this.
2025-09-01 17:06:40 +02:00
Benjamin Nauck baef697977 Merge pull request #23101 from 3x380V/td_fixes
TechDraw: random fixes
2025-09-01 15:58:01 +02:00
Pieter Hijma cf15c637b8 Gui: Process minor review comments
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-09-01 15:32:36 +02:00
Ladislav Michl 7f2ddc5ac1 TD: remove unused clearLineSets()
d2ce7f8145 ("TD: Remove calls to now-empty clearLineSets() method")
removed last calls to clearLineSets(), so remove it entirely.
2025-09-01 14:12:58 +02:00
wmayer 2006480ae8 TD: Fix compiler warnings 2025-09-01 14:11:52 +02:00
wmayer eb2c6bf73f TD: Fix loading project files
With PR 19941 there is a regression where parts of the document
won't be restored. This is caused by overriding the virtual method
handleChangedPropertyType() but not calling the method of the base class.

While searching for a fix another problem showed up where (due to the
incomplete loading) exceptions are thrown but not handled within TD.
Therefore the method recompute() is overridden in DrawView to also handle
OCC exceptions.
2025-09-01 14:11:52 +02:00
wmayer cd31d0e698 TD: Fix crash on selecting 3D edge for dimension
Unlike in the bug description of issue 19654 the user doesn't have
to preselect an edge in the 3D view but first start the dimension
command and then select an edge.

This commit adds some security checks to TechDrawHandler::quit(),
TechDrawHandler::getPage() and TDHandlerDimension::onSelectionChanged()
to be on the safe side that no null pointers are dereferenced.

But the ultimative fix for this whole problem is to change
activateHandler() and immediately delete the passed TechDrawHandler if
it fails to find the appropriate QGVPage. This is needed as otherwise
the handler behaves like a ghost object that affects the selection
mechanism and disallows to select anything in the 3D view or the tree
view.

Fixes issue 19654
2025-09-01 14:11:51 +02:00
PaddleStroke 98ad0e9fd8 PartDesign: TaskExtrudeParameters improve ui by letting line visible 2025-09-01 08:40:29 +02:00
matthiasdanner 6d5800c862 Sketcher: Fix Assertion Crash when selecting a Constraint in a group (#23491)
* Sketcher: Fix Assertion Crash when selecting a Constraint in a group

* Update src/Mod/Sketcher/Gui/EditModeConstraintCoinManager.cpp

---------

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-09-01 06:28:13 +00:00
wandererfan f5db0c6589 [TD]fix ISOLineSpacing preference not applied 2025-09-01 00:26:22 -05:00
FEA-eng 2244a16790 FEM: Add defined temperature field with CalculiX (*TEMPERATURE) (#23277)
* FEM: add write_constraint_finaltemperature.py

* FEM: Update CMakeLists.txt

* FEM: Update membertools.py

* FEM: Update FemConstraintInitialTemperature.cpp

* FEM: Update FemConstraintInitialTemperature.h

* FEM: Update write_constraint_initialtemperature.py

* FEM: Update write_femelement_material.py

* FEM: Update writer.py

* FEM: Update write_constraint_finaltemperature.py

* FEM: Update write_femelement_material.py

* FEM: Update write_femelement_material.py

* FEM: Update box_static.inp

* FEM: Update ccx_cantilever_beam_circle.inp

* FEM: Update ccx_cantilever_beam_pipe.inp

* FEM: Update ccx_cantilever_beam_rect.inp

* FEM: Update ccx_cantilever_ele_hexa20.inp

* FEM: Update ccx_cantilever_ele_quad4.inp

* FEM: Update ccx_cantilever_ele_quad8.inp

* FEM: Update ccx_cantilever_ele_seg2.inp

* FEM: Update ccx_cantilever_ele_seg3.inp

* FEM: Update ccx_cantilever_ele_tria3.inp

* FEM: Update ccx_cantilever_ele_tria6.inp

* FEM: Update ccx_cantilever_faceload.inp

* FEM: Update ccx_cantilever_nodeload.inp

* FEM: Update ccx_cantilever_prescribeddisplacement.inp

* FEM: Update constraint_contact_shell_shell.inp

* FEM: Update constraint_sectionprint.inp

* FEM: Update constraint_selfweight_cantilever.inp

* FEM: Update constraint_tie.inp

* FEM: Update constraint_transform_beam_hinged.inp

* FEM: Update constraint_transform_torque.inp

* FEM: Update material_multiple_bendingbeam_fiveboxes.inp

* FEM: Update material_multiple_bendingbeam_fivefaces.inp

* FEM: Update material_multiple_tensionrod_twoboxes.inp

* FEM: Update material_nonlinear.inp

* FEM: Update square_pipe_end_twisted_edgeforces.inp

* FEM: Update square_pipe_end_twisted_nodeforces.inp

* FEM: Update write_constraint_finaltemperature.py

* FEM: Update write_femelement_material.py

* FEM: Update write_constraint_finaltemperature.py

* FEM: Update FemConstraintInitialTemperature.cpp

* FEM: Update FemConstraintInitialTemperature.h
2025-08-31 23:28:56 -05:00
Roy-043 ad0606c69b Mesh: Gmsh dropdown to sentence case 2025-08-31 23:26:18 -05:00
Chris Hennes 8221ab77d7 Merge pull request #23503 from maxwxyz/issue-22123
Fix STEP import with bad string behavior
2025-08-31 23:23:25 -05:00
luzpaz 8f53b5164a BIM: fix trailing whitespace and refine source comment grammar (#23496)
* BIM: fix trailing whitespace and refine source comment grammar

* BIM: remove unnecessary newline
2025-08-31 23:22:39 -05:00
luzpaz e30408eec7 Part: remove trailing whitespace 2025-08-31 23:21:13 -05:00
PaddleStroke 970f771127 Core: Datums: Make getDirection and getBasePoint aware of LCS position 2025-08-31 22:54:03 -05:00
Chris Hennes 2f9f8eda18 Merge pull request #22998 from Rexbas/prevent-showing-context-menu
Navigation: Prevent showing context menu after panning or rubber band selection
2025-08-31 22:41:05 -05:00
Kacper Donat 5669db8d8b Revert "Gui: Mark mouse move action handled to skip digging nodes"
This reverts commit ccb417e00d.
2025-09-01 05:33:02 +02:00
Mathieu GRENET 692101bd1b Assembly: Fix inconsistent positioning in distance joint validation
When validating distance joints, parts would move from preview position to
a different valid solution. This was caused by preSolve() being called
inconsistently - applied during offset changes for all joint types, but
distance joints are not in JointUsingPreSolve list.

Fix: Only call preSolve() for joint types that are designed to use it,
matching the logic used elsewhere in the codebase.
2025-08-31 21:31:45 -05:00
wandererfan a0305388c3 [TD]allow finding child view outside clip rectangle 2025-08-31 20:56:14 -05:00
tetektoza 66e099aedb Merge pull request #23192 from tetektoza/fix/22253_fix_losing_expression_during_sketcher_tools_usage
Sketcher: Copy expressions when rotating/moving geometry
2025-08-31 20:12:22 -05:00
Chris Hennes b898703841 Merge pull request #23310 from Roy-043/Draft-more-logical-placement-for-3-point-arcs
Draft: more logical placement for 3 point arcs
2025-08-31 18:44:02 -05:00
Bas Ruigrok cc930ae145 Gui: Allow switch to panning after canceling sketcher rubber band selection 2025-08-31 18:37:09 -05:00
Bas Ruigrok e469eb5ccb Sketcher: Cancel rubber band selection with RMB
Cleanup
2025-08-31 18:36:38 -05:00
Ian 'z0r0' Abreu 6fa1adf141 Cleaning up xml file generation, and erroneous export annotations from interface bindings. 2025-08-31 18:28:41 -04:00
Bas Ruigrok 39329e547f Sketcher: Don't show the context menu after rubber band selection 2025-08-31 17:24:28 -05:00
Bas Ruigrok ac3b441cba Gui: Reset navigation flags when the new mode is not IDLE or when the mouse buttons are released 2025-08-31 17:24:28 -05:00
tetektoza 96d9cd3739 Core: Do not clear highlight if filter rejected selection
When user has specified a filter for a multi selection attempt, for
example Ctrl + clicking on a disallowed edge, the visual highlighting of
previously selected valid objects (that filter allowed) would disappear,
even though they were still internally valid in selection system.

The root cause of that was that when `addSelection()` failed, the code
still applied a `SoSelectionElementAction::None` to the scene graph
path, which was clearing visual highlighting for all objects in that
path, including those valid selection.

So, the fix is to set `pPath` to `nullptr` if selection fails, to
prevent any visual action from happening and being applied, in essence
leaving correct (and existing) selection untouched.
2025-08-31 17:23:26 -05:00
Chris Hennes 880df78906 Merge pull request #23062 from kadet1090/pd-boolean-preview
PartDesign: Implement preview for Booleans
2025-08-31 15:36:38 -05:00
Kohei Takahashi ccb417e00d Gui: Mark mouse move action handled to skip digging nodes 2025-08-31 22:09:32 +02:00
theo-vt 0c4e125e44 Quickmeasure: Make measuring holes easier (#23385)
* Measure: Add circle center distance types to quickmeasure

* Measure: Add cylinder axis distance types to quickmeasure

* Measure: Fix PointToCylinder minimum distance not computing

* Quickmeasure: compute circle and cylinder diameters when they are closed

* Quickmeasure: add angle measurement between cylinder & circle axes

* Quickmeasure: Remove minimum distance between circle center and cylinder surface

* [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-08-31 21:57:00 +02:00
Ryan K 25d1a51fb4 Gui: Widen the default customize dialog (#22714)
* Gui: Widen the default customize dialog

* Gui: Make panels the same width in keyboard and toolbars tabs

* Remove namespace additions

---------

Co-authored-by: Ryan Kembrey <ryan.kembrey@student.uts>
2025-08-31 21:53:51 +02:00
Ian 'z0r0' Abreu 4fc94492cd Finalizing Python interface bindings for TechDraw. 2025-08-31 15:43:50 -04:00
Ian 'z0r0' Abreu 6d3fb9393a Finalizing Python interface bindings for Robot, Spreadsheet, Surface. 2025-08-31 15:41:14 -04:00
Chris Hennes c26e3e9756 Base: Allow all valid Python 3 identifier characters
Note: Does not check for keywords, only character classes (not a change from the original code).
2025-08-31 21:39:49 +02:00
tetektoza 7b85239093 Sketcher: Use different colors for touch/window selection (#23261)
* Sketcher: Use different colors for touch/window selection

As the title says. I think it was missing, so currently right to left
motion makes the box selection in Sketcher green with dashed lines,
whereas motion from left to right makes it blue with solid lines.

* [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-08-31 21:36:24 +02:00
Kacper Donat f502aad3b8 Merge pull request #23321 from chennes/refactorApplicationAndAddVersioning
Refactor App::Application directory handling and add versioning
2025-08-31 21:35:02 +02:00
Ian 'z0r0' Abreu 6e75aef81c Finalizing Python interface bindings for Import, Measure, Mesh, Points. 2025-08-31 15:34:03 -04:00
Ian 'z0r0' Abreu 2b889560d1 Finalizing Python interface bindings for Fem. 2025-08-31 15:27:21 -04:00
Ian 'z0r0' Abreu 9008cdb8ee Finalizing Python interface bindings for CAM. 2025-08-31 15:24:02 -04:00
Ian 'z0r0' Abreu c63ac5ffbc Finalizing Python interface bindings for assembly 2025-08-31 15:19:25 -04:00
Kacper Donat edad41c245 PartDesign: Change preview parameter to opacity from transparency 2025-08-31 21:12:07 +02:00
Kacper Donat 18792297f6 PartDesign: Implement preview for Booleans 2025-08-31 21:12:07 +02:00
Kacper Donat 0aa95996d9 Part: Add transform property to SoPreviewShape 2025-08-31 21:12:05 +02:00
Pieter Hijma bc406bee68 Gui: Add editing a property tooltip
This commit adds a way to edit the tooltip of a property in the Property
View.
2025-08-31 17:42:06 +02:00
pre-commit-ci[bot] b44dc26ff1 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-08-31 12:42:10 +00:00
wmayer ee2d35cad8 Test: Add test cases for Persistence::validateXMLString 2025-08-31 14:38:25 +02:00
wmayer 696c18b6da App: Fix output string to XML
Not all unicode characters are allowed as XML output. When writing disallowed characters the SAX parser throws an exception
when loading a project file that results into a broken document and thus to a possible loss of data.

This PR replaces all disallowed characters with an underscore and prints a warning.

This fixes https://github.com/FreeCAD/FreeCAD/issues/22123
Note: It does not fix an already corrupted project file.
2025-08-31 14:38:05 +02:00
Roy-043 ffb5d7a428 Update gui_snaps.py 2025-08-31 14:33:24 +02:00
wmayer 6500a872eb Part: Improve TopoShape::findPlane
Since OCC 7.7 using GeomLib_IsPlanarSurface without a custom tolerance may fail because the default value is too strict.
To fix this problem forward the passed tolerance value to GeomLib_IsPlanarSurface.

This fixes issue 20633
2025-08-31 14:27:09 +02:00
luzpaz 9d806694ff TechDraw: remove trailing whitespace 2025-08-30 22:10:14 -05:00
luzpaz 25a94705bd PartDesign: remove trailing whitespace
Removed from src/Mod/PartDesign/App/FeatureExtrude.cpp
2025-08-30 21:53:58 -05:00
dependabot[bot] eb5ef8d30d Bump actions/dependency-review-action from 4.7.2 to 4.7.3
Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 4.7.2 to 4.7.3.
- [Release notes](https://github.com/actions/dependency-review-action/releases)
- [Commits](https://github.com/actions/dependency-review-action/compare/bc41886e18ea39df68b1b1245f4184881938e050...595b5aeba73380359d98a5e087f648dbb0edce1b)

---
updated-dependencies:
- dependency-name: actions/dependency-review-action
  dependency-version: 4.7.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-30 21:00:44 -05:00
Chris Hennes 7eb15f53e5 Merge pull request #23100 from 3x380V/points
Points: Speed up translation of imported points
2025-08-30 20:04:08 -05:00
Jiří Pinkava c72d3f706b Remove unused DAGFilter 2025-08-30 17:23:18 -05:00
tetektoza e5518f9ad1 Draft: Call autogroup in make_hatch to put hatch in active group if any (#23464)
As the title says - this patch adds autogroup to hatch, so when created
it will be put in active group.
2025-08-30 22:24:33 +02:00
Jacob Oursland d3b00bdb18 Assembly: Update OndselSolver to the latest version. 2025-08-30 15:12:07 -05:00
FEA-eng 076b0bb98f FEM: Add tied contact with CalculiX (#23327)
* FEM: Update FemConstraintContact.cpp

* FEM: Update FemConstraintContact.h

* FEM: Update write_constraint_contact.py

* [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-08-30 14:24:22 -05:00
Chris Hennes 7d38562c79 Merge pull request #23368 from kadet1090/show-placement-and-plane-in-attacher
Gui: Show placement and plane in attacher
2025-08-30 14:13:43 -05:00
Chris Hennes b6705f5c60 Merge pull request #23453 from marioalexis84/fem-2d_calculix_loads
Fem: Add support for 2D loads with CalculiX
2025-08-30 14:09:27 -05:00
Chris Hennes 22fbdf4b58 Mesh: Add boost/agorithm/string.hpp to PCH 2025-08-30 18:44:21 +02:00
captain0xff 6e896b1248 PartDesign: add interactive gizmos 2025-08-30 17:02:52 +02:00
PaddleStroke 82ca06e7df Link: MaterialOverride: fix transparency inversion 2025-08-30 16:32:23 +02:00
marioalexis d35e5613cf Part: Remove PartDesign header 2025-08-30 15:06:31 +02:00
Max Wilfinger b57d0f37aa TechDraw: Change navigation cursors to SVG 2025-08-30 11:23:07 +02:00
Max Wilfinger 8132ffe9f0 Gui: Use BitmapFactory for generating cursors 2025-08-30 11:23:07 +02:00
Max Wilfinger 7293b323c4 Gui: Change navigation cursors to SVG 2025-08-30 11:23:07 +02:00
marioalexis a8747dca2a Fem: Update CalculiX test files 2025-08-29 19:57:42 -03:00
marioalexis 5fb640f219 Fem: Remove code duplication in MeshSetsGetter class 2025-08-29 19:57:42 -03:00
marioalexis 98e8704e79 Fem: Update body heat source element getter for CalculiX 2025-08-29 19:57:42 -03:00
marioalexis a907b60561 Fem: Add support for 2D geometries to Pressure constraint - fixes #12778 2025-08-29 19:57:42 -03:00
marioalexis 7027caf0aa Fem: Add support for 2D geometries to HeatFlux constraint 2025-08-29 19:57:42 -03:00
marioalexis 7afa56652c Fem: Add support for 2D geometries to Contact constraint - fixes #13280 2025-08-29 19:57:36 -03:00
marioalexis c483f5a890 Fem: Add support for 2D geometries to Tie constraint - fixes #13280 2025-08-29 14:03:31 -03:00
marioalexis 2e18224d8e Fem: Update electrostatic element getter for CalculiX 2025-08-29 14:03:31 -03:00
marioalexis 345f160e72 Fem: Improve meshtools.get_ccx_elements* functions 2025-08-29 14:03:31 -03:00
tetektoza 3b76d77ed8 Sketcher: Introduce Select All (Ctrl + A) (#23289)
* Sketcher: Introduce Select All (Ctrl + A)

As the title says, this allows selecting all geometries on the sketch
with CTRL + A shortcut, plus also allows to select "Select All" option
from Edit menu.

* Sketcher: Use fmt instead of std::stringstream in selectAll

* Sketcher: Fix typo in selectAll

Co-authored-by: João Matos <joao@tritao.eu>

---------

Co-authored-by: João Matos <joao@tritao.eu>
2025-08-29 16:52:43 +02:00
wwmayer e55e7f75d2 PD: Fix creation of pad from base feature
In versions prior to 1.0 there was never the requirement that the shape of a FeatureBase must contain a solid. This has changed with 7a4bc95d47 for no obvious reason. This requirement should be dropped again.

In versions prior to 1.0 the method Feature::getBaseShape() was used within the Pad feature to check if the base feature has a solid. This method throws an exception if the shape doesn't have a solid.
Since version 1.0 the new method Feature::getBaseTopoShape() is used. As parameter a boolean is passed to either throw an exception or silently return a null shape. The implementation of this function is inconsistent:
If the parameter is false it throws an exception if the base feature's shape has no solid but if the parameter is true it doesn't check if the shape has a solid and returns it as is.

This leads to incorrect behaviour in the calling instance where the shape of the base feature is tried to be fused with the padded shape. This operation will fail if the shape of the base feature has no solid.

This fixes https://github.com/FreeCAD/FreeCAD/issues/23348
2025-08-29 16:28:38 +02:00
luzpaz 13c9f5da83 Fix various typos
Found via codespell
2025-08-29 10:03:57 +02:00
PaddleStroke 7d3dd2605f PartDesign: Fix symmetric regression & LengthAlongSketchNormal (#23418)
* PartDesign: Fix symmetric regression

* to squash

* Fix LengthAlongSketchNormal not working

* to squash

* Fix checkbox not initially visible
2025-08-29 10:03:16 +02:00
Chris Hennes c4da72f55e CAM: Eliminate C++11 compiler warning by explicitly defaulting copy 2025-08-28 18:30:56 -05:00
Chris Hennes ff1932d550 FEM: remove unused variable from handlePropertyChange 2025-08-28 18:30:55 -05:00
Chris Hennes ece6353bd7 Part: Rename layout to avoid conflict 2025-08-28 18:30:55 -05:00
Chris Hennes acf9827891 PD: Remove unused parameter from *ReferenceSelection 2025-08-28 18:30:55 -05:00
Chris Hennes 780c49b6f0 Sketcher: Remove unused parameter from *ReferenceSelection 2025-08-28 18:30:55 -05:00
Chris Hennes 545dadab4d Gui: Remove unused variable from fuzzyMatch() 2025-08-28 18:30:22 -05:00
Chris Hennes 3f85cf14d3 Gui: For Qt 6.5 and later, use ParseOptions in xml 2025-08-28 18:30:22 -05:00
Chris Hennes 4be6a64abb Part: Remove unused arguments from isLinearEdge 2025-08-28 18:30:22 -05:00
Kacper Donat 78a579804c Gui: Fix reloading of themes 2025-08-28 17:14:55 -05:00
Max Wilfinger 9cae60a70f Update UI strings from Crowdin reports for consistency 2025-08-28 11:45:38 -05:00
Roy-043 6ab8589a03 Draft: Add edge-face intersection snap 2025-08-28 16:16:38 +02:00
Chris Hennes b1b97e44f1 Update translations 2025-08-28 16:14:49 +02:00
Roy-043 f7e88675e9 Mesh: Change 1 missed dialog title to Title Case (#23422)
* Mesh: Change 1 missed dialog title to Title Case

* [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-08-28 10:51:14 +00:00
Chris Hennes 4f61369339 Addon Manager: Sync with upstream 2025-08-27 2025-08-28 11:24:50 +02:00
Kacper Donat 94e978439c Gui: Do not compute preview while restoring 2025-08-28 10:30:52 +02:00
Kacper Donat 44f58d7b72 Merge pull request #22923 from MisterMakerNL/Stylesheet_fixes2
Stylesheet fixes
2025-08-27 21:58:50 +02:00
Chris Hennes 102d0a9ac8 App: refactor to use unique_ptr
Also address other reviewer comments.
2025-08-27 11:51:22 -05:00
Chris Hennes 1ad8d0c0f2 Gui: Refactor to not use std::ranges
Older Ubuntu doesn't like the mechanism used to split on commas
2025-08-27 11:51:22 -05:00
Chris Hennes 58126c20e2 App: Fix problems with temp dir creation 2025-08-27 11:51:22 -05:00
Chris Hennes 2af71a5288 Gui: Detect new versions and offer to migrate
At the very end of the startup process, check to see if we are using a
versioned directory from a previous version, or we are not versioned at
all but are using the system's default storage location (that is, not a
custom config path set on the command line, etc.). If so, offer to
migrate the old configration folders into new ones for the current
version.
2025-08-27 11:51:22 -05:00
Chris Hennes 7ed4a9b731 App: Add directory versioning for data and config
At the application level, support the existence of subdirectories inside
the original config and data paths for a specific version of the
software. For a new installation, create them, but for an existing
installation use the most recent available version, even if it's not the
current one (and even if it's not versioned at all). Any migration must
be done at the GUI level due to the amount of data that is potentially
being copied during that process.
2025-08-27 11:51:22 -05:00
Chris Hennes 25f8a1eb57 App: Migrate directory handling to helper class
Use std::filesystem wherever possible, replacing most uses of
std::string when the object is actually a path. This is the first stage
of refactoring, and does not make any changes to Application that affect
client code. Access to the new directory-handling class is implemented,
but is unused by any external code.
2025-08-27 11:51:22 -05:00
Kacper Donat 56d8d37ab4 Gui: Move style parameters to yaml files 2025-08-27 17:59:10 +02:00
MisterMakerNL f87a9646a7 Gui: Various fixes to official themes
Updated PropertyEditor QLabel and QPushButton styles for better visual consistency
and usability, including specific pushbutton styling for the Placement tool. Adjusted
QCheckBox disabled indicator styles to use consistent border and background colors,
and fixed background color for checked and indeterminate disabled states.

Gave inactive and active tab their own token. Fixed missing hover for
scrollbar.

Changed the value of EditedEdgeColor in the FreeCAD Light preference
pack Due to contrast issues with default shape color.

Refreshed Theme_thumbnail_dark.png and Theme_thumbnail_light.png images.
Updated Thumbnails_themes.svg with new Inkscape version metadata, export
paths, and visual adjustments, including color and layout changes to
theme preview rectangles.

Refreshed Theme_thumbnail_dark.png and Theme_thumbnail_light.png images.
Updated Thumbnails_themes.svg with new export filenames, DPI settings,
and adjusted some SVG properties for improved export consistency.

Changed the TextDisabledColor to fix issue with lighten full black.

Adjusted the QComboBox padding-right from 2px to 18px in FreeCAD.qss to
provide space for the check-mark indicating the active item.

Changed the 'HighlightColor' value in the FreeCAD Light preference pack
configuration to dark green to solve contrast issues.

Introduces InActiveTabBackgroundColor and ActiveTabBackgroundColor to
both FreeCAD Dark and FreeCAD Light preference packs for improved tab
appearance customization.
2025-08-27 17:58:57 +02:00
Chris Hennes bf4c850a4c Merge pull request #23140 from kadet1090/yaml-source-style-parameters
Gui: Add YamlParameterSource for StyleParameters
2025-08-27 10:34:17 -05:00
Kacper Donat 7c2f35c73f Gui: Show placement and plane in attacher 2025-08-27 16:53:37 +02:00
Kacper Donat 78bacd99d0 App: Add helpers for guarding property overrides.
Within code often it is required to temporarly override value of some
object properties. To properly restore old values they must be stored
somewhere and the developer must remember to manualy restore them.

This commit introduces utilities that can be used to make it easier
using RAII idiom to guard the overrides.
2025-08-27 16:53:37 +02:00
Kacper Donat 1720a71e33 Merge pull request #22944 from pieterhijma/expr-dialog-varset
Gui: Improve Expression dialog for VarSets
2025-08-27 16:14:25 +02:00
wwmayer 8512585a41 Measure: Fix quick measure command
* Clear status bar when switching off quick measure
* Activate quick measure by default
* Remove command from toolbar as there is currently no icon
2025-08-27 16:01:54 +02:00
Kacper Donat 27d2178008 Merge pull request #22389 from PaddleStroke/pd_transform
PartDesign: Transform tools
2025-08-27 15:22:26 +02:00
Pieter Hijma 8887ac8dff Gui: Add more translations to expr dialog
This adds translations to the feedback on the expression, for example if
there is a unit mismatch.
2025-08-27 14:59:28 +02:00
Pieter Hijma f672637155 Gui: Make expr dialog input validation themeable 2025-08-27 14:58:44 +02:00
marioalexis 105e918594 Fem: Acquire the GIL before running Python code 2025-08-27 14:58:06 +02:00
wwmayer 8944fd7d5e Fem: Fix crash when writing mesh to z88 file
For the z88 export the FemMesh must be passed to its Python wrapper which will increase the counter upon construction and decrease it upon destruction. If the counter becomes 0 the FemMesh will be destroyed too which causes a crash.

To fix the crash the counter must be increased and safely decreased after the lifetime of the Python wrapper.

This fixes https://github.com/FreeCAD/FreeCAD/issues/23380
2025-08-27 14:57:50 +02:00
Paul Lee 5af7ad5df4 [ArchStructure] Fix Regression : FaceMaker
Fix #22822

See discussion and example model file in github :-
https://github.com/FreeCAD/FreeCAD/issues/22822
2025-08-27 12:30:32 +02:00
FEA-eng 0bf22ffca8 PartDesign: Update missed error message about multiple solids (#23392)
* PartDesign: Update FeatureLoft.cpp

* PartDesign: Update FeatureExtrude.cpp

* PartDesign: Update FeaturePipe.cpp

* PartDesign: Remove empty lines added by GitHub editor

* PartDesign: Remove empty lines added by GitHub editor
2025-08-27 09:37:53 +00:00
Pieter Hijma 4cf96385f3 Assembly: Update Ondsel Solver to the latest 2025-08-27 11:37:30 +02:00
Pieter Hijma 64895e0dad Gui: Add translations expression dialog VarSets 2025-08-27 09:52:50 +02:00
Pieter Hijma a9de6875a1 Gui: Process minor review comments
Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-08-27 09:52:50 +02:00
Pieter Hijma efcbb008ac Gui: Process comments DWG expression dialog
This commit gives an error box on invalid input for the VarSet inputs.
2025-08-27 09:52:50 +02:00
Pieter Hijma 7bce610ef5 Gui: Process comments DWG expression dialog
This commit ensures that the buttons stay at the end of the dialog.
2025-08-27 09:52:50 +02:00
Pieter Hijma 7f758606bf Gui: Process review comments expr dialog
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-08-27 09:52:50 +02:00
Pieter Hijma d09cba0092 Gui: Improve presenting VarSets in expr dialog 2025-08-27 09:52:50 +02:00
Pieter Hijma 459726a43f Gui: Stop remember state expression dialog
Before this commit, the expression dialog remembered the state of
whether the varset information should be shown.  This is removed
according to #17075.
2025-08-27 09:52:50 +02:00
Pieter Hijma 72fabf98b3 Gui: Improve layout expression dialog for varsets
According to #17075
2025-08-27 09:52:50 +02:00
Chris Hennes 5c73859134 Merge pull request #23374 from wwmayer/issue_23353
Exporting mesh to Z88 format no longer breaks all export and configs
2025-08-26 23:20:25 -05:00
wwmayer 99ad338d4b Fem: Fix file suffixes
*i1.txt or *o2.txt are not valid suffixes for a file dialog. In the past (until 2018) the suffixes were set to *.txt but this has been changed with 6fe8a881e.

To avoid creating invalid filenames the original suffixes are restored.
2025-08-26 22:22:56 -05:00
corpix a5b3a2caac CAM: QTableView height too small in tasks panel #22957 (#23067) 2025-08-26 15:37:46 -05:00
Roy-043 6e5a1cd31c Remove gui_utils import from make_arc_3points.py 2025-08-26 12:34:42 +02:00
Adrian Insaurralde Avalos b7d2913b0c Fix autouic warnings about duplicate names in ui files 2025-08-26 11:00:30 +02:00
wwmayer 802fd0b1ef Gui: Fix crash in FileDialog::getSaveFileName 2025-08-26 09:35:01 +02:00
paddle 8b7290e91a PartDesign: Patterns: Tooltips. 2025-08-26 09:13:17 +02:00
PaddleStroke 5d2037c820 PartDesign: Transform rework 2025-08-26 08:46:51 +02:00
Benjamin Nauck f65cdb9794 Merge pull request #23291 from 3x380V/measurement
Measure: Useability improvements
2025-08-26 06:51:50 +02:00
drwho495 594acbb6a5 Toponaming: Remove updateElementReferences call in PropertyLinkSub (#23263)
* remove updateElementReferences call in PropertyLinkSub

* Retrigger checks

* update element refs after the document has restored
2025-08-25 21:39:40 -05:00
PaddleStroke 8b9ad3b509 Sketcher: Circle DSH: move diameter constraint. Fix #22267 (#22862)
* Sketcher: Circle DSH: move diameter constraint. Fix #22267

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

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

* Improve. To squash

* [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-08-25 21:37:37 -05:00
Roy-043 314d66593c MeshPart: "Trim by plane" -> "Trim With Plane" (#23361)
* MeshPart: "Trim by plane" -> "Trim With Plane"

* [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-08-25 22:39:25 +00:00
PaddleStroke a52a130a03 Assembly: Screw Joint, fix distance name to Thread Pitch 2025-08-25 16:44:04 -05:00
Frank David Martínez M e5c912e0f3 [Core] Fix #15558: Direct expression in ternary operator (#22938)
* [Core] Fix #15558: Direct expression in ternary operator

* [Core] Added tests for Non-Numeric conditions in ternary op.

* [Core] prevent relational operator chains at grammar level.

* [Core] Rewrite expressions grammar as a layered grammar.

* [Core] Revert to left associative relops (like C/C++) plus tests.
2025-08-25 21:52:42 +02:00
paddle d85613b498 Update ondsel solver 2025-08-25 13:08:30 -05:00
Roy-043 416a2fe714 Draft: Implement hints for creation tools (#23244)
* Draft: Implement hints for creation tools

Fixes: #22886
Related: #22298

This PR implements hints for the tools in the Draft Creation toolbar.

* Fix confusing indentation

* Fix typo in comment
2025-08-25 19:42:59 +02:00
PaddleStroke a346c266e7 PartDesign: Extrude 2 sides (#21794)
* PartDesign: extrude 2 sides

* Part: OpCodes XOR

* PartDesign: Remove deprecated generatePrism functions

* PartDesign: Extrude : Update Sides combobox strings

* Change "Sides" to "Mode"

* Use OpCodes::Extrude instead of Prism.
2025-08-25 17:17:23 +00:00
Chris Hennes 3b3516de71 Material: Add missing include for PCH 2025-08-25 18:50:27 +02:00
paddle 5fa7fe5117 PartDesign: Remove message taskbox and use regular warnings instead. 2025-08-25 18:39:08 +02:00
paddle 9d12c0c7c6 PartDesign: Remove unnecessary warning. 2025-08-25 18:39:06 +02:00
paddle 9535371265 PartDesign: Rename Transformed::Mode enum 2025-08-25 18:38:34 +02:00
paddle 2e0dc45874 Part: Add PatternParametersWidget 2025-08-25 18:38:34 +02:00
paddle 89eddb4138 Gui: Move ComboLink from PartDesign to Gui. 2025-08-25 18:38:34 +02:00
paddle 00ed23845a PartDesign: add linear pattern spacing and extent icons. 2025-08-25 18:38:34 +02:00
Roy-043 ba7bb0eabe Draft: fix 2 issues with Draft_SelectPlane 2025-08-25 18:24:01 +02:00
wmayer cd1496be75 Mesh: In ReaderOBJ replace std::atoi with std::stoi 2025-08-25 18:13:59 +02:00
wmayer 8747607820 Tests: Add test case for ReaderOBJ 2025-08-25 18:13:59 +02:00
wmayer 5d75cf8fed Mesh: Improve OBJ mesh import
This change allows it to load OBJ files created by Blender.

Fixes https://github.com/FreeCAD/FreeCAD/issues/19456
2025-08-25 18:13:59 +02:00
Roy-043 f62e18b59c Draft: Support relative paths for hatch patterns 2025-08-25 18:12:20 +02:00
tetektoza 9f04f5f371 Sketcher: Set total angle to make evaluation choose it when typing in OVP (#23193)
* Sketcher: Set total angle to make evaluation choose it when typing in OVP

When typing an angle value (e.g., "315 deg") in the sketcher rotate tool,
the result differed from manually moving the mouse to achieve the same rotation.
The angle would "flip" to equivalent but opposite directions (315 deg became -45 deg)
due to smart angle selection logic choosing the "closer" alternative.

The parameter enforcement system (`doEnforceControlParameters`) calculated cursor
positions for keyboard input but never directly set the `totalAngle` value.
The mouse logic's smart angle selection algorithm then calculated totalAngle
independently, potentially choosing equivalent but opposite angle directions
(e.g., -45 deg instead of +315 deg) based on proximity to the previous angle value.

Solution is to basically predefine `totalAngle` if user has typed it so
this "smart logic" will always choose the `totalAngle` that user typed.

* Sketcher: Set total angle for arc tool

* Sketcher: Set total angle for Arc Slot tool
2025-08-25 11:10:17 -05:00
Roy-043 6c63c298fc Bim: Fix direction of panel waves (#23271)
* Update ArchPanel.py

* Update ArchPanel.py
2025-08-25 18:09:31 +02:00
MisterMakerNL a362c4915e Replace preference page icons
replaced icon so look more like the actual wb icons
2025-08-25 11:08:19 -05:00
PaddleStroke b527c1ae6a Assembly: Move label change logic to onChange 2025-08-25 11:06:11 -05:00
tetektoza 9798df0215 Part: Start listing BoundBox properties for Expression Editor
As the title says. It was missing, so this patch adds all needed.
2025-08-25 18:04:22 +02:00
wmayer 7eaa5e8844 Mesh: Fix crash MeshPy::setPoint & MeshPy::movePoint
Fixes https://github.com/FreeCAD/FreeCAD/issues/18823
2025-08-25 10:55:53 -05:00
Chris Hennes 9ee6e592b1 Tools: Small improvements to translation extraction
1) Block a problematic BIM file from extraction
2) Implement advanced scanning system to better report problems
3) Limit number of jobs in CrowdIn push to prevent 403 errors
2025-08-25 17:39:40 +02:00
xtemp09 f20c1a0102 Simplify repr() function 2025-08-25 10:38:39 -05:00
Paul Lee c7aaff410b [ArchWindow] Clone and Link to Support Sill Change
Problems / Course of Developement:

  1. Allow changing Sill feature was added in
  - https://github.com/FreeCAD/FreeCAD/pull/21005

  2. Bug fix was added in
  - https://github.com/FreeCAD/FreeCAD/commit/f6bba5d58ec7788c37977b97d7db40ef1e1ff499

  3. Further Problems were identified as discused in
  - https://github.com/FreeCAD/FreeCAD/pull/21005#issuecomment-3010959162

  'New Observation-

      1. Clone or Link to a Window does not work and return error
      2. This PR/Commit (21005) translate the Base Sketch when Sill property is changed, to change the final disposition of a Window object; however, it will also shift the disposition of a Clone and Link as a result (with error message above fixed). This is apparently not an expected behaviour.

  (Sidenote- When SketchArch Addon is installed and parametric placement is used, there would not no impact)

Current Commit:

  1. Support Link and Clone of Arch Windows (bug fix)

  2. Instead of changing base Sketch disposition, the Placement of Arch Window, Clone, or Link is adjusted.
2025-08-25 17:30:13 +02:00
paddle e2346dabd6 Sketcher: Port and fix internal faces from RealThunder's branch
Co-authored-by: Zheng Lei <realthunder.dev@gmail.com>
Co-authored-by: Kacper Donat <kacper@kadet.net>
Co-authored-by: Pierre-Louis Boyer <pierrelouis.boyer@gmail.com>
2025-08-25 17:09:10 +02:00
Max Wilfinger 3347ac343e Gui: Update header in about dialog before the 1.1 release (#22991)
* Gui: Update header in about dialog before the 1.1 release

Gui: Change main link in about dialog to main website instead of Wiki Main_Page

* Update based on code review.

Co-authored-by: xtemp09 <xtemp09@gmail.com>

---------

Co-authored-by: xtemp09 <xtemp09@gmail.com>
2025-08-25 10:07:58 -05:00
PaddleStroke 409d0e408d Assembly: Fix untranslatable string in CommandInsertNewPart.py (#23355)
* Assembly: Fix untranslatable string in CommandInsertNewPart.py

* [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-08-25 14:38:33 +00:00
PaddleStroke 150e6c9b99 Sketcher: fix constraint icon size (#22940)
* Sketcher: fix constraint icon size

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

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

* [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-08-25 15:59:46 +02:00
Furgo 4d8a277926 BIM: add interactive sun position and ray visualization to Arch Site (#22516)
* BIM: add properties for static sun sphere representation

* BIM: create Coin3D nodes for the sun sphere

* BIM: implement logic for static sun representation

* BIM: add additional info properties to sun ray

* BIM: use Draft.Line for sun ray, improve visual appearance

* BIM: color code the sun path arc

* BIM: add hour marker points to the sun path arc

* BIM: make sun path diagram smoother

* BIM: add conditional sun hour marker labels

* BIM: set constraints to time values

* BIM: remove redundant import
2025-08-25 11:37:30 +02:00
Roy-043 8d880f2860 Draft: task_orthoarray.py make some strings translatable 2025-08-25 11:31:50 +02:00
wmayer 130d5618c2 Measure: Extend angle measurements
Support to measure the angle using a planar B-spline surface
2025-08-25 09:29:29 +02:00
wmayer eebb7f7829 PD: Increase the tolerance to check for planar surfaces
The default tolerance to check for a planar B-spline surface is 1.0e-7 which might be too strict in some cases.
Therefore the tolerance is increased to 2.0e-7.

This fixes issue 21242
2025-08-25 09:29:29 +02:00
wmayer 4a5217075c Measure: Fix some linter warnings 2025-08-25 09:29:29 +02:00
wmayer 9540cfe0ea Measure: Improve TaskMeasure dialog
+ Use Qt's translation of the Save and Close buttons
+ Use QShortcut instead of eventFilter() because the latter is
  too aggressive eating all Enter and ESC events

This fixes the remaining issues as mentioned at the PR 17109
2025-08-25 09:29:29 +02:00
wmayer 75236d4b13 Measure: Allow any surface type for MeasureArea 2025-08-25 09:23:54 +02:00
wmayer 8165d12607 Measure: Fix TaskMeasure
Made several fixes to TaskMeasure:
* Move to correct namespace
* Handle possible exception in update() method
* Add null pointer checks for buttonBox
* Cannot use 'Measure::MeasurePython' as template argument in addObject<>
  because the macro PROPERTY_HEADER_WITH_OVERRIDE determines the invalid
  string 'App::FeaturePythonT<FeatureT>' so that an exception is raised

Note: The changes might fix issue 20304
2025-08-25 09:21:33 +02:00
wmayer 1acafb240a Measure: Fix several crashes in Measurement
Measurement::getShape() used to call ShapeFinder::getLocatedShape()
that failed to return a valid shape in many cases. And the calling
instance didn't check for a valid shape either which caused
a segmentation fault.

Solution:
Replace ShapeFinder::getLocatedShape() with Part::Feature::getShape()
that works more reliably and where needed check for a valid shape
before accessing it.

This fixes issue 19452 and improves the fix for 19349
2025-08-25 09:21:33 +02:00
wmayer 5d3f9cac3f Measure: Implement quick measure as command and make it toggable
The quick measure can considerably slow down the system when selecting
part elements. With this change the user is able to turn off this
bottleneck.
2025-08-25 09:21:33 +02:00
wmayer 2b2a82d901 Measure: Fix crash in Measurement::length() when selecting infinite edge (e.g. PD datum line) 2025-08-25 09:21:33 +02:00
Max Wilfinger 04e9baf533 Fix UI strings reported on Crowdin (#23297)
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-08-25 06:10:53 +00:00
Chris Hennes 18517c78e5 Addon Manager: Sync with upstream 2025-08-24 2025-08-25 07:22:52 +02:00
tetektoza 0ce6a509e7 BIM: Load QIcon for Material Editor from bytes
Loading QIcon directly from bytes is not supported in Qt6 it seems, so
this patch changes it to load it to pixmap first and then to QIcon
directly.

Plus add some alternative options to avoid tracebacks for compatibility,
as it seems that in Qt5 it either failed gracefully, or was able to load
directly from string/bytes.
2025-08-24 23:08:44 -05:00
mosfet80 475dd13052 Clean SoDatumLabel.cpp (#23217)
* Clean SoDatumLabel.cpp

removed unused variables

* Update SoDatumLabel.cpp
2025-08-24 23:00:29 -05:00
FEA-eng 20f17f7e1b FEM: Update write_step_output.py 2025-08-24 22:59:22 -05:00
tetektoza 568e63f8d5 Assembly: Allow editing joint references
As the title says - root cause of this problem was imprecise reference
matching by moving_part and TNP string processing incosistencies, so the
solution is to give enhanced matching and TNP string mapping for
reliable deletion.

Also added context menu with keyboard shortucs so user is able to delete
stuff with right click.
2025-08-24 22:58:57 -05:00
PaddleStroke e3cfca6e9d Assembly: toggle grounded: handle case of grounded joint selection. 2025-08-24 22:58:22 -05:00
Jiří Pinkava 2cf5138654 CMake: remove unused PYSIDE_WRAP_UI macro 2025-08-24 22:50:56 -05:00
tetektoza 9bff63e38d Sketcher: Fix construction lines becoming solid after box selection
Currently if user tries to use box selection while having transformed
normal line to a construction line, the line becomes solid unless it
gets moved or new geometry is created.

The root cause of that is the `draw(true, false)` call which uses
outdated solver geometry where construction=false is being specified.
Solver updates lazily, which results in construction lines in normal
sublayer instead of construction.

So, this patch changes it to `draw(false, false)` after box selection.
This ensures the redraw uses current SketchObject geometry with
up-to-date construction flags. This should be safe, as box selection is
purely visual and we do not need geometry calculations in this
operation.
2025-08-24 22:48:14 -05:00
Ian Abreu 8533b4fbb8 Core: Fixing missing python bindings. (#23054)
* Adding missing python interfaces.

* fixing interface includes.

* attempting fix for CI build error related to path resolution.

* testing build

* More testing via Github Actions...

* renaming files

* fixing comparison operator.

* reverting...

* fixing CMakeLists

* fixing binding generation issue
2025-08-24 22:43:39 -05:00
Chris Hennes d77a070bc8 Merge pull request #23104 from thyssentishman/main
Split Material Exceptions.h into source and header
2025-08-24 22:38:39 -05:00
Kacper Donat 9e0badc8a5 Gui: Fix Document Recovery screen 2025-08-24 22:32:24 -05:00
tetektoza a6e0b91758 Assembly: Auto close on deleted doc for dialogs to avoid segfaults
Currently if we close document on Assembly WB while having dialog
opened, it will throw segfault because it is not being auto closed
automatically during document close. This in turn resulted in dialog
having dangling references to document that was no longer existing,
throwing segfaults in random places.

So solution is simple - add `setAutoCloseOnDeletedDocument` for every
dialog in Assembly to avoid this situation and close every dialog upon
document close.
2025-08-24 22:22:19 -05:00
dependabot[bot] 9647b8c637 Bump actions/checkout from 4.2.2 to 5.0.0
Bumps [actions/checkout](https://github.com/actions/checkout) from 4.2.2 to 5.0.0.
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/11bd71901bbe5b1630ceea73d27597364c9af683...08c6903cd8c0fde910a37f88322edcfb5dd907a8)

---
updated-dependencies:
- dependency-name: actions/checkout
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-24 22:20:53 -05:00
wmayer de14265ba7 Part: Check for straight splines or Bezier curves
Straight splines or Bezier curves can be considered as line segments and thus can be used to measure e.g. angles.

This fixes https://github.com/FreeCAD/FreeCAD/issues/22878
2025-08-24 22:20:23 -05:00
wandererfan 7acd859634 [TD]fix crash in vertex show/hide 2025-08-24 22:19:31 -05:00
wmayer 8ec43d2966 App: Remove build dependency to Coin3D
Fixes https://github.com/FreeCAD/FreeCAD/issues/20897
2025-08-24 22:18:55 -05:00
wmayer 1dfcef2939 Part: Fix crash in MultiFuse::execute()
The processed shape is null and thus it's not allowed to call its ShapeType() method.
The crash is not directly related to the fact that there is a cyclic dependency

Fixes https://github.com/FreeCAD/FreeCAD/issues/22879
2025-08-24 22:17:48 -05:00
wmayer ecd7a47b4a Gui: Hold the GIL when clearing the form attribute
Inside TaskDialogPython::clearForm() the interpreter may execute a lot of things where at the some point the GIL must be hold.

This very likely fixes https://github.com/FreeCAD/FreeCAD/issues/22863

@thyssentishman
Please check this branch
2025-08-24 22:17:10 -05:00
Stefan Tröger 80f3b21184 FEM: Extract postprocessing data only if available. Fixes #22193 (#23127)
* FEM: Extract postprocessing data only if available. Fixes #22193

* [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-08-24 22:16:29 -05:00
matthiasdanner 19a082b63c Sketcher: Fix constraint selection in groups (#22937)
* Fix constraint selection in groups

* include paddlestrokes refactoring and fix for more than 2 constraints in a group

---------

Co-authored-by: Matthias Danner <28687794+matthiasdanner@users.noreply.github.com>
Co-authored-by: PaddleStroke <pierrelouis.boyer@gmail.com>
2025-08-24 22:08:32 -05:00
Max Wilfinger 9fe682e2cf Gui: Change default WB list in preferences 2025-08-24 21:23:41 -05:00
WandererFan 24e3ab7d3e [TD]Fix no delete of cosmetic in clip group (#22838)
* [TD]Fix no delete of cosmetic in clip group

* [TD]lint clean up
2025-08-24 20:55:55 -05:00
Kacper Donat 947f1ca235 Part: Relax boolean requirements
The current solution checked shapes before allowing boolean operation to
happend. That meant that even small error with model in an unrelated
place could prevent the boolean from being computed, even if it would
compute fine and create valid shape. This commit changes that behaviour
so the tool at least tries to compute the results.
2025-08-24 20:54:21 -05:00
Max Wilfinger 9fc40b33de Fix source string mistakes reported on Crowdin (#23157)
* Fix source string mistakes reported on Crowdin

* Update src/Mod/Draft/Resources/ui/TaskPanel_CircularArray.ui

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Update src/Mod/Draft/Resources/ui/TaskPanel_CircularArray.ui

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Update src/Mod/Draft/draftfunctions/upgrade.py

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Update src/Mod/Draft/draftfunctions/upgrade.py

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Update src/Mod/Draft/draftguitools/gui_downgrade.py

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Update src/Mod/Draft/Resources/ui/TaskPanel_SetStyle.ui

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

---------

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>
2025-08-24 20:51:32 -05:00
Bas Ruigrok 21d0e8af5f Gui: Perspective camera set focal distance to rotation center depth to fix zooming at new rotation center 2025-08-24 20:49:42 -05:00
FEA-eng 60cb0d9d8b FEM: Update writeFenicsXDMF.py 2025-08-24 20:38:14 -05:00
Kacper Donat b57f4709ba PartDesign: Prevent Hole from claiming other features as children 2025-08-24 20:37:44 -05:00
Kacper Donat bf08a5e6b5 Part: Fix 2D Offset of Face
With TNP mitigation implementation handling of TopAbs_FACE was changed
in the method computing 2D offset of shape. It used to be very simple
iteration over face wires and it was instead changed to much more
complicated splitWires method. The intent of that change was to ensure
stability of the result, but it breaks existing models.

The problem is caused by OCC bug within offseting mechanism that is
dependent on wire order. Here the outer wire is moved to the end which
can cause issues.

Another issue is that for some reason, if circle is enclosed by other
shape the offset does not create proper 2D offset but moves the circle
in Z direction.
2025-08-24 20:36:47 -05:00
Kacper Donat fd502ce94f Gui: Try to load Theme Parameters from file
This creates logic that tries to load user parameters from file as the
priority and pushes back older mechanism to lower layer. Older way of
loading theme parameters should be preserved until we release first 1.1
RC.
2025-08-25 00:47:55 +02:00
Kacper Donat db3e96ebf0 Gui: Add YamlParameterSource for StyleParameters
This adds ability to read and write Style Parameters from YAML files.
This will allow to move certain tokens out of the User Parameter system
to ensure that they can be update without user needing to reapply the
theme.
2025-08-25 00:47:55 +02:00
Ladislav Michl 3354125a0f Base: Add moment to the internal unit schema 2025-08-25 00:05:06 +02:00
Ladislav Michl f934e86dc1 Base: Quantity: Assign work unit to all energy quantities
Fixes: 847e2f5c85 ("Base: Units: refactor")
2025-08-25 00:05:06 +02:00
Roy-043 34147736e2 BIM: change shortcut for Arch_Space 2025-08-24 22:30:14 +02:00
Roy-043 e786278f80 Add import init_draft_statusbar to 2 other functions 2025-08-24 11:49:05 -05:00
Roy-043 78f4d60dab Core: 2 Report View context menu items to Title Case 2025-08-24 13:06:39 +02:00
Roy-043 28cae33d0c Bring back placement argument type check 2025-08-24 13:06:32 +02:00
Roy-043 9807bd6e02 Do not import the Draft module 2025-08-24 13:04:39 +02:00
theo-vt c61ad05789 Techdraw: Undo/redo when dragging views and rework projection group drag (#22875)
* TechDraw: create a transaction when finished dragging a view

* TechDraw: drag projection group when dragging a subview in AutoDistribute is enabled

* TechDraw: avoid creating 'Drag View' transaction if the document is already in a transaction

* TechDraw: Apply suggestions from code review

---------

Co-authored-by: Benjamin Nauck <benjamin@nauck.se>
2025-08-24 08:36:41 +02:00
Kacper Donat cf951bae6b PartDesign: Unify deletion behavior
This unifies deletion behavior for all PartDesign features ensuring that
sketches that were used to create these features show after deletion and
that the tip is properly transfered.
2025-08-23 16:40:33 -05:00
Kacper Donat be3b9edd33 PartDesign: Do not copy visuals from ShapeBinder 2025-08-23 16:38:53 -05:00
Kacper Donat cfa6ee8d2c PartDesign: Properly forward BaseFeature transform edit requests to Body 2025-08-23 16:37:53 -05:00
tarman3 261355b714 CAM: Remove tool body with Job onDelete (#22924) 2025-08-23 12:11:51 -05:00
tarman3 dfbf7fc637 CAM: Do not show models of the toolbits in Job dialog (#22893) 2025-08-23 12:10:38 -05:00
David Kaufman 0c26ac9dba [CAM] Roadmap epic to improve core dressups (#23259)
* [CAM] proposal for an epic to improve core dressups

* Add 'array dressup' to out of scope section
2025-08-23 11:45:36 -05:00
luzpaz eb55e07b75 FEM: fix source comment typos
Found via codespell
2025-08-23 16:47:53 +02:00
Roy-043 5a854ed3d3 Draft: more logical placement for 3 point arcs
The placement of 3 point arcs very often was unexpected and typically did not match the placement of circles created on the same working plane.

This PR updates the code to use the placement of the working plane to adjust the placement of the created arc.

Additonally:
* Avoided code duplication by just passing the edge from make_arc_3points to make_circle.
* Removed inconsistent map_mode argument from make_arc_3points and the cryptic code related to it. The handling of the support property is something that has to be reviewed for all Draft commands at some point though.
2025-08-23 12:34:06 +02:00
FEA-eng dc489914d2 PartDesign: Fix small typo in multiple solids error (#23299)
* PartDesign: Update FeatureChamfer.cpp

* Update src/Mod/PartDesign/App/FeatureChamfer.cpp

---------

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-08-22 20:47:04 +00:00
FEA-eng b7c233b94e PartDesign: Update error message about multiple solids (#23286) 2025-08-22 18:29:50 +00:00
David Kaufman 26a7067e44 [CAM] Add roadmap epic for fixing user pain points (#23253)
* Add epic for fixing user pain points

I didn't add any detail page for this, because the pain points are already described in this document. I just think there should be an epic for this, since we are prioritizing changes that fit within an epic

* Fix typo
2025-08-22 17:47:02 +00:00
sliptonic f51b7742d3 CAM: Roadmap epic for circular hole improvements (#23001)
* epic for circular hole improvements

* feedback from PR

---------

Co-authored-by: Brad Collette <bradcollette@pop-os.localdomain>
2025-08-22 11:05:08 -05:00
Ryan Kembrey 0e85372e4a TechDraw: Fix frames resizing on select/hover 2025-08-22 16:36:31 +02:00
wmayer a6cf8ba983 Tests: Add unit tests for FileInfo 2025-08-22 15:20:25 +02:00
wmayer 12acd1da6c Base: Modernize FileInfo 2025-08-22 15:20:25 +02:00
tetektoza 67d001585c Start: Add caching for performance for thumbnails on start page (#23186)
* Start: Add caching for performance for thumbnails on start page

So currently we can have a problem where we are trying to load whole
image as a thumbnail, which can result in over 256MB~ of internal buffer
memory. Also, even if we load smaller size - every now and then start
page gets refreshed, so to check if any file got modified and refresh it
in recent files. This is okay, but with large files it loads them over
and over, resulting in start page lagging.

Solution for that is first - load image thumbnails as scaled, small
images instead of full image.

Second - for performance, use caching by using `path:modtime:size` key.
If the item fits this key, it means it didn't change, so just proceed
further and get this item from the cache. If the key is different, it
means it has been changed on the disk, so reload it.

* Start: Deactivate Start page if it loses focus to stop receiving events

As the title says. This prevents Start page from processing unnecessary
events (mostly paint ones that were causing extreme lag previously) if
it is not opened.

* Start: Preserve aspect ratio of the image for the thumbnail

* Start: use brace initialization when returning QString

* [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-08-21 22:06:07 -05:00
Roy-043 4680127a84 Update DlgSettingsGeneral.ui 2025-08-21 20:47:55 +02:00
dependabot[bot] c266bb10ae Bump github/issue-metrics from 3.22.3 to 3.23.0
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.22.3 to 3.23.0.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/9f2ad7e5b0353ace5de24bc74187ed0ad21473d7...63da87a2ab16c720cf9199a73c11f56a42f39cd4)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.23.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-21 15:01:58 +02:00
Johannes Thyssen Tishman 9831b60b9c Split Material Exceptions.h into source and header 2025-08-21 12:20:14 +02:00
Benjamin Nauck 5a0c03c891 Part: Fix WireJoiner error handling (#23241)
* Part: Fix WireJoiner error handling

* Part: Rename assertCheck to ENSURE
2025-08-20 22:26:56 +02:00
tetektoza 9d54896953 Part: Assign proper row and column to compound body property in prefs
As the title says, really small fix to the overlapping preferences for
Part/Part Design preferences.
2025-08-20 21:22:33 +02:00
Benjamin Nauck c93c7ed360 Merge pull request #23246 from Roy-043/Draft-Make-Draft_Label-tooltip-consistent
Draft: Make Draft_Label tooltip consistent
2025-08-20 16:41:34 +02:00
Benjamin Nauck 1876e68bcb Merge pull request #23240 from wwmayer/issue_23222
Sheet: Verify that UnitExpression is valid
2025-08-20 16:40:39 +02:00
PaddleStroke fc463ee5d7 Sketcher: Revert DPI adjustment error #22941 (#23237)
* Revert #22941

* [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-08-20 15:25:32 +02:00
Roy-043 29d98b0af5 Update gui_labels.py 2025-08-20 15:20:06 +02:00
marioalexis f176172faa PartDesign: Remove use of user parameters from Body constructor 2025-08-20 15:08:47 +02:00
wmayer f5cfd3d64c Sheet: Verify that UnitExpression is valid
The crash happens because the UnitExpression is null and thus segfaults when trying to access the unit and scalar value.
This fixes https://github.com/FreeCAD/FreeCAD/issues/23222
2025-08-20 10:15:08 +02:00
tetektoza 564e79b890 Gui: Don't use this pointer after valueChanged in EditableDatumLabel
Simple fix for such a simple error I didn't see. Basically,
`valueChanged` signal can result in EditableDatumLabel being deleted
(for example, when we are on the last OVP and all of the OVPs have been
accepted). This could result in crashes as reported in previous issues,
because just after emitting this signal we were trying to use `this` pointer,
which wasn't available anymore as we deleted EditableDatumLabel obj that
was attached to it, so in essence we were dereferencing some random
address.

Fix for that is simple - move the check for `hasFinishedEditing` flag to
check locked appearance in `validateAndFinish` lambda, as it already
does validation and this way we will avoid referencing internals (which
could be deallocated) after emitting this signal.
2025-08-19 19:33:20 -05:00
Chris Hennes 5e4fe3a3c3 Merge pull request #23164 from ickby/FEM_post_fixes_4
Fem: Fix for 3 issues
2025-08-19 19:00:55 -05:00
dependabot[bot] 2151a39c48 Bump actions/dependency-review-action from 4.7.1 to 4.7.2
Bumps [actions/dependency-review-action](https://github.com/actions/dependency-review-action) from 4.7.1 to 4.7.2.
- [Release notes](https://github.com/actions/dependency-review-action/releases)
- [Commits](https://github.com/actions/dependency-review-action/compare/da24556b548a50705dd671f47852072ea4c105d9...bc41886e18ea39df68b1b1245f4184881938e050)

---
updated-dependencies:
- dependency-name: actions/dependency-review-action
  dependency-version: 4.7.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-19 17:01:48 -05:00
marioalexis d5b1d994a2 Fem: Fix module import in solver CalculiX object 2025-08-19 16:33:43 -05:00
dependabot[bot] 89dc1e360c Bump github/issue-metrics from 3.22.1 to 3.22.3
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.22.1 to 3.22.3.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/2fd323a2f81a70e719d1035f7b7c7535c5bc53ea...9f2ad7e5b0353ace5de24bc74187ed0ad21473d7)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.22.3
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-19 15:30:44 -05:00
pre-commit-ci[bot] 40ada2daf5 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-08-19 15:48:09 +00:00
Stefan Tröger 7cd161f066 FEM: Update color bar when switching postprocessing frames. Fixes #22284 2025-08-19 17:44:21 +02:00
Stefan Tröger c9ca852ad0 FEM: Keep result pipeline and only reload data. Fixes #20542 2025-08-19 17:44:21 +02:00
Stefan Tröger b20fe6039e FEM: Update color bar of children when switching postprocessing frames 2025-08-19 17:43:52 +02:00
Valentin Rusu 1c67ab7be2 Fix segfault where DatumLine does not have a refSubSHape 2025-08-19 11:54:32 +02:00
FEA-eng 91712dc810 FEM: Update commands.py 2025-08-19 08:05:02 +02:00
luzpaz afb943df30 TechDraw: Fix tooltip in Gui/CommandAnnotate.cpp
Typo fix
2025-08-19 07:35:23 +02:00
Roy-043 3fb61d0c90 Update CommandBody.cpp 2025-08-19 07:29:06 +02:00
Chris Hennes bafd9f75b5 Addon Manager: Sync with upstream 2025-08-18 2025-08-18 19:31:10 +02:00
Kacper Donat 9e047821bd Part: Fix wrong capitalization of Display options property group 2025-08-18 18:18:15 +02:00
drwho495 75d3d72e47 Toponaming: Update element references of PropertyLinks everytime the program needs to access the values (#22785) 2025-08-18 11:11:49 -05:00
dependabot[bot] eab4d2229a Bump prefix-dev/setup-pixi from 0.8.14 to 0.9.0
Bumps [prefix-dev/setup-pixi](https://github.com/prefix-dev/setup-pixi) from 0.8.14 to 0.9.0.
- [Release notes](https://github.com/prefix-dev/setup-pixi/releases)
- [Commits](https://github.com/prefix-dev/setup-pixi/compare/8ca4608ef7f4daeb54f5205b20d0b7cb42f11143...fef5c9568ca6c4ff7707bf840ab0692ba3f08293)

---
updated-dependencies:
- dependency-name: prefix-dev/setup-pixi
  dependency-version: 0.9.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-18 11:11:05 -05:00
PaddleStroke 569deff94d Sketcher: Coinmanager: remove dpi (#22941)
* Sketcher: Coinmanager: remove dpi

* [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-08-18 11:06:37 -05:00
Chris Hennes 3e1cc8302a Update translations 2025-08-18 17:55:24 +02:00
Kacper Donat da5d6092e0 Merge pull request #22945 from ryankembrey/cosmetic-circles
TechDraw: Clarify and group cosmetic circle commands
2025-08-18 17:51:06 +02:00
Roy-043 8721756f57 Draft: fix handling of MouseDelay (improved) (#23011)
* Update DraftGui.py

* Update gui_points.py
2025-08-18 17:47:44 +02:00
theo-vt a94dc1463d TechDraw: add transactions to multiple commands (#22795)
* TechDraw: add transactions to multiple commands

* Feed each 'Create Dimension' option to the translation macro

* Call fixSceneDependencies when re-adding dimensions so that it shows up at the right place
2025-08-18 11:46:15 -04:00
Chris Hennes d8168d33f3 App: Remove use of dangerous localtime() function 2025-08-18 17:44:34 +02:00
Chris Hennes abdd975089 CI: Try to gain more disk space for the CodeQL run 2025-08-18 17:42:52 +02:00
theo-vt 10ae4de2f2 TechDraw: Fix balloon annotation unlinked after undo-redo (#22805)
* TechDraw: remove then add balloon annotation when changing the SourceView

* Use fixSceneDependencies
2025-08-18 10:37:02 -05:00
WandererFan c15cfd6615 [Meas]Fix visibility at load (#23145)
* [Meas]Fix visibility at load

* [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-08-18 10:36:05 -05:00
Stefan Tröger 27c7eca010 FEM: Fix post processing branch working with data extraction. Fixes #23030 2025-08-18 10:35:42 -05:00
FEA-eng b110102ca5 FEM: Amplitude support for rigid body constraint (#22898)
* FEM: Update FemConstraintRigidBody.cpp

* FEM: Update FemConstraintRigidBody.h

* FEM: Update write_constraint_rigidbody_step.py

* FEM: Update write_amplitude.py
2025-08-18 10:35:23 -05:00
marioalexis f8367d263e Fem: Add option to create conformal mesh from Netgen 2025-08-18 10:34:48 -05:00
marioalexis dc967cdb1c Fem: Create CalculiX output from .dat file - fixes #22983 2025-08-18 10:34:32 -05:00
marioalexis 576fed8362 Fem: Set Elmer equation priority based on the order of definition - fixes #21351 2025-08-18 10:34:13 -05:00
FEA-eng 052ff9237b FEM: Add support for CalculiX membrane elements (#22912)
* FEM: Update solver.py

* FEM: Update write_femelement_geometry.py

* FEM: Update write_mesh.py

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

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

* FEM: Update solver_calculix.py

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-18 10:33:49 -05:00
Roy-043 7f8e34938a Mesh: Revert Triangle menu text to Add Triangle (#23168) 2025-08-18 08:18:23 +02:00
drwho495 68077de39b Part: Fix toponaming issues. (#23151)
* fix split apart and splice

* fix hasher gen issue in extrusion

* fix broken gen in fillet/chamfer

* error when elements go missing in fillet/chamfer

* fix hashing in some elements

* fix compiler errors

* fix sweep

* remove hasher from mirror

* remove old import

* add clarifying comment

* Linter cleanup

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-08-18 01:35:46 +00:00
Max Wilfinger 84afc15c91 PartDesign: Enable compounds for PD bodies 2025-08-18 01:09:07 +02:00
captain0xff ed770bf849 Sketcher: fix cropping of some icons on hidpi screens 2025-08-18 01:02:13 +02:00
Benjamin Nauck 51f4ad7432 PartDesign: Use sketch as neutral plane for Draft (continuation of 20135) (#21901)
* Enabled Draft to accept sketch as neutral plane

* Resolving the last review

* Fix: tested the Feature with test file

* Fix: error with sketch pointer

* PartDesign: Simplify selection implementation

---------

Co-authored-by: Ziad <ziad.ashraf.cs@gmail.com>
2025-08-17 14:55:53 -05:00
Dmitry Moskowski 37c6e93e8a OpenSCAD: make openscadexecutable path resolution more consistent 2025-08-17 14:51:45 -05:00
luzpaz a55366e86e GUI: start cleaning up Parameter Editor
Begins to address a few issues brought up in #17351
2025-08-17 19:25:48 +02:00
Roy-043 2d12915a1c OpenSCAD: tweak tooltips (#23159)
* Update OpenSCADCommands.py
2025-08-17 19:24:36 +02:00
Stefan Tröger 70685aaa5d FEM: Purge tool deletes all result objects. Fixes #23028
- Correctly deletes children of pipeline without error on delete
- Ensures visualizations are also deleted as they are result objects too
- Ensures purge tool uses a transaction, like all tools should
2025-08-17 18:29:31 +02:00
Chris Hennes 1a4ff21bdd Addon Manager: Fix macro icon encoding bug 2025-08-15 22:35:00 +02:00
Kacper Donat 0c23e15cc4 Part: Prevent crash on cross-section of invalid object 2025-08-15 15:31:02 -05:00
dependabot[bot] cb3973e773 Bump korthout/backport-action from 3.2.1 to 3.3.0
Bumps [korthout/backport-action](https://github.com/korthout/backport-action) from 3.2.1 to 3.3.0.
- [Release notes](https://github.com/korthout/backport-action/releases)
- [Commits](https://github.com/korthout/backport-action/compare/0193454f0c5947491d348f33a275c119f30eb736...ca4972adce8039ff995e618f5fc02d1b7961f27a)

---
updated-dependencies:
- dependency-name: korthout/backport-action
  dependency-version: 3.3.0
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-15 13:30:51 -05:00
theo-vt af83b6883e PartDesign: Hole: fallback to getProfileNormal when a non-cylindrical surface is used 2025-08-15 10:09:23 -05:00
dependabot[bot] a0705f1d85 Bump github/issue-metrics from 3.22.0 to 3.22.1
Bumps [github/issue-metrics](https://github.com/github/issue-metrics) from 3.22.0 to 3.22.1.
- [Release notes](https://github.com/github/issue-metrics/releases)
- [Commits](https://github.com/github/issue-metrics/compare/f5c0d3ba93f0f6c6465665ac6ed1737dc74cea78...2fd323a2f81a70e719d1035f7b7c7535c5bc53ea)

---
updated-dependencies:
- dependency-name: github/issue-metrics
  dependency-version: 3.22.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-15 09:49:23 -05:00
Matthias Danner a7b501c95c remove edit value option from non dimensional constraints 2025-08-15 13:51:14 +02:00
theo-vt cf162dee3e PartDesign: Hole use the default PartDesign context menu items 2025-08-15 12:21:54 +02:00
Chris Hennes fec7d6f7cb Addon Manager: Sync with upstream
Fixes CMake problem with last sync
2025-08-14 19:55:04 +02:00
wmayer ac84cff53b Points: Replace defines with constexpr 2025-08-14 16:28:16 +02:00
wmayer 403bb40cad Points: Optimize translation of imported points 2025-08-14 16:28:16 +02:00
wmayer d1ab887475 Points: Add method PointKernel::moveGeometry
This allows to more efficiently transform a point cloud if only a translation but no rotation is needed
2025-08-14 16:28:16 +02:00
wmayer 72877a354e Gui: Add helper function Command::getActiveDocument() to get active App document 2025-08-14 16:28:16 +02:00
Johannes Thyssen Tishman 39f4bdf455 Revert "Materials: Check if m_uuid is empty before adding to recents"
This reverts commit dc03238349.
2025-08-14 16:02:02 +02:00
Vincenzo Calligaro b3e11ecd11 [Feature Request] [Draft] [UI/UX] Allow to turn dimension arrows on/off individually (#11941)
* Update additional files

* The LineColor and LineWidth properties are removed from Text objects.
* Arrow properties are added by the ViewProviderDraftAnnotation class only. This avoids code duplication.

* gui_annotationstyleeditor.py fix except

* view_draft_annotation.py fix except

---------

Co-authored-by: Roy-043 <info@b-k-g.nl>
Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>
2025-08-14 10:44:49 +02:00
Kacper Donat 8185d01771 Gui: Add GuiExport to SoToggleSwitch 2025-08-14 06:11:28 +02:00
Chris Hennes 9dc746389b Addon Manager: Sync with upstream
Major change is a switch to using Zip downloads as the primary
installation mechanism. Also fixes a number of small bugs.
2025-08-13 23:56:12 +02:00
wandererfan 81d22eb2c3 [TD]fix weld symbol not attached to leader 2025-08-13 22:46:20 +02:00
Kacper Donat 5fabb1372d Sketcher: Fix dimension extension overshoot length 2025-08-13 22:43:58 +02:00
Syres916 e86fbd0689 [CAM] Fix SetupSheet form table minimum height to be 300px 2025-08-13 12:34:25 +01:00
Benjamin Nauck 4195f7fee2 Merge pull request #23019 from kadet1090/transparent-previews-theming
Gui: Add theming abilities to Transparent Previews
2025-08-13 00:08:35 +02:00
Kacper Donat 6bbb4458c9 PartDesign: Use Style Parameters for theming previews 2025-08-12 22:04:23 +02:00
Kacper Donat 2f1d96bf44 Gui: Add ParameterDefinition to Style Parameters
This adds a way to define parameters within code, that allows developers
to easily encapsulate the parameters and their default values.
2025-08-12 22:04:23 +02:00
Kacper Donat 0cce9c1261 Gui: Make StyleParameterManager::resolve return optional result
This changes the resolve method of style parameter manager to return
optional intead of definitive result. In reality tokens may not be
defioned correctly and optionals provide a good way to nicely handle
defaults.
2025-08-12 22:04:23 +02:00
Kacper Donat 322ed2c7bc Gui: Rename StyleParameters::Length to StyleParameters::Numeric
This change gives a better name to the parameter type that is used to
store numeric values. Before it was called length, but it can store
other quantities as well so the name is no longer fitting.
2025-08-12 21:25:41 +02:00
Kacper Donat cf55183ece Gui: StyleParameters - use Base::Color instead of QColor
If possible we should prefer using our own classess instead of ones
coming from frameworks. This changes Style Parameters to use Base::Color
class instead of QColor. Calculations are still done using QColor but
the data is always exposed as Base::Color.
2025-08-12 21:25:41 +02:00
Kacper Donat 3a209a7e90 Base: Allow constexpr Color
This changes Base::Color class so it can be used as constexpr, useful
for defining various defaults.
2025-08-12 21:25:41 +02:00
luzpaz ce9da36314 Fix various typos 2025-08-12 12:18:23 -05:00
Max Wilfinger 6d078d3836 Change links to weekly releases 2025-08-12 11:39:42 -05:00
marioalexis f7132d7d9b Fem: Fix VTK check version 2025-08-12 11:36:29 -05:00
Kacper Donat bdba939f9f PartDesign: Implement preview for Draft 2025-08-12 11:34:26 -05:00
Benjamin Nauck 667990ec7b Start: Fix bug causing <none> to show in wb selector 2025-08-12 11:09:00 -05:00
Chris Hennes 91b3581a78 Merge pull request #22788 from pieterhijma/fix-func-expr-simplify
Core: Fix expression function simplify
2025-08-12 11:07:44 -05:00
pre-commit-ci[bot] fc3ae475e6 [pre-commit.ci] pre-commit autoupdate
updates:
- [github.com/pre-commit/pre-commit-hooks: cef0300fd0fc4d2a87a85fa2093c6b283ea36f4b → 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c](https://github.com/pre-commit/pre-commit-hooks/compare/cef0300fd0fc4d2a87a85fa2093c6b283ea36f4b...3e8a8703264a2f4a69428a0aa4dcb512790b2c8c)
2025-08-11 20:00:21 -05:00
theo-vt 44a8ec2b65 Core: Add setting to hide the TaskWatcher (#22857)
* Core: Add setting to hide the TaskWatcher

* Move setting to Display/UI

* Clarify option description

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

* Use sentence case for section title

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

---------

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-08-11 21:38:58 +02:00
PaddleStroke 78b4e4211c Sketcher: Move root point to a SoSkipBoundingGroup (#22874) 2025-08-11 14:09:15 -03:00
Kacper Donat 5361532de7 Gui: Restore proper object names for panels 2025-08-11 18:40:25 +02:00
Chris Hennes 6616f24049 Merge pull request #22985 from pieterhijma/fix-rename-prop-with-expr
Core: Fix renaming a property with an expression
2025-08-11 11:13:54 -05:00
wandererfan ba4475bf9c [TD]fix editable fields click handles
- click handles were displayed when view frames were displayed,
  and when printing or exporting.
- now, click indication is only shown on mouse over.
2025-08-11 11:05:47 -05:00
Ryan K 4d6f0927fe TechDraw: Rework view frames (#22869)
Co-authored-by: Ryan Kembrey <ryan.kembrey@student.uts>
2025-08-11 11:04:58 -05:00
tarman3 ec8d05b163 CAM: Fix seach tool controller in Operations group (#22728) 2025-08-11 11:04:06 -05:00
Chris Hennes bd681f70fb Merge pull request #22466 from WandererFan/ComplexSection3
TechDraw: ComplexSection fixes
2025-08-11 11:01:47 -05:00
drwho495 9f18f9a86d Toponaming: Fix bad element map in Part Design Bodies (#22767) 2025-08-11 10:41:39 -05:00
PaddleStroke 53f1f112e0 Core: Fit all : Do not process SoSkipBoundingGroup 2025-08-11 10:38:26 -05:00
wandererfan 3a7298f95a [TD]Ensure changed expression value is processed 2025-08-11 10:35:12 -05:00
sliptonic c4c97b217d CAM: Fix bug with loop completion (#22877)
* fixes #22876

* [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-08-11 10:32:52 -05:00
Andrés Barreiro 584022fb7d Add deduction guide for Base::Overloads 2025-08-11 11:53:23 +02:00
Kacper Donat 31a24e7226 Merge pull request #22751 from PaddleStroke/sk-messages-refactor
Sketcher: Refactor TaskSketcherMessages
2025-08-11 11:13:18 +02:00
theo-vt 79738eec38 Measure: give a hint to ::getShape so that compound shapes may be resolved 2025-08-11 00:24:56 +02:00
Roy-043 c1d25b0920 Draft: toolbar names to title case
This was  missed in #22331.
2025-08-10 21:27:38 +02:00
FC-FBXL5 1885cce10e Update TaskSectionView.ui
Tooltip related to label "Section Plane Location" deserves a better description. 
Also See Crowdin: https://crowdin.com/editor/freecad/all/en-de?view=comfortable&filter=basic&value=0&search_scope=translations&search_strict=0&search_full_match=0&case_sensitive=0#q=Abstand%20vom

This tool seems to work with one section plane (section line) only, which other object's distance/position could be addressed here?
2025-08-10 17:35:44 +02:00
paddle 35f151d99e Sketcher: Refactor TaskSketcherMessages to move most of the logic into Core to be reused by Assembly 2025-08-10 15:17:35 +02:00
paddle ccb28af4a1 Sketcher: Rename "Solver messages" to "Sketch edit". Add setting button to the solver message box. In which there're grid, snap and ordering widgets. 2025-08-10 15:15:53 +02:00
Roy-043 ee1a49b1c6 Draft: update WP Proxy string for consistency (#23012)
* Update gui_planeproxy.py
2025-08-10 13:01:27 +00:00
Pieter Hijma 5a842e93f5 Gui: Add support for renaming properties 2025-08-10 11:37:11 +02:00
marioalexis fbc4f450be Fem: Fix VTK submodule import 2025-08-09 14:03:39 -05:00
Matthias Danner 2477b9a976 Fix crash on set constraints to virtual space
Reverting fix for show only filtered constraints
2025-08-09 13:59:17 -05:00
sliptonic 80cad2a44e Creating a roadmap for CAM development (#22591)
* draft roadmap

* Update README.md

fix links

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* current state

* update

* Update Tool Management.md

drag knife

* Create ADR-003.md

* Update ADR-003.md

* Update ADR-003.md

* Update ADR-003.md

* Update Generators.md

* functionality

* adr-003

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

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

* improve circular holes features

* Update ADR-003.md

Ambiguous term "Safe height" (safe for what?) shall be renamed OpRapidsHeight to indicate its function.

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

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

* relative gcode

* adding tables

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

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

* Survey.
Assessment of functionality

* Update Operation Configuration.md

* Update Operation Configuration.md

* Update Job Management.md

array

* Update README.md

short term priorities

* Update README.md

* Update README.md

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

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

* Update README.md

* Update README.md

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

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

* Update README.md

* Update README.md

* Update README.md

* renaming

* Update ADR-004.md

* Update README.md

* Update README.md

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

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

* Update README.md

* Update README.md

ADR update

* Roadmap cleanup.

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

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

* @connor's changes

* Update README.md

* Update Operation Configuration.md

Drilling ops:
Don't ignore user selection on entry. Use auto if no selection.

* Update Operation Configuration.md

Fill in some place holders
Flesh out current state.

* safe operating planes
AR-003

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

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

* Update ADR-003.md

language normalized

* Update ADR-003.md

* Remove current state

* Update ADR-002.md

* Update Operation Configuration.md

Retain starting position from hole to hole when set. 
ie retain starting angle on XY plane as determined by first hole. 
Minimising rapids between holes gains nothing over all and leads to rather arbitrary starting on subsequent holes.

* Update Operation Configuration.md

Pocket clearance. Fix and restore Spiral

* recomputes

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

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

* Update ADR-005.md

* Update ADR-005.md

* Update Output Generation.md

* Update Simulation and Verification.md

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

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

* Update ADR-003.md

title change and cleanup

* Update README.md

ADR3 title change

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

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

* Update Operation Configuration.md

* initiatives

* handling user selection draft ADR

* Update Output Generation.md

* update

* epics

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

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

* changes

* cleanup

* meta data on path commands

---------

Co-authored-by: Ian Abreu <z0r0@shurikenlabs.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: J-Dunn <dunn@piments.com>
Co-authored-by: Brad Collette <bradcollette@pop-os.localdomain>
2025-08-09 11:17:34 -05:00
dependabot[bot] 023ab981a8 Bump actions/cache from 4.2.3 to 4.2.4
Bumps [actions/cache](https://github.com/actions/cache) from 4.2.3 to 4.2.4.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/5a3ec84eff668545956fd18022155c47e93e2684...0400d5f644dc74513175e3cd8d07132dd4860809)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-version: 4.2.4
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-09 08:54:35 -05:00
Sunless 93d90ef96e Improve wording and grammar in README introduction
Reworded the sentence about sketching geometry-constrained 2D shapes to improve clarity and grammar. This change makes the introduction easier to read and more precise for new users.
2025-08-09 08:53:12 -05:00
wmayer 39ca75bac2 Py3.13: Update PyCXX to version 7.1.11 2025-08-09 00:36:56 +02:00
Pieter Hijma 3446cb8660 Core: Add logic for updating exprs on prop rename 2025-08-08 17:31:11 +02:00
marioalexis 0cdf0af0c6 App: Fix ExtensionPython macro 2025-08-08 17:11:51 +02:00
Pieter Hijma 0acc2d1ed5 Core: Add test for a prop rename with expression 2025-08-08 17:09:49 +02:00
Syres916 32ddaff649 [Gui] add carriage return to warnings 2025-08-08 06:51:18 -05:00
Bas Ruigrok 7dbb67cbe8 Sketcher: Add missing finishEditing() for points 2025-08-08 06:49:14 -05:00
dependabot[bot] 20873e433b Bump actions/download-artifact from 4.3.0 to 5.0.0
Bumps [actions/download-artifact](https://github.com/actions/download-artifact) from 4.3.0 to 5.0.0.
- [Release notes](https://github.com/actions/download-artifact/releases)
- [Commits](https://github.com/actions/download-artifact/compare/d3f86a106a0bac45b974a628896c90dbdf5c8093...634f93cb2916e3fdff6788551b99b062d0335ce0)

---
updated-dependencies:
- dependency-name: actions/download-artifact
  dependency-version: 5.0.0
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-08-08 06:44:11 -05:00
Max Wilfinger 70f4221993 Fix missed strings for UI consistency
Fix ellipsis rendering
2025-08-08 06:37:59 -05:00
FEA-eng f371622d6f FEM: Update FemConstraintDisplacement.cpp 2025-08-07 18:36:53 -05:00
Max Wilfinger 75ed661b14 Update sub_weeklyBuild.yml
Run weekly builds each Wednesday
2025-08-07 18:36:20 -05:00
Jacob Oursland d42e532397 CI: add debug entitlement to macOS weekly builds. 2025-08-07 18:34:29 -05:00
Jacob Oursland a3a72c556c CI: ccache configuration tweaks. 2025-08-07 18:34:08 -05:00
Jacob Oursland b71214d1e3 CMake: add FREECAD_3DCONNEXION_SUPPORT to CMakePresets.json 2025-08-07 18:33:30 -05:00
Chris Hennes 9a7c084720 Merge pull request #17249 from kadet1090/part-design-transparent-previews
PartDesign: Introduce transparent previews
2025-08-07 15:33:58 -05:00
Krzysztof ec2bf69135 Core: Fix 'Expression' and 'Vector' editor outhanging the screen (#22426)
* Core: Fix Expression dialog outhanging main window

Expression dialog is now fully shown inside main window, even if opened from model panel positioned on right side. If Model panel is outside main window, dialog is opened over this panel.

* Core: Fix Vectors dialog outhanging main window

Vectors dialog is now fully shown inside main window, even if opened from model panel positioned on right side. If Model panel is outside main window, dialog is opened over this panel.

* Core: Simplify 'adjustDialogPosition()'

Change suggested and authored by @hyarion
2025-08-07 19:22:28 +02:00
Benjamin Nauck 78e5dc9e21 Gui: Fix null check issue in navlib 2025-08-07 16:51:23 +02:00
Max Wilfinger 321cc5ced5 Gui: Fix crash with navlib
Co-authored-by: @hyarion
2025-08-07 12:11:14 +02:00
Kacper Donat 07e98226fe Part: Cleanup setupCoinGeometry method 2025-08-07 00:37:47 +02:00
Alfredo Monclus d2986cd99a PartDesign: disable final model while selecting on dressups (fillet/chamfer)
Co-authored-by: Kacper Donat <kacper@kadet.net>
2025-08-07 00:37:47 +02:00
Alfredo Monclus a5c2ccaa87 Gui: refactor: change Preview button label to Confirm Selection
Transparent preview can be enabled so it wasn't representative
2025-08-07 00:37:47 +02:00
Kacper Donat 802af4c464 PartDesign: Add preview TaskBox to all feature task dialogs 2025-08-07 00:37:46 +02:00
Kacper Donat 6caceacb95 PartDesign: Add support for preview for transforms 2025-08-07 00:37:23 +02:00
Kacper Donat 7f87d87f61 PartDesign: Add transparent previews 2025-08-07 00:37:21 +02:00
Kacper Donat 38db306a84 PartDesign: Return to previous feature after edit 2025-08-07 00:36:23 +02:00
Max Wilfinger a9cd5a4982 Draft: Update UI strings for consistency (#22331)
* Draft: Update UI strings for consistency

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Ryan K <114723629+ryankembrey@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Ryan K <114723629+ryankembrey@users.noreply.github.com>

* Apply suggestions from code review

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Apply suggestions from code review

* Apply suggestions from code review

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>

* Apply suggestions from code review

---------

Co-authored-by: Ryan K <114723629+ryankembrey@users.noreply.github.com>
Co-authored-by: Roy-043 <70520633+Roy-043@users.noreply.github.com>
2025-08-06 23:02:16 +02:00
Ladislav Michl f1032b47d4 Gui: Fix about image path
Merge of a4d4a8e7d6 accidentally didn't drop change to DlgAbout path.
Nothing sets AboutImageDev congfig key, so partially revert said commit.

Fixes: a4d4a8e7d6 ("Gui: Add about image for dev version")
2025-08-06 08:22:45 -05:00
Ryan Kembrey ca3710060b TechDraw: Fix default toolbar cosmetic circle name 2025-08-06 20:28:17 +10:00
Ryan Kembrey e2298448ab TechDraw: Fix cosmetic circle menu 2025-08-06 20:05:38 +10:00
Ryan Kembrey 2d695b249c TechDraw: Clarify and group cosmetic circle commands 2025-08-06 19:49:54 +10:00
Carlos Nihelton d5bcf68e43 Start: Walks the parent tree to close the tab (#22572)
* Start: Walks the parent tree to close the tab

We're currently closing the entire app, it seems a mistake.
Instead, we should look up the widget tree to find the tab
(QMdiSubWindow) and close it instead.

The way I put if we don't find it we don't do anything.
Might be unexpected but at least harmless.

A side effect of this fix is a required drop of constness of
multiple helper methods that call postStart().

* Start: Minor code cleanup and PCH fix

---------

Co-authored-by: Carlos Nihelton <cn@ubuntu.com>
Co-authored-by: Chris Hennes <chennes@gmail.com>
2025-08-06 00:38:30 +00:00
qewer33 a4d4a8e7d6 Gui: Add about image for dev version
Co-authored-by: ein-shved <yury.shvedov@kaspersky.com>
Co-authored-by: Ladislav Michl <ladis@triops.cz>
Co-authored-by: qewer33 <qewer33@proton.me>
Co-authored-by: 3x380V <i58604845+3x380V@users.noreply.github.com>
2025-08-05 17:33:05 -05:00
Matthias Danner 377ccbdf54 Fix drawing of angle constraints beyond the centerpoint and for negative angles 2025-08-05 23:41:30 +02:00
Roy-043 8786cac938 Draft: project point in split operation and copy original wire (#22452)
* Roy 043 patch 1 (#6)

* Update split.py

* Update gui_split.py

* Add recompute to update wire in split test

* Avoid circular import: init_draft_statusbar -> params -> init_draft_statusbar

* Remove accidentally added "ui/preferences-webgl.ui"
2025-08-05 14:41:03 -05:00
Ryan Kembrey 18702dfd6a PartDesign: Fix regression in mirror 2025-08-05 16:29:12 +02:00
Frank David Martínez M 1b3851c502 [Core] Add Boolean Functions to expressions (AND, OR, NOT) (#22506)
* [Core] Add Boolean Functions to expressions (AND, OR, BOOL, NOT)

* [Core] Add `if` function to expressions to overcome ternary operator limitations

* [Core] Update expressions grammar to recognize relational operations as arguments

* [Core] The `if` function has been removed as no consensus was reached regarding its convenience or necessity. Its inclusion was considered potentially confusing or redundant.

* [Core] Make boolean cast based on Confusion threshold.
2025-08-05 03:50:13 +00:00
Kacper Donat b311137b74 Merge pull request #22916 from kadet1090/all-string-changes
All: Update UI strings for consistency
2025-08-05 01:20:35 +02:00
Benjamin Nauck a10a52e36b Merge pull request #21723 from B0cho/CORE_Skip_recompute_command
CORE: 'Skip recompute' command added
2025-08-04 22:48:18 +02:00
Ryan Kembrey 75b2ef67fc TechDraw: Update UI strings for consistency
Closes: #22143
2025-08-04 20:26:04 +02:00
Max Wilfinger bee89d0447 PartDesign: Update UI strings for consistency and correct for new fuctions and typos
Closes: #22128
2025-08-04 20:15:04 +02:00
Max Wilfinger b267203e67 Material: Update UI strings for consistency
Closes: #22130
2025-08-04 20:14:59 +02:00
Max Wilfinger 1f35b9d7fe Part: Update UI strings for consistency
Closes: #22133
2025-08-04 20:14:51 +02:00
Max Wilfinger ecf02b7878 Gui: Update UI strings for consistency
Closes: #22135
2025-08-04 20:14:45 +02:00
Ryan Kembrey 2c7ee9b8ed Assembly: Update UI strings for consistency
Closes: #22194
2025-08-04 20:14:38 +02:00
Ryan Kembrey 627a89d8db BIM: Update UI string for consistency
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

Closes: #22328
2025-08-04 20:14:15 +02:00
Ryan Kembrey 80c1d7a630 CAM: Update UI strings for consistency
Closes: #22350
2025-08-04 20:13:52 +02:00
Ryan Kembrey 3d163c9990 Help: Update UI strings for consistency
Closes: #22368
2025-08-04 20:13:40 +02:00
Ryan Kembrey d7bc171a38 Test: Update UI strings for consistency
Closes: #22369
2025-08-04 20:13:34 +02:00
Ryan Kembrey adff20f7dc Measure: Update UI strings for consistency
Closes: #22370
2025-08-04 20:13:26 +02:00
Ryan Kembrey 33ccea6835 MeshPart: Update UI strings for consistency
Closes: #22372
2025-08-04 20:13:18 +02:00
Max Wilfinger 764b9cca0e Sketcher: Fix UI strings
Closes: #22770
2025-08-04 20:13:04 +02:00
Max Wilfinger b7a65220a3 DAGView: Update UI strings for consistency
Closes: #22771
2025-08-04 20:12:54 +02:00
Chris Hennes 7d6c9c0ee6 Contributing: Clarify use of Draft and On hold 2025-08-04 19:39:07 +02:00
Benjamin Nauck 37a653ef33 Gui: Remove toggleskiprecomputes todos 2025-08-04 19:17:15 +02:00
luzpaz f73e863a02 Fix various typos (#22836)
* Fix various typos
Found via codespell

* [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-08-04 11:14:15 -05:00
Luz Paz f791502dac CI: add more codespellignore words 2025-08-04 11:13:11 -05:00
Roy-043 8f42b8e3dd Draft: fix size of file button in Hatch task panel
Fixes #22790.

To keep the file button at the correct size a vertical bottom spacer is required.
2025-08-04 11:05:48 -05:00
Chris Hennes eea9f81a90 Base: Clean up ParameterManager::LoadDocument 2025-08-04 18:04:59 +02:00
Roy-043 dac94dfee7 Draft: fix display of cross-shaped cursor
If snapping was off, and after clicking the first point of a new line (for example), the cursor would be a default arrow instead of the intended cross-shaped cursor.

Note that the arrow cursor is still displayed for a fraction of a second after this fix.

May also fix #16559.
2025-08-04 11:02:38 -05:00
Roy-043 98756ea010 BIM: ArchPanel: FontFile parameter name has changed
The parameter name has been changed from FontFile to ShapeStringFontFile. See #21054.
2025-08-04 10:58:52 -05:00
J-Dunn 966cb36e9e CAM: revert grbl_post regression (#22569)
* CAM: revert grbl_post regression

I recently noticed a bug in grbl_proc post processor where it was not correctly setting OLD_Z  if current machine_z is below G81 retract plane in R parmeter. 

On digging into my original commit is looks like the two lines which did this have been commented out. 
I can never find the Blame feature when I need so if someone else can find the culprit feel free. 

https://github.com/FreeCAD/FreeCAD/pull/9153/commits/2bd617a2b35540a6d41cb5519328fa1280116153

This PR simply reinstates the missing lines and adds a snippet of NIST as a comment block  to prevent any over-zealous editing in the future. 

This regression means that drilling cycles start with z=clearance height instead of z=safe height leading to much costly air cutting.
This similarly messes up the  the retract plane for G98 leading to excessive machine time wasting and incorrect application of G98 returns. 

Indeed this regression was noticed because some were claiming the Safe height was redundant in drilling ops since it was never used. 

There is much discussion about all this at the moment which is being disrupted by people assuming the current broken paths are what FreeCAD is intended to do. 

Let's fix this ASAP, so we can stop this confusion and get discussions back to reality.

* [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-08-04 10:57:03 -05:00
Florian Foinant-Willig 39c902c616 Try to auto-fix any invalid generated helix 2025-08-04 17:52:06 +02:00
Chris Hennes 26c6aa934d Tests: Add tests for timestamp-based backups 2025-08-04 17:51:15 +02:00
wandererfan 8173b11104 [TD]more stringent test for bsplines as circles 2025-08-04 10:49:27 -05:00
Ian Abreu 4aa0aff389 Core: Generation of FEM interface bindings (#22581)
* Initial commit of FEM bindings.

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

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

* running black.

* Fixing imports.

* Update src/Mod/Fem/Gui/ViewProviderFemMeshPy.pyi

Co-authored-by: João Matos <joao@tritao.eu>

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: João Matos <joao@tritao.eu>
2025-08-04 10:48:00 -05:00
FEA-eng 5eb4dffe50 Part: Remove redundant Part Import and Export tools from the menu (#22116)
* Part: Update Workbench.cpp
2025-08-04 10:43:18 -05:00
sliptonic bb0965941d Merge pull request #22228 from knipknap/fix-custom-attribute-edit
CAM: Various bugfixes for CAM tool management
2025-08-04 10:39:25 -05:00
Ian Abreu 3ecb701959 Core: Generation of python bindings for Techdraw (#22565)
* first working interfaces..

* adding the rest.

* updated all pyi files.

* running black for formatting.

* removing unused imports

* removing empty comments

* fixing typing declarations.

* removing inline comments.

* fixing pyObjectBase in CosmeticEdgePy

* removing erroneous tags.

* running black.

* fixing CenterLinePy

* fixing import issues.

* Fixing tuple.

* Enabling CosmeticEdge compilation.

* fixing comments, removing unused imports.

* fixing ordering
2025-08-04 10:36:32 -05:00
Ian Abreu 0e4dbbe8d2 Core: Generation of python bindings for Assembly (#22574)
* adding XML, CmakeLists, and interfaces.

* removing Dict, List from typing imports.

* Normalizing imports.
2025-08-04 10:36:22 -05:00
Benjamin Nauck 837ccef6f4 Merge pull request #22165 from 3x380V/fix_19183
PD: Fix loft between curved faces
2025-08-04 17:34:52 +02:00
Pieter Hijma 1b9da7e423 Core: Fix func expression simplify 2025-08-04 16:51:11 +02:00
Pieter Hijma c86907d243 Core: Add tests for expression simplify and eval 2025-08-04 16:51:11 +02:00
Jackson Oursland 54a5192182 CI: ccache fix (#22899) 2025-08-03 23:55:53 +00:00
Kacper Donat 481b5d644b Sketcher: Make SoDatumLabel constraints more interactable (#21920)
* Sketcher: Make distance constraint more interactable

As the title says, this patch aligns selectability to what we actually
draw, so from now on extension lines and arrowheads will be also
selectable.

* Sketcher: Make radius/diameter constraint more interactable

* Sketcher: Make angle constraint more interactable

* Sketcher: Make symmetric constraint more interactable

* Sketcher: Make ArcLength constraint more interactable
2025-08-03 22:04:59 +02:00
Syres916 123b3b066b Tests: Add test for two face loft 2025-08-03 19:14:09 +02:00
Ladislav Michl 9a5d934eab PD: Fix loft between curved faces
Fixes issue 19183 also reported in the forum:
https://forum.freecad.org/viewtopic.php?p=806495
https://forum.freecad.org/viewtopic.php?t=88234

The actual reason for the failure is that the new code uses
FaceMakerBullseye method which expects coplanar wires.
The code was using FaceMakerCheese previously which changed
in LinkStage with their commit 93ce3edfe7ff
("PD: use FaceMakerBullseye for feature Loft")
and was imported here with TNP mitigations.

As changing it back would cause different regressions, lets
try different facemakers until one succeeds.

Fixes: fa8f29aed4 ("Toponaming/Part: Fix all getBaseTopoShape calls...")
Co-authored-by: Benjamin Nauck <benjamin@nauck.se>
Co-authored-by: Werner Mayer <wmayer@freecad.org>
2025-08-03 19:14:09 +02:00
theo-vt 1299b3eb9f Core: Set ::Remove flag before calling breakLinks (#22759)
* Ensure the ::Remove flag of DocumentObject is set to true before calls to breakLinks

* TechDraw: remove then add balloon annotation when changing the SourceView

* Revert "TechDraw: remove then add balloon annotation when changing the SourceView"

This reverts commit 483b4fe4a0715ff63c2669af33fc3beb60a93f54.
2025-08-03 15:45:04 +02:00
tetektoza 44b3686459 Sketcher: Make ArcLength constraint more interactable 2025-08-02 19:54:00 +02:00
tetektoza ba0e9ac5a8 Sketcher: Make symmetric constraint more interactable 2025-08-02 19:54:00 +02:00
tetektoza 36e6808d34 Sketcher: Make angle constraint more interactable 2025-08-02 19:54:00 +02:00
tetektoza c7e96a2168 Sketcher: Make radius/diameter constraint more interactable 2025-08-02 19:53:48 +02:00
tetektoza e2b8ebab41 Sketcher: Make distance constraint more interactable
As the title says, this patch aligns selectability to what we actually
draw, so from now on extension lines and arrowheads will be also
selectable.
2025-08-02 19:52:33 +02:00
tetektoza afa61ab0d1 Part: Enable SwitchToTask as a preference (#22136)
* Part: Enable SwitchToTask as a preference

As the title says. No clue why this variable was not available in
preferences, but giving it to users allow them to stop Part Design
workbench to switch to Tasks tab by default, everytime they switch
workbench, which users claim to be annoying.

So this patch adds this preference under Part/Part Design.

* Update src/Mod/Part/Gui/DlgSettingsGeneral.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

* Update src/Mod/Part/Gui/DlgSettingsGeneral.ui

Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>

---------

Co-authored-by: Kacper Donat <kadet1090@gmail.com>
Co-authored-by: Max Wilfinger <6246609+maxwxyz@users.noreply.github.com>
2025-08-02 16:22:47 +00:00
xtemp09 5aae85f48d [Spreadsheet] Add icons to the context menu (#22773)
* [Spreadsheet] Add icons to the context menu

This commit adds the following icons:
- edit-cut
- edit-copy
- edit-paste
- edit-delete
- merge-cells
- split-cell
- view-refresh

* [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-08-02 14:57:53 +02:00
MisterMaker 7ded6608c6 Stylesheet: Update QComboBox and QListView styles for varset dialog (#22861)
* Update QComboBox and QListView styles

Fixed issue with Varset dialog which was using the same object as the workbench combobox. So I directed the general version to the workbench combobox and changed the general setting to more normal version.

* Update selected item background in QListView

Changed the background color for selected QListView items from @AccentBackgroundHoverColor to @GeneralBackgroundHoverColor for improved visual consistency.

* Unify selection and hover styles in views

Updated QListView, QTableView, QTreeView, and QColumnView item selection to use @AccentBackgroundColor for consistency. Changed hover states for these views to use @AccentHoverColor, improving visual coherence across the UI.

* shouldn't be in there yellow
2025-08-02 14:56:31 +02:00
Chris Hennes 113a06a2e1 Merge pull request #22881 from oursland/ci-ccache-update
CI: ccache update
2025-08-01 22:02:00 -05:00
Jacob Oursland 52453154e6 CI: formatting GitHub CI workflows. 2025-08-01 14:49:15 -07:00
Jacob Oursland 66881ad3e4 CI: address actions/cache warning and always upload cache. 2025-08-01 14:49:14 -07:00
FEA-eng a83f34e31c FEM: Add support for amplitudes with CalculiX (#22851) 2025-08-01 15:22:01 -05:00
FEA-eng fb4c739619 FEM: Add support for references for CalculiX's initial temperature (#22864)
* FEM: Update checksanalysis.py

* FEM: Update FemConstraintInitialTemperature.cpp

* FEM: Update meshsetsgetter.py

* FEM: Update writer.py

* FEM: Update write_constraint_initialtemperature.py

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

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

* FEM: Update thermomech_bimetal.inp

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-08-01 14:03:37 -05:00
Pieter Hijma d4303f19ca Core: Support enum editor in VarSet dialog 2025-07-31 13:43:31 +02:00
PaddleStroke bc207c0a07 Assembly: Fix https://github.com/FreeCAD/FreeCAD/issues/22815 2025-07-29 13:49:41 -05:00
Johannes Wüller 3321b13218 Sketcher: Fix external geometry out-of-bounds vector access (#22181)
* Sketcher: Fix external geometry out-of-bounds vector access

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
Co-authored-by: Ajinkya Dahale <AjinkyaDahale@users.noreply.github.com>
Co-authored-by: Benjamin Bræstrup Sayoc <benj5378@outlook.com>
2025-07-29 18:36:17 +00:00
dependabot[bot] d200ae6f7a Bump prefix-dev/setup-pixi from 0.8.12 to 0.8.14
Bumps [prefix-dev/setup-pixi](https://github.com/prefix-dev/setup-pixi) from 0.8.12 to 0.8.14.
- [Release notes](https://github.com/prefix-dev/setup-pixi/releases)
- [Commits](https://github.com/prefix-dev/setup-pixi/compare/307e5e5842748e3752d5178fbd158e0a6c1b55ff...8ca4608ef7f4daeb54f5205b20d0b7cb42f11143)

---
updated-dependencies:
- dependency-name: prefix-dev/setup-pixi
  dependency-version: 0.8.14
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-07-29 13:04:45 -05:00
Chris Hennes 68ae4986c3 Merge pull request #22817 from oursland/macos-weekly-numpy
Fix numpy on macOS Weekly Builds
2025-07-29 08:43:35 -05:00
Jacob Oursland 10080f0bd3 CI: use OpenBLAS on macOS weekly builds. 2025-07-29 01:43:12 -07:00
Jacob Oursland 9e8371f91c CI: recursively fixup RPATHs on macOS. 2025-07-29 01:42:26 -07:00
PaddleStroke 83a7d3c456 AssemblyGui: CmakeLists typo 2025-07-28 22:21:45 -05:00
Chris Hennes 8dc6397fc4 App: Fix XML namespace issue in Branding 2025-07-28 12:17:34 -05:00
PaddleStroke ae5564d50c Assembly: Replace "Activated" property by the core "Suppressed" mecha… (#22409)
* Assembly: Replace "Activated" property by the core "Suppressed" mechanism.

* Fix inaccuracy

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

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

* move the change to migrationScript5 function

* Update JointObject.py

* [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-07-28 18:20:01 +02:00
wandererfan 40db448db2 [TD]light changes for style and clarity 2025-07-28 18:15:18 +02:00
wandererfan 76517f8492 [TD]fix BrokenView does not handle shells
- or faces, wires, edges that are not part of another shape
2025-07-28 18:14:21 +02:00
wandererfan c47cd6bece [TD]prevent detail object deletion during task dialog 2025-07-28 18:11:12 +02:00
sliptonic 1d64a3a983 Merge pull request #22392 from knipknap/fix-test-uses-user-data
CAM: fix: CAM tests use files from user asset dir
2025-07-28 11:08:50 -05:00
Roy-043 80713fd47c Draft: show dotted lineTracker in Trimex extrude mode (#22509)
* Draft: show dotted lineTracker in Trimex extrude mode

* Fix copy-paste error
2025-07-28 18:02:01 +02:00
Roy-043 a8a44aab0a Draft: fix handling of MouseDelay
The MouseDelay sets a point value to None. In some cases this point was then still used resulting in attribute errors.

See:
https://github.com/FreeCAD/FreeCAD/issues/19531#issuecomment-2651341711
2025-07-28 17:52:02 +02:00
Furgo 6e68d94c78 Update default sun path diagram scale 2025-07-28 17:49:56 +02:00
Yorik van Havre 7766b215d4 Merge pull request #22251 from furgo16/dxf-new-import-ui-and-more
Redesign DXF import UI, add Part primitives and Draft object import modes
2025-07-28 17:49:25 +02:00
sliptonic 43fe9b3d1a Merge pull request #22578 from z0r0/CAM-bindings
Core: Generation of python bindings for CAM
2025-07-28 10:34:34 -05:00
Ian 'z0r0' Abreu ab225f5672 fixing unnecessary list import 2025-07-28 08:59:52 -05:00
Roy-043 e64b654699 BIM: fix profile rotation of elbow pipe connector
Fixes #22761
2025-07-28 12:39:06 +02:00
Lee Matos fcd1b923b3 Gui: Fix #12199 missing font family Courier on MacOS 2025-07-28 10:17:18 +02:00
theo-vt 2da7c9ff17 Sketcher: Change the style of the curves in creation to match the construction/defining flag (#22407)
* Sketcher: Change EditCurvesDrawStyle to match either CurvesDrawStyle or CurvesConstructionDrawStyle in editDraw()

* Match color as well

* Match pattern scale as well

* Use enum instead of boolean flag

* Update src/Mod/Sketcher/Gui/Utils.h

---------

Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-07-28 02:33:25 +00:00
theo-vt 7481a5d8dd PartDesign: Hole: get direction from cylindrical surface rather than normal (#22393)
* PartDesign: Hole: Find direction of cylindrical face in Hole::execute instead of FeatureSketchBased::getProfileNormal

* PartDesign: Minor cleanups in guessNormalDirection

---------

Co-authored-by: Kacper Donat <kadet1090@gmail.com>
2025-07-28 02:06:50 +00:00
Furgo f2e9a7f62e Gui: add 'Select group contents' context menu item (#22082)
* Gui: add 'Select group contents' context menu item

* Gui: remove dependency from Draft icon
2025-07-28 00:44:12 +02:00
Kacper Donat 5c2b5507d6 Merge pull request #22712 from PaddleStroke/asm_watcher
Assembly: TaskWatcher
2025-07-28 00:13:28 +02:00
paddle 3aeb6e9e92 Assembly: Task Watcher. 2025-07-27 21:23:12 +02:00
paddle 2843bbefc7 Assembly: Add 'Activate assembly' command. 2025-07-27 21:17:28 +02:00
paddle 013bbf1937 Core: TaskView: add updateWatcher when an object is set in edit. And add a timer when active document changes. 2025-07-27 21:17:28 +02:00
alafr f89a763a5b Draft: Enable Draft Edit for Draft Labels (#13445)
* Draft: implement DraftLabelGuiTools

TODO:
1- support for custom StraightDirection with any number of points
2- fix EditNode positions when the label is inside a Part

* Draft: enable Draft Edit for Draft Label object

TODO:
Make the edition possible also with double-click in the tree view

* Draft: Trigger Edit on double click on Label in the tree view

Fix part 1/2 of comment https://github.com/FreeCAD/FreeCAD/pull/13445#issuecomment-2079672899

* Draft: Edit Label: enable to move one or move both nodes

The following apply to both edit points of the straight segment:
- If a point is moved exactly on the direction of the straight segment (set the WP to the Label object and use Shift key while moving the node), then it's length is changed without moving the other point.
- If a point is moved in any other direction, both points are moved and the straight segment's length is unchanged

Part 2/2 of https://github.com/FreeCAD/FreeCAD/pull/13445#issuecomment-2079672899
2025-07-27 17:26:12 +02:00
PaddleStroke 91641c4fb6 TaskView: Add 'Permanent task box' framework. (#22750)
* TaskView: Add 'Permanent task box' framework.

* Update TaskView.h
2025-07-26 22:46:49 +02:00
PaddleStroke a8b655d602 Assembly: Use icon overlay for unconnected joints instead of annoying warning. (#22662)
* Core: FeaturePython : Add getOverlayIcons to python interface

* Assembly: unconnected joints icon overlay Fix #22643

* Update src/Mod/Assembly/Gui/ViewProviderAssembly.cpp

Co-authored-by: Kacper Donat <kadet1090@gmail.com>

* Update AssemblyObject.cpp

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

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

* Update ViewProviderFeaturePython.h

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

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

* Update ViewProviderFeaturePython.h

* Update JointObject.py

* Update ViewProviderFeaturePython.h

* Update ViewProviderFeaturePython.cpp

* Update Application.cpp

* Update ViewProviderFeaturePython.cpp

* Update ViewProviderFeaturePython.h

* Update ViewProviderAssembly.cpp

---------

Co-authored-by: Kacper Donat <kadet1090@gmail.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2025-07-26 22:35:24 +02:00
Kacper Donat 4823ccb6a1 Merge pull request #22736 from chennes/sketcherCodeQLCleanup
Sketcher CodeQL cleanup
2025-07-26 11:21:53 +02:00
Chris Hennes 3aa31f11f6 Part: Add error handling to TopoShape::isLinearEdge 2025-07-26 11:17:33 +02:00
PaddleStroke 4f4fe019b8 Assembly: utils: tiny fix 2025-07-26 11:16:28 +02:00
Chris Hennes 29da89febd Sketcher: Clean up some old commented out code 2025-07-25 19:12:30 -05:00
Chris Hennes 3679a2adca Sketcher: Extract "processFace" function
Tool-aided refactor, no functional changes.
2025-07-25 10:08:29 -05:00
Chris Hennes 403056fa20 Sketcher: Resolve "Declaration hides variable"
Reduce some code duplication via helper method.
2025-07-25 09:48:34 -05:00
Chris Hennes ab91372e28 Sketcher: Resolve "Type confusion" CodeQL critical warning 2025-07-25 09:21:43 -05:00
Ian 'z0r0' Abreu efc4defebf fixing imports 2025-07-20 09:04:27 -04:00
Ian 'z0r0' Abreu 536a7452c7 Removal of comments. 2025-07-20 08:51:45 -04:00
Ian 'z0r0' Abreu 6358874a58 merging. 2025-07-18 19:44:47 -04:00
Ian 'z0r0' Abreu 325fa7f5e6 removing List, Dict typing refs. 2025-07-18 19:44:09 -04:00
Ian Abreu b721257670 Merge branch 'main' into CAM-bindings 2025-07-18 18:28:49 -04:00
Ian 'z0r0' Abreu e4e8625a4b initial commit 2025-07-18 18:27:08 -04:00
B0cho 62e5d0df23 CORE: Tree context menu upgraded with 'Std_ToggleSkipRecompute' 2025-07-15 22:12:22 +02:00
B0cho b38394da68 CORE: 'Std_ToggleSkipRecompute' implemented, no icon 2025-07-15 22:12:22 +02:00
jffmichi e12b4fd27c CAM: select rows instead of cells in drilling panel 2025-07-15 21:09:16 +02:00
Furgo 485b8016f4 Remove debug print statement 2025-07-14 10:18:04 +02:00
Furgo 2061df9fa9 Import: DXF, fix CodeQL errors 2025-07-14 10:18:04 +02:00
Furgo 8bda4ddfa5 Import: DXF, make straight polylines Draft-editable 2025-07-14 10:18:04 +02:00
Furgo 9ce3a35bc8 Import: DXF, correctly transfer Draft.Line points to make them editable 2025-07-14 10:18:04 +02:00
Furgo 8054042a9a Import: DXF, fix typo in individual shapes import mode 2025-07-14 10:18:04 +02:00
Furgo f8b3e91e23 Import: DXF, add suggestions and improve UI copy. 2025-07-14 10:18:04 +02:00
Furgo 808526e8b8 Import: DXF, deduplicate Part primitives creation
Create helpers that can be reused when importing entities as top-level
geometry and as part of blocks
2025-07-14 10:18:04 +02:00
Furgo cb64caf283 Import: DXF, first working version of dimensions import 2025-07-14 10:18:04 +02:00
Furgo 5243501638 Import: DXF, make ellipses parametric 2025-07-14 10:18:04 +02:00
Furgo fa4d8247bc Import: DXF, first working version of Draft objects import 2025-07-14 10:18:04 +02:00
Furgo a7f8fd29bb Import: DXF, first working version for import as Part primitives 2025-07-14 10:18:04 +02:00
Furgo 071bdcc579 Import: DXF, add dedicated import dialog 2025-07-14 10:18:04 +02:00
Furgo c7aada6abd Gui: add WaitCursor API 2025-07-14 10:18:04 +02:00
Furgo 1b2246c5db Import: DXF importer, refactor preferences UI 2025-07-14 10:18:04 +02:00
wandererfan 24625d3198 [TD]ComplexSection fixes
- fix handling of non-ortho profiles
- fix profile not on same plane as section normal
- fix direction of arrows on section line
2025-07-13 12:08:15 -04:00
wandererfan df390b0c88 [TD]property type changes 2025-07-13 12:00:10 -04:00
Samuel Abels 0ad45ac99a CAM: silence unnecessary log for preferences change when no change was actually made 2025-07-09 10:19:22 +02:00
Samuel Abels 3332c49271 CAM: fix: CAM tests use files from user asset dir 2025-07-08 20:39:52 +02:00
Dan Taylor a7f1b96c45 [CAM] Correctly process Adaptive extensions as faces instead of shells (fix 22177) 2025-07-04 14:51:55 -05:00
Samuel b16fb74889 Merge branch 'main' into fix-custom-attribute-edit 2025-07-04 20:32:37 +02:00
Samuel Abels 173ee65b8b CAM: Fix: rename vbit and threadmill back to v-bit and thread-mill to avoid backward compatibility issues 2025-06-30 22:59:14 +02:00
Samuel Abels 16d90cfbb9 CAM: Fix: shape parameters coming from the attributes section in the fctb file were not normalized 2025-06-30 21:48:21 +02:00
Samuel Abels b5e4b400ad CAM: Fix: Tool editor ignored shape attributes if they were not in the Shape group. Now it reads all except Base 2025-06-30 20:27:54 +02:00
Samuel Abels 7f7f5ba2bb CAM: make ToolBitShape more robust against invalidly typed parameters in toolbit files (e.g. Flutes with string value) 2025-06-30 20:27:26 +02:00
Samuel Abels 3829e1db76 CAM: Fix: Remove invalid normalization of shape name 2025-06-30 20:26:51 +02:00
Samuel Abels 2d1746d04f CAM: gracefully handle tool numbers that are strings in the tool library JSON 2025-06-29 21:39:04 +02:00
Samuel Abels da8eec5744 CAM: Fix: ToolBitShapeCustom properties not editable if they had no type specified in the schema 2025-06-29 21:34:06 +02:00
Samuel Abels 788560d709 CAM: fix toolbit editor shape resolution for high DPI displays 2025-06-29 13:15:47 +02:00
Samuel Abels 3521ae91cc CAM: reduce default size of toolbit editor dialog 2025-06-29 13:02:09 +02:00
Samuel Abels 0a7cf449bc CAM: Fix: Tools without icon now display the thumbnail from the FCStd file 2025-06-29 12:57:32 +02:00
Samuel Abels 2f051136fe CAM: Fix: Chipload is not written to fctb file 2025-06-29 11:52:22 +02:00
Samuel Abels 33935cf73e CAM: store tool quantities in user units, not metric 2025-06-29 11:52:07 +02:00
Samuel Abels 11d5707141 CAM: Fix: custom shape attributes not showing in toolbit editor 2025-06-29 01:30:06 +02:00
papaathome fc92b2ba90 Update PathUtils.py
Removed typo ('.') at line 838
2025-06-04 17:28:46 +02:00
papaathome 047e39389f CAM: Update PathUtils.py
Proposed fix for `CAM: 3Dsurface, rotational path, difference between X/A and Y/B paths #21556`
2025-06-04 09:50:02 +02:00
Stephen Green c8c63a4099 Fix for https://github.com/FreeCAD/FreeCAD/issues/21533 2025-05-25 22:12:13 -04:00
6930 changed files with 1443305 additions and 1816871 deletions
+76 -49
View File
@@ -1,22 +1,22 @@
# Generated from CLion C/C++ Code Style settings
# --- Based on Qt Coding Style ---
BasedOnStyle: LLVM
# --- Bracket and Indentation Behavior ---
IndentWidth: 4
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
TabWidth: 4
ColumnLimit: 100
UseTab: Never
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: None
AlignOperands: DontAlign
AllowAllArgumentsOnNextLine: false
AlignAfterOpenBracket: BlockIndent
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortBlocksOnASingleLine: Empty
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: None
AllowShortIfStatementsOnASingleLine: Never
AllowShortLambdasOnASingleLine: Empty
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterReturnType: None
AlwaysBreakTemplateDeclarations: Yes
BinPackArguments: false
BinPackParameters: false
BinPackArguments: false
BreakBeforeBraces: Custom
BreakTemplateDeclarations: Yes
BreakBeforeBinaryOperators: All
BraceWrapping:
AfterCaseLabel: false
AfterClass: true
@@ -31,41 +31,68 @@ BraceWrapping:
IndentBraces: false
SplitEmptyFunction: false
SplitEmptyRecord: true
BreakBeforeBinaryOperators: NonAssignment
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: BeforeComma
BreakInheritanceList: BeforeColon
ColumnLimit: 100
CompactNamespaces: false
ContinuationIndentWidth: 4
IndentCaseLabels: true
IndentPPDirectives: None
IndentWidth: 4
InsertBraces: true
KeepEmptyLinesAtTheStartOfBlocks: true
MaxEmptyLinesToKeep: 2
NamespaceIndentation: None
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PackConstructorInitializers: Never
PointerAlignment: Left
ReflowComments: true
SortIncludes: Never
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeCpp11BracedList: true
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: false
# --- Special: Lambdas and Short Things ---
AllowShortFunctionsOnASingleLine: None
AllowShortBlocksOnASingleLine: Never
AllowShortEnumsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLambdasOnASingleLine: Inline
AllowAllArgumentsOnNextLine: false
# --- Spaces ---
SpaceBeforeParens: ControlStatements
SpaceAfterCStyleCast: false
Cpp11BracedListStyle: true
SpaceBeforeCpp11BracedList: true
SpaceBeforeRangeBasedForLoopColon: true
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 2
SpacesInAngles: false
SpacesInCStyleCastParentheses: false
SpacesInContainerLiterals: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
TabWidth: 4
UseTab: Never
SpaceAfterTemplateKeyword: false
SpaceBeforeInheritanceColon: false
# --- Alignment & Formatting Tweaks ---
AlignConsecutiveAssignments:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignConsecutiveDeclarations:
Enabled: false
AcrossEmptyLines: false
AcrossComments: false
AlignCompound: false
AlignFunctionPointers: false
PadOperators: true
AlignOperands: DontAlign
BreakConstructorInitializers: BeforeComma
PointerAlignment: Left
ReferenceAlignment: Left
# --- Comment Style ---
CommentPragmas: '^ IWYU pragma:'
# --- Namespace handling ---
NamespaceIndentation: None
# --- Others ---
SortIncludes: Never
IncludeBlocks: Preserve
MaxEmptyLinesToKeep: 2
IndentCaseLabels: true
InsertBraces: true
AlignEscapedNewlines: DontAlign
PPIndentWidth: 1
IndentPPDirectives: AfterHash
ReflowComments: true
# --- Penalties (Fine-tuning when to break lines) ---
PenaltyBreakAssignment: 80
PenaltyBreakBeforeFirstCallParameter: 1
PenaltyBreakComment: 60
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyBreakOpenParenthesis: 5
PenaltyExcessCharacter: 10
PenaltyReturnTypeOnItsOwnLine: 600
+2 -4
View File
@@ -2,8 +2,8 @@
Checks: 'clang-diagnostic-*,clang-analyzer-*,boost-*,bugprone-*,
performance-*,readability-*,portability-*,modernize-*,cppcoreguidelines-*,google-explicit-constructor,
concurrency-*,-modernize-use-trailing-return-type, -modernize-use-nodiscard,-readability-identifier-length,
-readability-redundant-access-specifiers,-readability-qualified-auto,
-cppcoreguidelines-avoid-non-const-global-variables,-cppcoreguidelines-owning-memory,
-readability-redundant-access-specifiers,-readability-qualified-auto,-readability-implicit-bool-conversion,
-cppcoreguidelines-avoid-non-const-global-variables,-cppcoreguidelines-owning-memory,-cppcoreguidelines-avoid-do-while,
-readability-convert-member-functions-to-static,-bugprone-easily-swappable-parameters,
-cppcoreguidelines-pro-type-static-cast-downcast'
WarningsAsErrors: ''
@@ -203,8 +203,6 @@ CheckOptions:
value: '4294967295'
- key: bugprone-suspicious-missing-comma.RatioThreshold
value: '0.200000'
- key: readability-implicit-bool-conversion.AllowIntegerConditions
value: 'false'
- key: readability-identifier-length.IgnoredParameterNames
value: '^[n]$'
- key: readability-function-size.StatementThreshold
+3 -1
View File
@@ -102,4 +102,6 @@ c5c2ea3498f402c0c89916c46ddb071e22756622 # Assembly: Final application of pre-co
d472927bba7b2d8d151c99fb29cf1d8dd099ea7d # Correct PartDesign Helix feature negative angles (#11399)
b93c02e07da4990482b9d927506901e6f5d624e1 # Black updated to 24.3.0
cbea6b60942f8327e6105b12e8c1d5db4647984c # FEM: Apply pre-commit to FEM files
f9d66096878c7d89c273522b9ca57bdb14fee3bc # Rearranged CommandCreateGeo.cpp
f9d66096878c7d89c273522b9ca57bdb14fee3bc # Rearranged CommandCreateGeo.cpp
b23d5809414d63ea90bcc744212c126645051438 # BIM: add to pre-commit and apply Black formatting
50e4864efb06faf3e2126e8cb9ff9058a08a54b2 # Draft: add to pre-commit and apply Black formatting
-1
View File
@@ -1,7 +1,6 @@
# These are supported funding model platforms
github: FreeCAD
liberapay: FreeCAD
open_collective: freecad
patreon: # Replace with a single Patreon username
ko_fi: # Replace with a single Ko-fi username
+21
View File
@@ -1,4 +1,6 @@
aci
addmin
afile
ake
aline
alle
@@ -6,13 +8,16 @@ alledges
alocation
anid
anormal
anull
apoints
aply
appy
ascript
ba
beginn
bloaded
bottome
brushin
childrens
childs
connexion
@@ -29,10 +34,15 @@ finde
findn
fle
fo
fpt
freez
froms
graphin
hist
incrementin
indexin
indicies
indx
inout
invertin
isnt
@@ -40,10 +50,12 @@ ist
itsel
leadin
linez
localy
lod
mantatory
mata
methode
mke
modell
nd
nin
@@ -53,21 +65,30 @@ numer
oce
ontop
ot
pard
parm
parms
pointin
programm
propt
rady
recurrance
rin
rougly
sectionin
seh
ser
sergent
serie
shs
siz
som
strack
strin
substraction
sur
te
textin
thist
tread
ue
+1 -2
View File
@@ -6,8 +6,7 @@
"owner": "msvc-problem-matcher",
"pattern": [
{
"regexp":
"^(?:\\s+\\d+\\>)?([^\\s].*)\\((\\d+),?(\\d+)?(?:,\\d+,\\d+)?\\)\\s*:\\s+(error|warning|info)\\s+(\\w{1,2}\\d+)\\s*:\\s*(.*)$",
"regexp": "^(?:\\s+\\d+\\>)?([^\\s].*)\\((\\d+),?(\\d+)?(?:,\\d+,\\d+)?\\)\\s*:\\s+(error|warning|info)\\s+(\\w{1,2}\\d+)\\s*:\\s*(.*)$",
"file": 1,
"line": 2,
"column": 3,
+168
View File
@@ -0,0 +1,168 @@
#!/usr/bin/env python3
# SPDX-License-Identifier: LGPL-2.1-or-later
"""
run_gui_tests.py
List registered tests via `FreeCAD -t`, filter for GUI tests (names containing 'Gui'), and run each
GUI test module using the specified FreeCAD executable.
Usage:
run_gui_tests.py [FREECAD_EXEC]
If FREECAD_EXEC is omitted the script falls back to 'FreeCAD' on PATH.
If FREECAD_EXEC is a directory containing bin/FreeCAD, that binary is used.
If FREECAD_EXEC is an executable path, it is used directly.
This script returns 0 if all GUI modules run successfully. Otherwise it returns the last non-zero
exit code.
"""
from __future__ import annotations
import sys
import subprocess
import os
from pathlib import Path
def find_executable(arg: str | None) -> str:
"""Return the FreeCAD executable path to use.
If `arg` is None or empty, returns the plain name 'FreeCAD' which will be looked up on PATH. If
`arg` is a directory and contains `bin/FreeCAD` that binary will be returned. If `arg` is a file
path it is returned as-is. Otherwise the original argument is returned.
Common use cases: use the FreeCAD binary from a build directory or an installed FreeCAD prefix.
"""
if not arg:
return "FreeCAD"
p = Path(arg)
if p.is_dir():
candidate = p / "bin" / "FreeCAD"
if candidate.exists():
return str(candidate)
if p.is_file():
return str(p)
# fallback: return as-is (may be on PATH)
return arg
def validate_executable(path: str) -> tuple[bool, str]:
"""Return (ok, message). Checks if the executable exists or is likely on PATH.
This is best effort: if a bare name is given (e.g. 'FreeCAD') we can't stat it here, so we
accept it but warn. If the path points to a file, we check executability. Also warn if the name
looks like the CLI-only 'FreeCADCmd'.
"""
p = Path(path)
if p.is_file():
if not os.access(str(p), os.X_OK):
return False, f"File exists but is not executable: {path}"
if p.name.endswith("FreeCADCmd"):
return (
True,
(
"Warning: executable looks like 'FreeCADCmd' (CLI); GUI tests require the GUI "
"binary 'FreeCAD'."
),
)
return True, ""
# Bare name or non-existent path: accept but warn
if p.name.endswith("FreeCADCmd"):
return (
True,
(
"Warning: executable name looks like 'FreeCADCmd' (CLI); GUI tests require the GUI "
"binary 'FreeCAD'."
),
)
return True, ""
def run_and_capture(cmd: list[str]) -> tuple[int, str]:
"""Run `cmd` and return (returncode, combined stdout+stderr string).
If the executable is not found a return code of 127 is returned and a small error string is
provided as output to aid diagnosis.
"""
try:
proc = subprocess.run(
cmd, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, text=True, check=False
)
return proc.returncode, proc.stdout
except FileNotFoundError:
return 127, f"Executable not found: {cmd[0]}\n"
def parse_registered_tests(output: str) -> list[str]:
"""Parse output from `FreeCAD -t` and return a list of registered test unit names.
The function looks for the section starting with the literal 'Registered test units:' and
then collects non-empty, stripped lines from that point onwards as test names.
"""
lines = output.splitlines()
tests: list[str] = []
started = False
for ln in lines:
if not started:
if "Registered test units:" in ln:
started = True
continue
s = ln.strip()
if not s:
# allow blank lines but keep going
continue
tests.append(s)
return tests
def main(argv: list[str]) -> int:
"""Entry point: run GUI test modules registered in the FreeCAD executable.
Returns the last non-zero exit code from any GUI test module, or 0 on success.
"""
exec_arg = argv[1] if len(argv) > 1 else None
freecad_exec = find_executable(exec_arg)
print(f"Using FreeCAD executable: {freecad_exec}")
ok, msg = validate_executable(freecad_exec)
if msg:
print(msg, file=sys.stderr)
if not ok:
print(f"Aborting: invalid FreeCAD executable: {freecad_exec}", file=sys.stderr)
return 3
code, out = run_and_capture([freecad_exec, "-t"])
if code != 0:
print(
f"Warning: listing tests returned exit code {code}; attempting to parse output anyway",
file=sys.stderr,
)
tests = parse_registered_tests(out)
if not tests:
print("No registered tests found; exiting with success.")
return 0
gui_tests = [t for t in tests if "Gui" in t]
if not gui_tests:
print("No GUI tests found in registered tests; nothing to run.")
return 0
print("Found GUI test modules:")
for t in gui_tests:
print(" ", t)
last_rc = 0
for mod in gui_tests:
print(f"\nRunning GUI tests for module: {mod}")
rc, out = run_and_capture([freecad_exec, "-t", mod])
print(out)
if rc != 0:
print(f"Module {mod} exited with code {rc}", file=sys.stderr)
last_rc = rc
return last_rc
if __name__ == "__main__":
sys.exit(main(sys.argv))
+2 -2
View File
@@ -58,7 +58,7 @@ jobs:
logdir: /tmp/log/
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -108,7 +108,7 @@ jobs:
done
- name: Upload logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ github.job }}-Logs
path: |
@@ -21,13 +21,13 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: '🧹 Tag & close stale unconfirmed bugs'
id: stale_issues
uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0
uses: actions/stale@5f858e3efba33a5ca4407a664cc011ad407f2008 # v10.1.0
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: 60
@@ -41,7 +41,7 @@ jobs:
remove-stale-when-updated: true
ascending: true
stale-issue-message: |
Hi! This issue hasnt seen activity in a while. If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD-Bundle/releases/tag/weekly-builds) to see if the problem is resolved.
Hi! This issue hasnt seen activity in a while. If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD/releases/) to see if the problem is resolved.
If the issue persists, let us know by adding a comment with any updates or details. Otherwise, well close this issue automatically in 14 days to keep our backlog tidy. Feel free to comment anytime to keep it open. Closed issues can always be reopened.
Thanks for helping improve FreeCAD!
@@ -53,7 +53,7 @@ jobs:
- name: '🧹 Close stale requested feedback issues'
id: awaiting_issues
uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0
uses: actions/stale@5f858e3efba33a5ca4407a664cc011ad407f2008 # v10.1.0
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: 20
@@ -68,7 +68,7 @@ jobs:
ascending: true
stale-issue-message: |
Hi! This issue hasnt seen activity in a while despite the need for further feedback.
If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD-Bundle/releases/tag/weekly-builds) to see if the problem is resolved.
If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD/releases/) to see if the problem is resolved.
If the issue persists, let us know by adding a comment with any updates or details. Otherwise, well close this issue automatically in 14 days to keep our backlog tidy. Feel free to comment anytime to keep it open. Closed issues can always be reopened.
Thanks for helping improve FreeCAD!
@@ -80,7 +80,7 @@ jobs:
- name: '🧹 Tag & close inactive issues'
id: inactive_issues
uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0
uses: actions/stale@5f858e3efba33a5ca4407a664cc011ad407f2008 # v10.1.0
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: 190
@@ -95,7 +95,7 @@ jobs:
ascending: true
stale-issue-message: |
Hi! This issue hasnt seen activity in a while. We automatically check each issue after 190 days without activity to keep the backlog tidy.
If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD-Bundle/releases/tag/weekly-builds) to see if the issue is already resolved.
If its still relevant, please update to the latest FreeCAD weekly build [download here](https://github.com/FreeCAD/FreeCAD/releases/) to see if the issue is already resolved.
If the issue is still relevant, let us know by adding a comment.
Otherwise, well close this issue automatically in 60 days.
@@ -110,7 +110,7 @@ jobs:
- name: '🧹 Tag & close inactive PRs'
id: inactive_pr
uses: actions/stale@5bef64f19d7facfb25b37b414482c7164d639639 # v9.1.0
uses: actions/stale@5f858e3efba33a5ca4407a664cc011ad407f2008 # v10.1.0
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
days-before-issue-stale: -1
+2 -2
View File
@@ -28,10 +28,10 @@ jobs:
)
steps:
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Create backport pull requests
uses: korthout/backport-action@0193454f0c5947491d348f33a275c119f30eb736 # v3.2.1
uses: korthout/backport-action@d07416681cab29bf2661702f925f020aaa962997 # v3.4.1
with:
# Inputs documented here: https://github.com/korthout/backport-action?tab=readme-ov-file#inputs
github_token: ${{ github.token }}
+2 -2
View File
@@ -64,12 +64,12 @@ jobs:
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 2
submodules: recursive
+13 -10
View File
@@ -68,23 +68,26 @@ jobs:
# your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 2
submodules: recursive
# prevent running out of disk space on Ubuntu runners.
- name: Maximize build space
uses: AdityaGarg8/remove-unwanted-software@90e01b21170618765a73370fcc3abbd1684a7793 # v5
with:
verbose: 'true'
remove-android: 'true' # (frees ~9 GB)
remove-cached-tools: 'true' # (frees ~8.3 GB)
remove-android: 'true' # (frees ~9 GB)
remove-cached-tools: 'true' # (frees ~8.3 GB)
remove-haskell: 'true' # (frees ~5.2 GB)
remove-swapfile: 'true' # (frees ~4 GB)
remove-docker-images: 'true' # (frees ~3.2 GB)
- name: Checkout repository
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 2
submodules: recursive
# Install FreeCAD dependencies (cpp)
- name: Setup build environment
@@ -153,7 +156,7 @@ jobs:
sarif_file: sarif-results/cpp.sarif
- name: Upload loc as a Build Artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@v5
with:
name: sarif-results
path: sarif-results
+3 -3
View File
@@ -17,11 +17,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: 'Checkout Repository'
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: 'Dependency Review'
uses: actions/dependency-review-action@da24556b548a50705dd671f47852072ea4c105d9 # v4
uses: actions/dependency-review-action@56339e523c0409420f6c2c9a2f4292bbb3c07dd3 # v4
+30
View File
@@ -0,0 +1,30 @@
name: Fedora Daily Build
permissions:
contents: read
on:
schedule:
- cron: "00 00 * * *"
workflow_dispatch:
jobs:
trigger-copr-build:
env:
copr_token: ${{ secrets.COPR_TOKEN }}
runs-on: ubuntu-latest
container: quay.io/packit/packit
steps:
- name: setup copr token
run: |
mkdir -p ~/.config
echo "$copr_token" > ~/.config/copr
- name: checkout sources
uses: actions/checkout@v4
with:
submodules: recursive
fetch-depth: 500
fetch-tags: true
- name: Setup safe Git directory
run: git config --global --add safe.directory $GITHUB_WORKSPACE
- name: trigger copr build
run: |
packit build in-copr --project freecad
@@ -0,0 +1,67 @@
name: Fetch Crowdin Translations
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * 1"
jobs:
update-crowdin:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
with:
fetch-depth: 0
- name: Install Qt ≥ 6.8
uses: jurplel/install-qt-action@d325aaf2a8baeeda41ad0b5d39f84a6af9bcf005
with:
aqtversion: "==3.1.*"
version: "6.8.3"
host: "linux"
target: "desktop"
arch: "linux_gcc_64"
- name: Setup Python & dependencies
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c
with:
python-version: "3.13"
- name: Install Python packages
run: |
python3 -m pip install --upgrade pip
pip install pyside6
- name: Gather translations from crowdin
run: |
./updatecrowdin.py build
while ./updatecrowdin.py build-status | grep -q "status: inProgress"; do sleep 10; done
./updatecrowdin.py download
./updatecrowdin.py install
working-directory: ./src/Tools
env:
CROWDIN_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
CROWDIN_PROJECT_ID: freecad
- name: Commit changes
run: |
git config --global user.name "github-actions"
git config --global user.email "github-actions@github.com"
git add src
git commit -m "Update translations from Crowdin" || echo "No changes to commit"
- name: Push changes to a new branch
run: |
git branch update-crowdin-translations
git push origin update-crowdin-translations --force
- name: Create Pull Request
uses: peter-evans/create-pull-request@271a8d0340265f705b14b6d32b9829c1cb33d45e
with:
branch: update-crowdin-translations
title: "Update translations from Crowdin"
body: "Automatic Crowdin update."
labels: "translations, automated"
delete-branch: true
add-paths: |
src
+3 -3
View File
@@ -17,7 +17,7 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -35,13 +35,13 @@ jobs:
echo "last_month=$first_day..$last_day" >> "$GITHUB_ENV"
- name: Run issue-metrics tool
uses: github/issue-metrics@f5c0d3ba93f0f6c6465665ac6ed1737dc74cea78 # v3.22.0
uses: github/issue-metrics@637a24e71b78bc10881e61972b19ea9ff736e14a # v3.25.2
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SEARCH_QUERY: 'repo:FreeCAD/FreeCAD is:issue created:${{ env.last_month }}'
- name: Create issue
uses: peter-evans/create-issue-from-file@e8ef132d6df98ed982188e460ebb3b5d4ef3a9cd # v5.0.1
uses: peter-evans/create-issue-from-file@fca9117c27cdc29c6c4db3b86c48e4115a786710 # v6.0.0
with:
title: Monthly issue metrics report
token: ${{ secrets.GITHUB_TOKEN }}
+2 -2
View File
@@ -21,11 +21,11 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- uses: actions/labeler@8558fd74291d67161a8a78ce36a881fa63b766a9 # v5.0.0
- uses: actions/labeler@634933edcd8ababfe52f92936142cc22ac488b1b # v6.0.1
with:
repo-token: "${{ secrets.GITHUB_TOKEN }}"
configuration-path: ".github/labels.yml"
@@ -0,0 +1,42 @@
name: Push Crowdin Translations
on:
workflow_dispatch:
schedule:
- cron: "0 0 * * 1"
jobs:
update-crowdin:
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
with:
fetch-depth: 0
- name: Install Qt ≥ 6.8
uses: jurplel/install-qt-action@d325aaf2a8baeeda41ad0b5d39f84a6af9bcf005
with:
aqtversion: "==3.1.*"
version: "6.8.3"
host: "linux"
target: "desktop"
arch: "linux_gcc_64"
- name: Setup Python & dependencies
uses: actions/setup-python@e797f83bcb11b83ae66e0230d6156d7c80228e7c
with:
python-version: "3.13"
- name: Install Python packages
run: |
python3 -m pip install --upgrade pip
pip install pyside6
- name: Push translations to Crowdin
run: |
./updatecrowdin.py gather
./updatecrowdin.py upload
working-directory: ./src/Tools
env:
CROWDIN_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
CROWDIN_PROJECT_ID: freecad
+4 -4
View File
@@ -36,17 +36,17 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: "Checkout code"
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
persist-credentials: false
- name: "Run analysis"
uses: ossf/scorecard-action@05b42c624433fc40578a4040d5cf5e36ddca8cde # v2.4.2
uses: ossf/scorecard-action@4eaacf0543bb3f2c246792bd56e8cdeffafb205a # v2.4.3
with:
results_file: results.sarif
results_format: sarif
@@ -68,7 +68,7 @@ jobs:
# Upload the results as artifacts (optional). Commenting out will disable uploads of run results in SARIF
# format to the repository Actions tab.
- name: "Upload artifact"
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: SARIF file
path: results.sarif
+21 -13
View File
@@ -49,14 +49,18 @@ jobs:
runs-on: ${{ matrix.os }}
continue-on-error: ${{ inputs.allowedToFail }}
env:
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_CONFIGPATH: ${{ github.workspace }}/ccache/config
CCACHE_MAXSIZE: 1G
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 5
config: debug
builddir: ${{ github.workspace }}/build/debug/
CCACHE_CONFIGPATH: ${{ github.workspace }}/ccache/config
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_MAXSIZE: 1G
CCACHE_NODIRECT: true
CCACHE_NOHASHDIR: true
CCACHE_NOINODECACHE: true
CCACHE_SLOPPINESS: "include_file_ctime,include_file_mtime,pch_defines,time_macros"
builddir: ${{ github.workspace }}/build/release/
cacheKey: pixi-${{ matrix.os }}
config: release
logdir: ${{ github.workspace }}/logs/
reportdir: ${{ github.workspace }}/report/
reportfilename: ${{ inputs.artifactBasename }}-${{ matrix.os }}-report.md
@@ -71,7 +75,7 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -87,7 +91,7 @@ jobs:
fi
- name: Checkout
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
- name: Add GCC Problem Matcher
if: runner.os == 'Linux'
@@ -112,13 +116,15 @@ jobs:
mkdir -p ${{ env.reportdir }}
echo "reportFile=${{ env.reportfilename }}" >> $GITHUB_OUTPUT
- uses: prefix-dev/setup-pixi@307e5e5842748e3752d5178fbd158e0a6c1b55ff # v0.8.12
- uses: prefix-dev/setup-pixi@82d477f15f3a381dbcc8adc1206ce643fe110fb7 # v0.9.3
with:
pixi-version: v0.48.1
pixi-version: v0.59.0
cache: false
- name: Restore Compiler Cache
uses: actions/cache/restore@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
id: cache-restore
if: always()
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
path: ${{ env.CCACHE_DIR }}
key: FC-${{ env.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
@@ -141,6 +147,7 @@ jobs:
pixi run build-${{ env.config }}
- name: Print ccache statistics after Build
if: always()
run: |
pixi run ccache -s
@@ -200,15 +207,16 @@ jobs:
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: Save Compiler Cache
id: cache-save
if: always()
uses: actions/cache/save@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
path: ${{ env.CCACHE_DIR }}
key: FC-${{ env.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
- name: Upload logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ inputs.artifactBasename }}-${{ matrix.os }}-Logs
path: |
@@ -217,7 +225,7 @@ jobs:
- name: Upload report
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ env.reportfilename }}
path: |
+45 -13
View File
@@ -50,17 +50,22 @@ jobs:
runs-on: ubuntu-22.04
continue-on-error: ${{ inputs.allowedToFail }}
env:
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_CONFIGPATH: ${{ github.workspace }}/ccache/config
CCACHE_MAXSIZE: 1G
CCACHE_COMPILERCHECK: "%compiler% -dumpfullversion -dumpversion" # default:mtime
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 1
CCACHE_COMPRESSLEVEL: 5
CCACHE_CONFIGPATH: ${{ github.workspace }}/ccache/config
CCACHE_DIR: ${{ github.workspace }}/ccache
CCACHE_MAXSIZE: 1G
CCACHE_NODIRECT: true
CCACHE_NOHASHDIR: true
CCACHE_NOINODECACHE: true
CCACHE_SLOPPINESS: "include_file_ctime,include_file_mtime,pch_defines,time_macros"
CC: /usr/bin/gcc
CXX: /usr/bin/g++
#CC: /usr/bin/clang
#CXX: /usr/bin/clang++
builddir: ${{ github.workspace }}/build/release/
config: release
logdir: /tmp/logs/
reportdir: /tmp/report/
reportfilename: ${{ inputs.artifactBasename }}-report.md
@@ -72,12 +77,12 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Checking out source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
submodules: true
@@ -100,38 +105,45 @@ jobs:
mkdir -p ${{ env.logdir }}
mkdir -p ${{ env.reportdir }}
echo "reportFile=${{ env.reportfilename }}" >> $GITHUB_OUTPUT
- name: Generate cache key
id: genCacheKey
uses: ./.github/workflows/actions/linux/generateCacheKey
with:
compiler: ${{ env.CXX }}
qt_major_version: 5
- name: Restore Compiler Cache
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
id: cache-restore
if: always()
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
save-always: true
path: ${{ env.CCACHE_DIR }}
key: FC-${{ steps.genCacheKey.outputs.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
restore-keys: |
FC-${{ steps.genCacheKey.outputs.cacheKey }}-${{ github.ref }}-
FC-${{ steps.genCacheKey.outputs.cacheKey }}-
- name: Print CCache statistics before build, reset stats and print config
run: |
ccache -s
ccache -z
ccache -p
- name: Install cmake
uses: jwlawson/actions-setup-cmake@802fa1a2c4e212495c05bf94dba2704a92a472be # v2.0.2
with:
cmake-version: '3.31.6'
- name: CMake Configure
uses: ./.github/workflows/actions/linux/configure
with:
extraParameters: -G Ninja --preset release
extraParameters: -G Ninja --preset ${{ env.config }}
builddir: ${{ env.builddir }}
logFile: ${{ env.logdir }}Cmake.log
errorFile: ${{ env.logdir }}CmakeErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: CMake Build
uses: ./.github/workflows/actions/linux/build
with:
@@ -139,9 +151,12 @@ jobs:
logFile: ${{ env.logdir }}Build.log
errorFile: ${{ env.logdir }}BuildErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: Print ccache statistics after Build
if: always()
run: |
ccache -s
- name: FreeCAD CLI tests on build dir
if: inputs.testOnBuildDir
timeout-minutes: 10
@@ -151,15 +166,18 @@ jobs:
testCommand: ${{ env.builddir }}/bin/FreeCADCmd -t 0
logFile: ${{ env.logdir }}TestCLIBuild.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD GUI tests on build dir
if: inputs.testOnBuildDir
timeout-minutes: 15
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "GUI tests on build dir"
testCommand: xvfb-run ${{ env.builddir }}/bin/FreeCAD -t 0
# Use Python wrapper to run only GUI-registered tests with the built FreeCAD executable
testCommand: xvfb-run python3 ./.github/scripts/run_gui_tests.py "${{ env.builddir }}"
logFile: ${{ env.logdir }}TestGUIBuild.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: C++ tests
timeout-minutes: 1
uses: ./.github/workflows/actions/runCPPTests/runAllTests
@@ -167,6 +185,7 @@ jobs:
reportdir: ${{ env.reportdir }}
builddir: ${{ env.builddir }}
reportFile: ${{ env.reportdir }}${{ env.reportfilename }}
- name: CMake Install
uses: ./.github/workflows/actions/linux/install
with:
@@ -174,6 +193,7 @@ jobs:
logFile: ${{ env.logdir }}Install.log
errorFile: ${{ env.logdir }}InstallErrors.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD CLI tests on install
timeout-minutes: 10
uses: ./.github/workflows/actions/runPythonTests
@@ -182,25 +202,37 @@ jobs:
testCommand: FreeCADCmd -t 0
logFile: ${{ env.logdir }}TestCLIInstall.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: FreeCAD GUI tests on install
timeout-minutes: 15
uses: ./.github/workflows/actions/runPythonTests
with:
testDescription: "GUI tests on install"
testCommand: xvfb-run FreeCAD -t 0
# Use Python wrapper to run only GUI-registered tests using the installed FreeCAD
testCommand: xvfb-run python3 ./.github/scripts/run_gui_tests.py "FreeCAD"
logFile: ${{ env.logdir }}TestGUIInstall.log
reportFile: ${{env.reportdir}}${{ env.reportfilename }}
- name: Save Compiler Cache
id: cache-save
if: always()
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
path: ${{ env.CCACHE_DIR }}
key: FC-${{ steps.genCacheKey.outputs.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
- name: Upload logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ inputs.artifactBasename }}-Logs
path: |
${{ env.logdir }}
/var/crash/*FreeCAD*
- name: Upload report
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ env.reportfilename }}
path: |
+42 -16
View File
@@ -42,19 +42,22 @@ jobs:
runs-on: windows-latest
continue-on-error: ${{ inputs.allowedToFail }}
env:
CCACHE_DIR: C:/FC/cache/
CCACHE_COMPILERCHECK: "%compiler%" # default:mtime
CCACHE_MAXSIZE: 1G
CCACHE_COMPRESS: true
CCACHE_COMPRESSLEVEL: 1
CCACHE_NOHASHDIR: true
CCACHE_DIRECT: true
#CCACHE_SLOPPINESS: "pch_defines,time_macros" # Can't get PCH to work on Windows
CCACHE_COMPRESSLEVEL: 5
CCACHE_DIR: C:/FC/cache/
CCACHE_LOGFILE: C:/logs/ccache.log
CCACHE_MAXSIZE: 1G
CCACHE_NODIRECT: true
CCACHE_NOHASHDIR: true
CCACHE_NOINODECACHE: true
CCACHE_SLOPPINESS: "include_file_ctime,include_file_mtime,pch_defines,time_macros" # Can't get PCH to work on Windows
## Have to use C:\ because not enough space on workspace drive
builddir: C:/FC/build/release/
libpackdir: C:/FC/libpack/
cacheKey: Windows
ccachebindir: C:/FC/ccache/
config: release
libpackdir: C:/FC/libpack/
logdir: C:/logs/
reportdir: C:/report/
reportfilename: ${{ inputs.artifactBasename }}-report.md
@@ -63,14 +66,15 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Checking out source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
submodules: true
- name: Make needed directories, files and initializations
id: Init
run: |
@@ -81,36 +85,43 @@ jobs:
mkdir ${{ env.logdir }}
mkdir ${{ env.reportdir }}
echo "reportFile=${{ env.reportfilename }}" >> $GITHUB_OUTPUT
- name: Get Ccache
uses: ./.github/workflows/actions/windows/getCcache
with:
ccachebindir: ${{ env.ccachebindir }}
- name: Get Libpack
uses: ./.github/workflows/actions/windows/getLibpack
with:
libpackdir: ${{ env.libpackdir }}
- name: Restore compiler cache
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4.2.3
id: cache-restore
if: always()
uses: actions/cache/restore@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
save-always: true
path: ${{ env.CCACHE_DIR }}
key: FC-Windows-${{ github.ref }}-${{ github.run_id }}
key: FC-${{ env.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
restore-keys: |
FC-Windows-${{ github.ref }}-
FC-Windows-
FC-${{ env.cacheKey }}-${{ github.ref }}-
FC-${{ env.cacheKey }}-
- name: Print Ccache statistics before build, reset stats and print config
run: |
. $env:ccachebindir\ccache -s
. $env:ccachebindir\ccache -z
. $env:ccachebindir\ccache -p
- name: Install cmake
uses: jwlawson/actions-setup-cmake@802fa1a2c4e212495c05bf94dba2704a92a472be # v2.0.2
with:
cmake-version: '3.31.6'
- name: Configuring CMake
run: >
cmake -B"${{ env.builddir }}" .
--preset release
--preset ${{ env.config }}
-DCMAKE_VS_NO_COMPILE_BATCHING=ON
-DCMAKE_BUILD_TYPE=Release
-DFREECAD_USE_PCH=OFF
@@ -119,26 +130,41 @@ jobs:
-DFREECAD_COPY_DEPEND_DIRS_TO_BUILD=ON
-DFREECAD_COPY_LIBPACK_BIN_TO_BUILD=ON
-DFREECAD_COPY_PLUGINS_BIN_TO_BUILD=ON
- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@6fb02220983dee41ce7ae257b6f4d8f9bf5ed4ce # v2.0.0
- name: Compiling sources
run: |
cd $env:builddir
msbuild ALL_BUILD.vcxproj /m /p:Configuration=Release /p:TrackFileAccess=false /p:CLToolPath=${{ env.ccachebindir }}
- name: Print Ccache statistics after build
if: always()
run: |
. $env:ccachebindir\ccache -s
- name: C++ unit tests
if: false # Disabled because seems to not function on Windows build
timeout-minutes: 1
run: |
. ${{ env.builddir }}\tests\Release\Tests_run --gtest_output=json:${{ env.reportdir }}gtest_results.json # 2>&1 | tee -filepath ${{ env.logdir }}\unitTests.log
- name: FreeCAD CLI tests
run: |
. ${{ env.builddir }}\bin\FreeCADCmd -t 0 # 2>&1 | tee -filepath ${{ env.logdir }}\integrationTests.log
- name: Save Compiler Cache
id: cache-save
if: always()
uses: actions/cache/save@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
with:
path: ${{ env.CCACHE_DIR }}
key: FC-${{ env.cacheKey }}-${{ github.ref }}-${{ github.run_id }}
- name: Upload logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ inputs.artifactBasename }}-Logs
path: |
+4 -4
View File
@@ -198,12 +198,12 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Check out code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
submodules: true
@@ -355,7 +355,7 @@ jobs:
- name: Upload logs and fixes
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ inputs.artifactBasename }}-Logs
path: |
@@ -364,7 +364,7 @@ jobs:
- name: Upload report
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ env.reportfilename }}
path: |
+4 -4
View File
@@ -81,7 +81,7 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -94,7 +94,7 @@ jobs:
touch ${{ env.logdir }}changedFiles.lst ${{ env.logdir }}changedCppFiles.lst ${{ env.logdir }}changedPythonFiles.lst
echo "reportFile=${{ env.reportfilename }}" >> $GITHUB_OUTPUT
- name: Check out code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
submodules: true
- name: Determine base and head SHA in case of PR
@@ -180,14 +180,14 @@ jobs:
echo "" >> $GITHUB_OUTPUT
- name: Upload logs
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ inputs.artifactBasename }}-Logs
path: |
${{ env.logdir }}
- name: Upload report
if: always()
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
uses: actions/upload-artifact@330a01c490aca151604b8cf639adc76d48f6c5d4 # v5.0.0
with:
name: ${{ env.reportfilename }}
path: |
+7 -7
View File
@@ -1,7 +1,7 @@
name: Weekly Build
on:
schedule:
- cron: "42 18 * * 1"
- cron: "0 0 * * 3"
workflow_dispatch:
permissions:
@@ -14,12 +14,12 @@ jobs:
build_tag: ${{ steps.tag_build.outputs.build_tag }}
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
- name: Checkout Source
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 2
fetch-tags: true
@@ -72,7 +72,7 @@ jobs:
environment: weekly-build
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -98,15 +98,15 @@ jobs:
fi
- name: Checkout Source
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
with:
fetch-depth: 2
fetch-tags: true
submodules: 'recursive'
- uses: prefix-dev/setup-pixi@307e5e5842748e3752d5178fbd158e0a6c1b55ff # v0.8.12
- uses: prefix-dev/setup-pixi@82d477f15f3a381dbcc8adc1206ce643fe110fb7 # v0.9.3
with:
pixi-version: v0.48.1
pixi-version: v0.59.0
cache: false
- name: Install the Apple certificate and provisioning profile
+2 -2
View File
@@ -54,7 +54,7 @@ jobs:
steps:
- name: Harden the runner (Audit all outbound calls)
uses: step-security/harden-runner@ec9f2d5744a09debf3a187a3f4f675c53b671911 # v2.13.0
uses: step-security/harden-runner@95d9a5deda9de15063e7595e9719c11c38c90ae2 # v2.13.2
with:
egress-policy: audit
@@ -62,7 +62,7 @@ jobs:
run: |
mkdir -p ${{ env.artifactsDownloadDir }}
- name: Download artifacts
uses: actions/download-artifact@d3f86a106a0bac45b974a628896c90dbdf5c8093 # v4.3.0
uses: actions/download-artifact@634f93cb2916e3fdff6788551b99b062d0335ce0 # v5.0.0
with:
path: ${{ env.artifactsDownloadDir }}
- name: Save input data to file
+1
View File
@@ -1,5 +1,6 @@
# file types to ignore
.*
!/.packit.yaml
!/.clang-format
!/.clang-tidy
!/.git-blame-ignore-revs
+68
View File
@@ -0,0 +1,68 @@
specfile_path: package/fedora/freecad.spec
files_to_sync:
- .packit.yaml
actions:
post-upstream-clone:
- bash -c 'BUILD_TAG=dev /usr/bin/python3 package/rattler-build/scripts/make_version_file.py freecad_version.txt'
- rm -f freecad-sources.tar.gz
changelog-entry:
- bash -c 'git log --no-merges --pretty="format:- %s (%an)" $(git describe --tags --abbrev=0 )..HEAD -- |sed 's/%/%%/g''
create-archive:
- git submodule update --init
- bash -c 'git ls-files --recurse-submodules | tar -caf freecad-sources.tar.gz -T-'
- echo -n 'freecad-sources.tar.gz'
downstream_package_name: freecad
additional_packages:
- python3
jobs:
- job: copr_build
identifier: pull_request
trigger: pull_request
notifications:
pull_request:
successful_build: True
branch: main
additional_repos:
- copr://bpostle/IfcOpenShell
manual_trigger: true
targets:
fedora-stable:
without_opts:
- debug_info
fedora-development:
without_opts:
- debug_info
- job: tests
identifier: pull_request
trigger: pull_request
branch: main
manual_trigger: true
targets:
fedora-latest-stable:
without_opts:
- debug_info
fmf_path: package/fedora/tests
- job: copr_build
identifier: main
trigger: commit
manual_trigger: true
branch: main
additional_repos:
- copr://bpostle/IfcOpenShell
owner: freecad
project: nightly
- job: copr_build
identifier: release
trigger: release
owner: freecad
project: freecad
additional_repos:
- copr://bpostle/IfcOpenShell
targets:
fedora-all:
without_opts:
- tests
+16 -8
View File
@@ -6,20 +6,24 @@ files: |
(?x)^(
.github|
src/Base|
src/Gui|
src/Main|
src/Tools|
tests/src|
src/Mod/Assembly|
src/Mod/BIM|
src/Mod/CAM|
src/Mod/Cloud|
src/Mod/Draft|
src/Mod/Fem|
src/Mod/Help|
src/Mod/Import|
src/Mod/Inspection|
src/Mod/JtReader|
src/Mod/Measure|
src/Mod/Mesh|
src/Mod/MeshPart|
src/Mod/Mesh|
src/Mod/PartDesign|
src/Mod/Part|
src/Mod/Plot|
src/Mod/Points|
src/Mod/ReverseEngineering|
@@ -31,7 +35,8 @@ files: |
src/Mod/Surface|
src/Mod/Test|
src/Mod/Tux|
src/Mod/Web
src/Mod/Web|
tests/src
)
exclude: |
(?x)^(
@@ -44,28 +49,31 @@ exclude: |
src/Gui/3Dconnexion/navlib|
src/Gui/QSint|
src/Gui/Quarter|
src/Mod/Fem/femexamples|
src/Mod/Import/App/SCL|
src/Mod/Import/App/SCL_output|
src/Mod/Mesh/App/TestData|
src/Mod/Mesh/App/WildMagic4|
src/Mod/Robot/App/kdl_cp|
src/Mod/Robot/Lib
src/Mod/Robot/Lib|
.*\.ts$|
.*\.brep$
)
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: cef0300fd0fc4d2a87a85fa2093c6b283ea36f4b # frozen: v5.0.0
rev: 3e8a8703264a2f4a69428a0aa4dcb512790b2c8c # frozen: v6.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- id: mixed-line-ending
- repo: https://github.com/psf/black
rev: 8a737e727ac5ab2f1d4cf5876720ed276dc8dc4b # frozen: 25.1.0
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 2892f1f81088477370d4fbc56545c05d33d2493f # frozen: 25.11.0
hooks:
- id: black
args: ['--line-length', '100']
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: 182152eb8c5ce1cf5299b956b04392c86bd8a126 # frozen: v20.1.8
rev: 317810f3c6a0ad3572367dc86cb6e41863e16e08 # frozen: v21.1.5
hooks:
- id: clang-format
+1
View File
@@ -77,6 +77,7 @@ SetupDoxygen()
SetupLibFmt()
SetupYamlCpp()
SetupZipIos()
find_package(ICU REQUIRED COMPONENTS uc i18n)
if(NOT FREECAD_LIBPACK_USE OR FREECAD_LIBPACK_CHECKFILE_CLBUNDLER OR FREECAD_LIBPACK_CHECKFILE_VERSION)
SetupPython()
SetupPCL()
+147 -1
View File
@@ -177,6 +177,10 @@
"type": "FILEPATH",
"value": "$env{CONDA_PREFIX}"
},
"FREECAD_3DCONNEXION_SUPPORT": {
"type": "STRING",
"value": "Both"
},
"OCC_INCLUDE_DIR": {
"type": "FILEPATH",
"value": "$env{CONDA_PREFIX}/include/opencascade"
@@ -204,6 +208,10 @@
"type": "FILEPATH",
"value": "$env{CONDA_PREFIX}/Library"
},
"FREECAD_3DCONNEXION_SUPPORT": {
"type": "STRING",
"value": "Both"
},
"OCC_INCLUDE_DIR": {
"type": "FILEPATH",
"value": "$env{CONDA_PREFIX}/Library/include/opencascade"
@@ -299,6 +307,144 @@
"value": "OFF"
}
}
}
},
{
"name": "rpm",
"description": "Settings like rpm build",
"displayName": "rpm",
"generator": "Ninja",
"binaryDir": "${sourceDir}/build/rpm",
"cacheVariables": {
"CMAKE_INSTALL_DATAROOTDIR": {
"type": "PATH",
"value": "/usr/share"
},
"CMAKE_C_FLAGS_RELEASE": {
"type": "STRING",
"value": "-DNDEBUG"
},
"CMAKE_CXX_FLAGS_RELEASE": {
"type": "STRING",
"value": "-DNDEBUG"
},
"CMAKE_Fortran_FLAGS_RELEASE": {
"type": "STRING",
"value": "-DNDEBUG"
},
"CMAKE_VERBOSE_MAKEFILE": {
"type": "BOOL",
"value": "ON"
},
"CMAKE_INSTALL_DO_STRIP": {
"type": "BOOL",
"value": "OFF"
},
"CMAKE_INSTALL_PREFIX": {
"type": "PATH",
"value": "/usr/lib64/freecad"
},
"CMAKE_INSTALL_FULL_SBINDIR": {
"type": "PATH",
"value": "/usr/bin"
},
"CMAKE_INSTALL_SBINDIR": {
"type": "PATH",
"value": "bin"
},
"INCLUDE_INSTALL_DIR": {
"type": "PATH",
"value": "/usr/include"
},
"LIB_INSTALL_DIR": {
"type": "PATH",
"value": "/usr/lib64"
},
"SYSCONF_INSTALL_DIR": {
"type": "PATH",
"value": "/etc"
},
"SHARE_INSTALL_PREFIX": {
"type": "PATH",
"value": "/usr/share"
},
"LIB_SUFFIX": {
"type": "STRING",
"value": "64"
},
"BUILD_SHARED_LIBS": {
"type": "BOOL",
"value": "ON"
},
"CMAKE_INSTALL_DOCDIR": {
"type": "PATH",
"value": "/usr/share/doc/freecad"
},
"CMAKE_INSTALL_INCLUDEDIR": {
"type": "PATH",
"value": "/usr/include"
},
"RESOURCEDIR": {
"type": "PATH",
"value": "/usr/share/freecad"
},
"FREECAD_USE_EXTERNAL_PIVY": {
"type": "BOOL",
"value": "TRUE"
},
"FREECAD_USE_EXTERNAL_FMT": {
"type": "BOOL",
"value": "TRUE"
},
"FREECAD_USE_PCL": {
"type": "BOOL",
"value": "OFF"
},
"FREECAD_QT_VERSION": {
"type": "STRING",
"value": "6"
},
"OpenGL_GL_PREFERENCE": {
"type": "STRING",
"value": "GLVND"
},
"USE_OCC": {
"type": "BOOL",
"value": "TRUE"
},
"PYCXX_INCLUDE_DIR": {
"type": "PATH",
"value": "/usr/include"
},
"PYCXX_SOURCE_DIR": {
"type": "PATH",
"value": "/usr/src/CXX"
},
"ENABLE_DEVELOPER_TESTS": {
"type": "BOOL",
"value": "TRUE"
},
"FREECAD_USE_EXTERNAL_GTEST": {
"type": "BOOL",
"value": "TRUE"
},
"ONDSELSOLVER_BUILD_EXE": {
"type": "BOOL",
"value": "TRUE"
},
"BUILD_GUI": {
"type": "BOOL",
"value": "TRUE"
}
},
"environment": {
"CC": "gcc",
"CXX": "g++",
"LT_SYS_LIBRARY_PATH": "/usr/lib64:",
"CCACHE_PROGRAM": "/usr/bin/ccache",
"CFLAGS": "-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=x86-64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -mtls-dialect=gnu2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer",
"CXXFLAGS": "-O2 -flto=auto -ffat-lto-objects -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-U_FORTIFY_SOURCE,-D_FORTIFY_SOURCE=3 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -march=x86-64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -mtls-dialect=gnu2 -fno-omit-frame-pointer -mno-omit-leaf-frame-pointer",
"LDFLAGS": "-Wl,--as-needed -Wl,--no-undefined"
}
}
]
}
+6 -4
View File
@@ -57,7 +57,7 @@ The FreeCAD Contribution Process is expressed here with the following specific g
9. A PR MUST compile cleanly and pass project self-tests on all target platforms.
10. Changes that break python API used by extensions SHALL be avoided. If it is not possible to avoid breaking changes, the amount of them MUST be minimized and PR MUST clearly describe all breaking changes with clear description on how to replace no longer working solution with newer one. Contributor SHOULD search for addons that will be broken and list them in the PR.
11. Each commit message in a PR MUST succinctly explain what the commit achieves. The commit message SHALL follow the suggestions in the `git commit --help` documentation, section DISCUSSION.
12. The PR message MUST consist of a single short line, the PR Title, summarizing the problem being solved, followed by a blank line and then the proposed solution in the Body. If a PR consists of more than one commit, the PR Title MUST succinctly explain what the PR achieves. The Body MAY be as detailed as needed. If a PR changes the user interface (UI), the body of the text MUST include a presentation of these UI changes, preferably with screenshots of the previous and revised state.
12. The PR Title MUST succinctly explain what the PR achieves. The Body MAY be as detailed as needed. If a PR changes the user interface (UI), the body of the text MUST include a presentation of these UI changes, preferably with screenshots of the previous and revised state.
13. If a PR contains the work of another author (for example, if it is cherry-picked from a fork by someone other than the PR-submitter):
1. the PR description MUST contain proper attribution as the first line, for example: "This is work of XYZ cherry-picked from <link>";
2. all commits MUST have proper authorship, i.e. be authored by the original author and committed by the author of the PR;
@@ -86,9 +86,11 @@ The FreeCAD Contribution Process is expressed here with the following specific g
2. capture toxic contributions in the historical record
3. engage with the Contributor on improving their contribution quality.
14. Maintainers SHALL NOT make value judgments on correct contributions.
15. Any Contributor who has value judgments on a PR SHOULD express these via their own PR.
16. The User who created an issue SHOULD close the issue after checking the PR is successful.
17. Maintainers SHOULD close issues that are left open without action or update for an unreasonable period.
15. If a PR requires significant further work before merging, the PR SHOULD be moved to draft status.
16. If a PR is complete, but should not be merged yet (for example, because it depends on another in-process PR), the "On hold" label SHOULD be applied.
17. Any Contributor who has value judgments on a PR SHOULD express these via their own PR.
18. The User who created an issue SHOULD close the issue after checking the PR is successful.
19. Maintainers SHOULD close issues that are left open without action or update for an unreasonable period.
## 7. Branches and Releases
+121 -98
View File
@@ -1,113 +1,125 @@
GNU LIBRARY GENERAL PUBLIC LICENSE
Version 2, June 1991
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991 Free Software Foundation, Inc.
51 Franklin Street - Fifth Floor
Boston, MA 02110-1301, USA.
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the library GPL. It is
numbered 2 because it goes with version 2 of the ordinary GPL.]
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Library General Public License, applies to some
specially designated Free Software Foundation software, and to any
other libraries whose authors decide to use it. You can use it for
your libraries, too.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations below.
When we speak of free software, we are referring to freedom, not
price. Our General Public Licenses are designed to make sure that you
have the freedom to distribute copies of free software (and charge for
this service if you wish), that you receive source code or can get it
if you want it, that you can change the software or use pieces of it
in new free programs; and that you know you can do these things.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
anyone to deny you these rights or to ask you to surrender the rights.
These restrictions translate to certain responsibilities for you if
you distribute copies of the library, or if you modify it.
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link a program with the library, you must provide
complete object files to the recipients so that they can relink them
with the library, after making changes to the library and recompiling
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
Our method of protecting your rights has two steps: (1) copyright
the library, and (2) offer you this license which gives you legal
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
Also, for each distributor's protection, we want to make certain
that everyone understands that there is no warranty for this free
library. If the library is modified by someone else and passed on, we
want its recipients to know that what they have is not the original
version, so that any problems introduced by others will not reflect on
the original authors' reputations.
Finally, any free program is threatened constantly by software
patents. We wish to avoid the danger that companies distributing free
software will individually obtain patent licenses, thus in effect
transforming the program into proprietary software. To prevent this,
we have made it clear that any patent must be licensed for everyone's
free use or not licensed at all.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Most GNU software, including some libraries, is covered by the ordinary
GNU General Public License, which was designed for utility programs. This
license, the GNU Library General Public License, applies to certain
designated libraries. This license is quite different from the ordinary
one; be sure to read it in full, and don't assume that anything in it is
the same as in the ordinary license.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
The reason we have a separate public license for some libraries is that
they blur the distinction we usually make between modifying or adding to a
program and simply using it. Linking a program with a library, without
changing the library, is in some sense simply using the library, and is
analogous to running a utility program or application program. However, in
a textual and legal sense, the linked executable is a combined work, a
derivative of the original library, and the ordinary General Public License
treats it as such.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
Because of this blurred distinction, using the ordinary General
Public License for libraries did not effectively promote software
sharing, because most developers did not use the libraries. We
concluded that weaker conditions might promote sharing better.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
However, unrestricted linking of non-free programs would deprive the
users of those programs of all benefit from the free status of the
libraries themselves. This Library General Public License is intended to
permit developers of non-free programs to use free libraries, while
preserving your freedom as a user of such programs to change the free
libraries that are incorporated in them. (We have not seen how to achieve
this as regards changes in header files, but we have achieved it as regards
changes in the actual functions of the Library.) The hope is that this
will lead to faster development of free libraries.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it becomes
a de-facto standard. To achieve this, non-free programs must be
allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, while the latter only
works together with the library.
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
Note that it is possible for a library to be covered by the ordinary
General Public License rather than by this special one.
GNU LIBRARY GENERAL PUBLIC LICENSE
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library which
contains a notice placed by the copyright holder or other authorized
party saying it may be distributed under the terms of this Library
General Public License (also called "this License"). Each licensee is
addressed as "you".
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
@@ -134,7 +146,7 @@ such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
@@ -146,7 +158,7 @@ Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
@@ -204,7 +216,7 @@ instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
@@ -255,8 +267,8 @@ Library will still fall under Section 6.)
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also compile or
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
@@ -283,23 +295,31 @@ of these things:
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Accompany the work with a written offer, valid for at
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at
least three years, to give the same user the materials
specified in Subsection 6a, above, for a charge no more
than the cost of performing this distribution.
c) If distribution of the work is made by offering access to copy
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
d) Verify that the user has already received a copy of these
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the source code distributed need not include anything that is normally
distributed (in either source or binary form) with the major
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
@@ -309,7 +329,7 @@ restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
@@ -348,9 +368,9 @@ Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties to
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
@@ -391,7 +411,7 @@ excluded. In such case, this License incorporates the limitation as if
written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Library General Public License from time to time.
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
@@ -402,7 +422,7 @@ conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
@@ -412,7 +432,7 @@ decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
@@ -435,8 +455,9 @@ FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
@@ -455,7 +476,7 @@ convey the exclusion of warranty; and each file should have at least the
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2 of the License, or (at your option) any later version.
version 2.1 of the License, or (at your option) any later version.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
@@ -464,7 +485,8 @@ convey the exclusion of warranty; and each file should have at least the
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301
USA
Also add information on how to contact you by electronic and paper mail.
@@ -473,7 +495,8 @@ school, if any, to sign a "copyright disclaimer" for the library, if
necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James Random Hacker.
library `Frob' (a library for tweaking knobs) written by James Random
Hacker.
<signature of Ty Coon>, 1 April 1990
Ty Coon, President of Vice
+8 -9
View File
@@ -1,6 +1,6 @@
<a href="https://freecad.org"><img src="/src/Gui/Icons/freecad.svg" height="100px" width="100px"></a>
### Your own 3D parametric modeler
### Your own 3D Parametric Modeler
[Website](https://www.freecad.org) •
[Documentation](https://wiki.freecad.org) •
@@ -10,7 +10,7 @@
[Blog](https://blog.freecad.org)
[![Release](https://img.shields.io/github/release/freecad/freecad.svg)](https://github.com/freecad/freecad/releases/latest) [![Crowdin](https://d322cqt584bo4o.cloudfront.net/freecad/localized.svg)](https://crowdin.com/project/freecad) [![Liberapay](https://img.shields.io/liberapay/receives/FreeCAD.svg?logo=liberapay)](https://liberapay.com/FreeCAD)
[![Release](https://img.shields.io/github/release/freecad/freecad.svg)](https://github.com/freecad/freecad/releases/latest) [![Crowdin](https://d322cqt584bo4o.cloudfront.net/freecad/localized.svg)](https://crowdin.com/project/freecad)
<img src="/.github/images/partdesign.png" width="800"/>
@@ -22,8 +22,8 @@ modeler made primarily to design real-life objects of any size.
Parametric modeling allows you to easily modify your design by going back into
your model history to change its parameters.
* **Create 3D from 2D and back** FreeCAD lets you to sketch geometry constrained
2D shapes and use them as a base to build other objects.
* **Create 3D from 2D and back** FreeCAD lets you sketch geometry-constrained
2D shapes and use them as a base to build other objects.
It contains many components to adjust dimensions or extract design details from
3D models to create high quality production-ready drawings.
@@ -44,12 +44,12 @@ Installing
----------
Precompiled packages for stable releases are available for Windows, macOS and Linux on the
[Releases page](https://github.com/FreeCAD/FreeCAD/releases).
[latest releases page](https://github.com/FreeCAD/FreeCAD/releases/latest).
On most Linux distributions, FreeCAD is also directly installable from the
software center application.
For development releases visit the [weekly-builds page](https://github.com/FreeCAD/FreeCAD-Bundle/releases/tag/weekly-builds).
For weekly development releases visit the [releases page](https://github.com/FreeCAD/FreeCAD/releases/).
Other options are described on the [wiki Download page](https://wiki.freecad.org/Download).
@@ -73,7 +73,7 @@ To report an issue please:
- Consider posting to the [Forum](https://forum.freecad.org), [Discord](https://discord.com/invite/w2cTKGzccC) channel, or [Reddit](https://www.reddit.com/r/FreeCAD) to verify the issue;
- Search the existing [issues](https://github.com/FreeCAD/FreeCAD/issues) for potential duplicates;
- Use the most updated stable or [development versions](https://github.com/FreeCAD/FreeCAD-Bundle/releases/tag/weekly-builds) of FreeCAD;
- Use the most updated stable or [development versions](https://github.com/FreeCAD/FreeCAD/releases/) of FreeCAD;
- Post version info from `Help > About FreeCAD > Copy to clipboard`;
- Restart FreeCAD in safe mode `Help > Restart in safe mode` and try to reproduce the issue again. If the issue is resolved it can be fixed by deleting the FreeCAD config files.
- Start recording a macro `Macro > Macro recording...` and repeat all steps. Stop recording after the issue occurs and upload the saved macro or copy the macro code in the issue;
@@ -86,7 +86,6 @@ For more details see:
- [Reporting Issues and Requesting Features](https://github.com/FreeCAD/FreeCAD/issues/new/choose)
- [Contributing](https://github.com/FreeCAD/FreeCAD/blob/main/CONTRIBUTING.md)
- [Help Forum](https://forum.freecad.org/viewforum.php?f=3)
- [Developers Handbook](https://freecad.github.io/DevelopersHandbook/)
> [!NOTE]
The [FPA](https://fpa.freecad.org) offers developers the opportunity
@@ -106,7 +105,7 @@ View these pages for more information:
- [Frequent questions](https://wiki.freecad.org/FAQ/en)
- [Workbenches](https://wiki.freecad.org/Workbenches)
- [Scripting](https://wiki.freecad.org/Power_users_hub)
- [Development](https://wiki.freecad.org/Developer_hub)
- [Developers Handbook](https://freecad.github.io/DevelopersHandbook/)
The [FreeCAD forum](https://forum.freecad.org) is a great place
to find help and solve specific problems when learning to use FreeCAD.
+20 -9
View File
@@ -23,16 +23,27 @@ if(NOT Eigen3_FIND_VERSION)
endif(NOT Eigen3_FIND_VERSION)
macro(_eigen3_check_version)
file(READ "${EIGEN3_INCLUDE_DIR}/Eigen/src/Core/util/Macros.h" _eigen3_version_header)
# file Version exists from Eigen3 5.0.0
if (EXISTS "${EIGEN3_INCLUDE_DIR}/Eigen/Version")
file(READ "${EIGEN3_INCLUDE_DIR}/Eigen/Version" _eigen3_version_header)
string(REGEX MATCH "define[ \t]+EIGEN_MAJOR_VERSION[ \t]+([0-9]+)" _eigen3_major_version_match "${_eigen3_version_header}")
set(EIGEN3_MAJOR_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_MINOR_VERSION[ \t]+([0-9]+)" _eigen3_minor_version_match "${_eigen3_version_header}")
set(EIGEN3_MINOR_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_PATCH_VERSION[ \t]+([0-9]+)" _eigen3_patch_version_match "${_eigen3_version_header}")
set(EIGEN3_PATCH_VERSION "${CMAKE_MATCH_1}")
set(EIGEN3_VERSION ${EIGEN3_MAJOR_VERSION}.${EIGEN3_MINOR_VERSION}.${EIGEN3_PATCH_VERSION})
else()
file(READ "${EIGEN3_INCLUDE_DIR}/Eigen/src/Core/util/Macros.h" _eigen3_version_header)
string(REGEX MATCH "define[ \t]+EIGEN_WORLD_VERSION[ \t]+([0-9]+)" _eigen3_world_version_match "${_eigen3_version_header}")
set(EIGEN3_WORLD_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_MAJOR_VERSION[ \t]+([0-9]+)" _eigen3_major_version_match "${_eigen3_version_header}")
set(EIGEN3_MAJOR_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_MINOR_VERSION[ \t]+([0-9]+)" _eigen3_minor_version_match "${_eigen3_version_header}")
set(EIGEN3_MINOR_VERSION "${CMAKE_MATCH_1}")
set(EIGEN3_VERSION ${EIGEN3_WORLD_VERSION}.${EIGEN3_MAJOR_VERSION}.${EIGEN3_MINOR_VERSION})
endif()
string(REGEX MATCH "define[ \t]+EIGEN_WORLD_VERSION[ \t]+([0-9]+)" _eigen3_world_version_match "${_eigen3_version_header}")
set(EIGEN3_WORLD_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_MAJOR_VERSION[ \t]+([0-9]+)" _eigen3_major_version_match "${_eigen3_version_header}")
set(EIGEN3_MAJOR_VERSION "${CMAKE_MATCH_1}")
string(REGEX MATCH "define[ \t]+EIGEN_MINOR_VERSION[ \t]+([0-9]+)" _eigen3_minor_version_match "${_eigen3_version_header}")
set(EIGEN3_MINOR_VERSION "${CMAKE_MATCH_1}")
set(EIGEN3_VERSION ${EIGEN3_WORLD_VERSION}.${EIGEN3_MAJOR_VERSION}.${EIGEN3_MINOR_VERSION})
if(${EIGEN3_VERSION} VERSION_LESS ${Eigen3_FIND_VERSION})
set(EIGEN3_VERSION_OK FALSE)
message(STATUS "Eigen3 version ${EIGEN3_VERSION} found in ${EIGEN3_INCLUDE_DIR}, "
@@ -22,7 +22,7 @@ macro(CheckInterModuleDependencies)
REQUIRES_MODS(BUILD_DRAFT BUILD_SKETCHER BUILD_TECHDRAW)
REQUIRES_MODS(BUILD_DRAWING BUILD_PART BUILD_SPREADSHEET)
REQUIRES_MODS(BUILD_FEM BUILD_PART)
REQUIRES_MODS(BUILD_IMPORT BUILD_PART)
REQUIRES_MODS(BUILD_IMPORT BUILD_PART BUILD_PART_DESIGN)
REQUIRES_MODS(BUILD_INSPECTION BUILD_MESH BUILD_POINTS BUILD_PART)
REQUIRES_MODS(BUILD_JTREADER BUILD_MESH)
REQUIRES_MODS(BUILD_MESH_PART BUILD_PART BUILD_MESH)
@@ -46,6 +46,8 @@ macro(CompilerChecksAndSetups)
else()
set(CMAKE_CXX_STANDARD 20)
endif()
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
# Log the compiler and version
message(STATUS "Compiler: ${CMAKE_CXX_COMPILER_ID}, version: ${CMAKE_CXX_COMPILER_VERSION}")
@@ -24,11 +24,7 @@ macro(InitializeFreeCADBuildOptions)
option(INSTALL_TO_SITEPACKAGES "If ON the freecad root namespace (python) is installed into python's site-packages" ON)
option(INSTALL_PREFER_SYMLINKS "If ON then fc_copy_sources macro will create symlinks instead of copying files" OFF)
option(OCCT_CMAKE_FALLBACK "disable usage of occt-config files" OFF)
if (WIN32 OR APPLE)
option(FREECAD_USE_QT_FILEDIALOG "Use Qt's file dialog instead of the native one." OFF)
else()
option(FREECAD_USE_QT_FILEDIALOG "Use Qt's file dialog instead of the native one." ON)
endif()
option(FREECAD_USE_QT_DIALOGS "Use Qt's dialogs instead of the native one." OFF)
# == Win32 is default behaviour use the LibPack copied in Source tree ==========
if(MSVC)
@@ -141,6 +141,7 @@ macro(PrintFinalReport)
conditional(pybind11 pybind11_FOUND "not enabled" ${pybind11_VERSION})
simple(Boost ${Boost_VERSION})
simple(XercesC "${XercesC_VERSION} [${XercesC_LIBRARIES}] [${XercesC_INCLUDE_DIRS}]")
simple(ICU "${ICU_VERSION}")
simple(ZLIB "${ZLIB_VERSION_STRING}")
simple(OCC "${OCC_VERSION_STRING} [${OCC_LIBRARY_DIR}] [${OCC_INCLUDE_DIR}]")
simple(OCC_Libs "[${OCC_LIBRARIES}]")
+1 -1
View File
@@ -3,7 +3,7 @@ macro(SetupBoost)
set(_boost_TEST_VERSIONS ${Boost_ADDITIONAL_VERSIONS})
set (BOOST_COMPONENTS program_options regex system thread date_time)
set (BOOST_COMPONENTS program_options regex thread date_time)
find_package(Boost ${BOOST_MIN_VERSION}
COMPONENTS ${BOOST_COMPONENTS} REQUIRED)
@@ -178,38 +178,6 @@ macro(SetupShibokenAndPyside)
endmacro(SetupShibokenAndPyside)
# Macros similar to FindQt4.cmake's WRAP_UI and WRAP_RC, for the automatic generation of Python
# code from Qt4's user interface ('.ui') and resource ('.qrc') files. These macros are called:
# - PYSIDE_WRAP_UI
# - PYSIDE_WRAP_RC
MACRO(PYSIDE_WRAP_UI outfiles)
if (NOT PYSIDE_UIC_EXECUTABLE)
message(FATAL_ERROR "Qt uic is required for generating ${ARGN}")
endif()
FOREACH(it ${ARGN})
GET_FILENAME_COMPONENT(outfile ${it} NAME_WE)
GET_FILENAME_COMPONENT(infile ${it} ABSOLUTE)
SET(outfile ${CMAKE_CURRENT_BINARY_DIR}/ui_${outfile}.py)
if(WIN32 OR APPLE)
ADD_CUSTOM_COMMAND(OUTPUT ${outfile}
COMMAND ${PYSIDE_UIC_EXECUTABLE} ${UICOPTIONS} ${infile} -o ${outfile}
MAIN_DEPENDENCY ${infile}
)
else()
# Especially on Open Build Service we don't want changing date like
# pyside2-uic generates in comments at beginning., which is why
# we follow the tool command with a POSIX-friendly sed.
ADD_CUSTOM_COMMAND(OUTPUT ${outfile}
COMMAND "${PYSIDE_UIC_EXECUTABLE}" ${UICOPTIONS} "${infile}" -o "${outfile}"
COMMAND sed "/^# /d" "${outfile}" >"${outfile}.tmp" && mv "${outfile}.tmp" "${outfile}"
MAIN_DEPENDENCY "${infile}"
)
endif()
list(APPEND ${outfiles} ${outfile})
ENDFOREACH(it)
ENDMACRO (PYSIDE_WRAP_UI)
MACRO(PYSIDE_WRAP_RC outfiles)
if (NOT PYSIDE_RCC_EXECUTABLE)
message(FATAL_ERROR "Qt rcc is required for generating ${ARGN}")
+5 -41
View File
@@ -18,8 +18,12 @@ MACRO (fc_copy_sources target_name outpath)
foreach(it ${ARGN})
get_filename_component(infile ${it} ABSOLUTE)
get_filename_component(outfile "${outpath}/${it}" ABSOLUTE)
# Ensure parent directory exists when copying or creating symlinks
get_filename_component(outfile_dir "${outfile}" PATH)
add_file_dependencies("${infile}" "${outfile}")
ADD_CUSTOM_COMMAND(
# Make sure destination directory exists before copy/symlink
COMMAND "${CMAKE_COMMAND}" -E make_directory "${outfile_dir}"
COMMAND "${CMAKE_COMMAND}" -E ${copy_command} "${infile}" "${outfile}"
OUTPUT "${outfile}"
COMMENT "Copying ${infile} to ${outfile}${fc_details}"
@@ -211,47 +215,6 @@ macro(generate_from_any INPUT_FILE OUTPUT_FILE VARIABLE)
endmacro(generate_from_any)
MACRO(ADD_MSVC_PRECOMPILED_HEADER TargetName PrecompiledHeader PrecompiledSource SourcesVar)
IF(MSVC)
GET_FILENAME_COMPONENT(PrecompiledBasename ${PrecompiledHeader} NAME_WE)
IF(MSVC_IDE)
SET(PrecompiledBinary "$(IntDir)\\$(TargetName).pch")
ELSE(MSVC_IDE)
SET(PrecompiledBinary ${CMAKE_CURRENT_BINARY_DIR}/${TargetName}.pch)
ENDIF(MSVC_IDE)
SET(Sources ${${SourcesVar}})
SET_SOURCE_FILES_PROPERTIES(${PrecompiledSource}
PROPERTIES COMPILE_FLAGS "/Yc\"${PrecompiledHeader}\" /Fp\"${PrecompiledBinary}\""
OBJECT_OUTPUTS "${PrecompiledBinary}")
SET_SOURCE_FILES_PROPERTIES(${Sources}
PROPERTIES COMPILE_FLAGS "/Yu\"${PrecompiledHeader}\" /FI\"${PrecompiledBinary}\" /Fp\"${PrecompiledBinary}\""
OBJECT_DEPENDS "${PrecompiledBinary}")
# Add precompiled header to SourcesVar
LIST(APPEND ${SourcesVar} ${PrecompiledSource})
ENDIF(MSVC)
ENDMACRO(ADD_MSVC_PRECOMPILED_HEADER)
MACRO(GET_MSVC_PRECOMPILED_SOURCE PrecompiledSource SourcesVar)
IF(MSVC)
FOREACH (it ${ARGN})
GET_FILENAME_COMPONENT(file_ext ${it} EXT)
GET_FILENAME_COMPONENT(file_name ${it} NAME)
STRING(COMPARE EQUAL ${it} ${PrecompiledSource} pch)
IF (NOT pch)
# get c++ source files
STRING(REGEX MATCH "^(.cpp|.cc|.cxx)$" cpp_file ${file_ext})
# ignore any generated source files from Qt
STRING(REGEX MATCH "^(moc_|qrc_|ui_)" gen_file ${file_name})
IF(cpp_file AND NOT gen_file)
LIST(APPEND ${SourcesVar} ${it})
ENDIF(cpp_file AND NOT gen_file)
ENDIF(NOT pch)
ENDFOREACH (it)
ENDIF(MSVC)
ENDMACRO(GET_MSVC_PRECOMPILED_SOURCE)
# Macro to replace all the binary output locations. Takes 2 optional parameters.
# ${ARGVN} is zero based so the 3rd element is ${ARGV2}. When the 3rd element is missing,
# Runtime and Lib directories default to /bin and /lib. When present, the 3rd element
@@ -364,3 +327,4 @@ function(target_compile_warn_error ProjectName)
target_compile_options(${ProjectName} PRIVATE -Werror)
endif()
endfunction()
Binary file not shown.
+3 -1
View File
@@ -8,6 +8,9 @@ SET(Examples_Files
FEMExample.FCStd
AssemblyExample.FCStd
ArchDetail.FCStd
FCPAT.pat
osifont.license
osifont-lgpl3fe.ttf
)
ADD_CUSTOM_TARGET(Example_data ALL
@@ -132,4 +135,3 @@ INSTALL(
DESTINATION
${CMAKE_INSTALL_DATADIR}/examples
)
+23
View File
@@ -0,0 +1,23 @@
; standard PAT patterns
*Diamond, 45 diagonals L & R, Solid, 1.0 mm separation
45,0,0,0,1.0
-45,0,0,0,1.0
*Diamond2, 45 diagonals L & R, Solid, 2.0 mm separation
45,0,0,0,2.0
-45,0,0,0,2.0
*Diamond4, 45 diagonals L & R, Solid, 4.0 mm separation
45,0,0,0,4.0
-45,0,0,0,4.0
*Diagonal4, 45 diagonal R, Solid, 4.0 mm separation
45,0,0,0,4.0
*Diagonal5, 45 diagonal L, Solid, 4.0 mm separation
-45,0,0,0,4.0
*Square, square grid, Solid, 5.0 mm separation
90,1,1,0,5.0
0,0,0,1,5.0
*Horizontal5, horizontal lines, Solid 5.0 separation
0,0,0,0,5.0
*Vertical5, vertical lines, Solid, 5.0 separation
90,0,0,0,5.0
Binary file not shown.
Binary file not shown.
+9
View File
@@ -0,0 +1,9 @@
osifont license:
osifont-lgpl3fe.ttf is used under one or more of the following licenses:
- GNU GPL licence version 3 with GPL font exception,
- GNU GPL licence version 2 with GPL font exception,
- GNU LGPL licence version 3 with GPL font exception.
https://github.com/hikikomori82/osifont/
+29
View File
@@ -0,0 +1,29 @@
# Cube
v -5. -5. -5.
v 5. -5. -5.
v 5. -5. 5.
v -5. -5. 5.
v -5. 5. -5.
v 5. 5. 5.
v 5. 5. -5.
v -5. 5. 5.
vt 0.645815 0.980689
vt 0.549235 0.9999
vt 0.5 0.5
vt 0.450764 0.9999
vt 0.354185 0.980689
vt 0.263209 0.943006
vt 0.181332 0.888298
vt 0.111702 0.818668
f 1/1 2/2 3/3
f 1/1 3/3 4/4
f 5/5 6/6 7/7
f 5/5 8/8 6/6
f 1/1 8/8 5/5
f 1/1 4/4 8/8
f 2/2 7/7 6/6
f 2/2 6/6 3/3
f 1/1 5/5 7/7
f 1/1 7/7 2/2
f 4/4 6/6 8/8
f 4/4 3/3 6/6
+239 -281
View File
@@ -1,109 +1,67 @@
# This package depends on automagic byte compilation
# https://fedoraproject.org/wiki/Changes/No_more_automagic_Python_bytecompilation_phase_3
%global py_bytecompile 1
# Some configuration options for other environments
# rpmbuild --without=bundled_zipios: don't use bundled version of zipios++
%bcond_without bundled_zipios
# rpmbuild --with=bundled_pycxx: use bundled version of pycxx
%bcond_with bundled_pycxx
# rpmbuild --without=bundled_smesh: don't use bundled version of Salome's Mesh
%bcond_without bundled_smesh
# rpmbuild --without=bundled_gtest: don't use bundled version of gtest and gmock
%bcond_with bundled_gtest
# rpmbuild --without=tests exclude tests in %%check
%bcond_without tests
# rpmbuild --without=debug_info don't generate package with debug info
%bcond_without debug_info
Name: freecad
Epoch: 1
Version: 1.1.0~dev
Release: 1%{?dist}
Summary: A general purpose 3D CAD modeler
Group: Applications/Engineering
License: LGPL-2.0-or-later
URL: https://www.freecad.org/
Source0: freecad-sources.tar.gz
# Setup python target for shiboken so the right cmake file is imported.
%global py_suffix %(%{__python3} -c "import sysconfig; print(sysconfig.get_config_var('SOABI'))")
# Maintainers: keep this list of plugins up to date
# List plugins in %%{_libdir}/%{name}/lib, less '.so' and 'Gui.so', here
%global plugins AssemblyApp AssemblyGui CAMSimulator DraftUtils Fem FreeCAD Import Inspection MatGui Materials Measure Mesh MeshPart Part PartDesignGui Path PathApp PathSimulator Points QtUnitGui ReverseEngineering Robot Sketcher Spreadsheet Start Surface TechDraw Web _PartDesign area flatmesh libDriver libDriverDAT libDriverSTL libDriverUNV libE57Format libMEFISTO2 libOndselSolver libSMDS libSMESH libSMESHDS libStdMeshers libarea-native
# List plugins in %%{_libdir}/%%{name}/lib, less '.so' and 'Gui.so', here
%global plugins AssemblyApp AssemblyGui CAMSimulator DraftUtils Fem FreeCAD Import Inspection MatGui Materials Measure Mesh MeshPart Part PartDesignGui Path PathApp PathSimulator Points QtUnitGui ReverseEngineering Robot Sketcher Spreadsheet Start Surface TechDraw Web _PartDesign area flatmesh libDriver libDriverDAT libDriverSTL libDriverUNV libE57Format libMEFISTO2 libSMDS libSMESH libSMESHDS libStdMeshers libarea-native
# Some configuration options for other environments
# rpmbuild --with=bundled_zipios: use bundled version of zipios++
%global bundled_zipios %{?_with_bundled_zipios: 1} %{?!_with_bundled_zipios: 1}
# rpmbuild --with=bundled_pycxx: use bundled version of pycxx
%global bundled_pycxx %{?_with_bundled_pycxx: 1} %{?!_with_bundled_pycxx: 0}
# rpmbuild --without=bundled_smesh: don't use bundled version of Salome's Mesh
%global bundled_smesh %{?_without_bundled_smesh: 0} %{?!_without_bundled_smesh: 1}
# Prevent RPM from doing its magical 'build' directory for now
%global __cmake_in_source_build 0
%global exported_libs libOndselSolver
# See FreeCAD-main/src/3rdParty/salomesmesh/CMakeLists.txt to find this out.
%global bundled_smesh_version 7.7.1.0
# Some plugins go in the Mod folder instead of lib. Deal with those here:
%global mod_plugins Mod/PartDesign
%define name freecad
%define github_name FreeCAD
%define branch main
Name: %{name}
Epoch: 1
Version: 1.1.0
Release: pre_{{{git_commit_no}}}%{?dist}
Summary: A general purpose 3D CAD modeler
Group: Applications/Engineering
License: LGPLv2+
URL: https://www.freecad.org/
Source0: {{{ git_repo_pack }}}
#add all submodule as source
Source1: {{{ git_pack path=$GIT_ROOT/src/3rdParty/OndselSolver/ dir_name="OndselSolver" }}}
Source2: {{{ git_pack path=$GIT_ROOT/src/3rdParty/GSL/ dir_name="GSL" }}}
Source3: {{{ git_pack path=$GIT_ROOT/src/Mod/AddonManager/ dir_name="AddonManager" }}}
# See /src/3rdParty/PyCXX/CXX/Version.h to find this out.
%global bundled_pycxx_version 7.1.9
# See /src/3rdParty/OndselSolver/CMakeLists.txt to find this out.
%global bundled_ondsel_solver_version 1.0.1
# Utilities
BuildRequires: cmake gcc-c++ gettext
BuildRequires: doxygen swig graphviz
BuildRequires: gcc-gfortran
BuildRequires: desktop-file-utils
BuildRequires: git
BuildRequires: tbb-devel
BuildRequires: cmake gcc-c++ gettext doxygen swig graphviz gcc-gfortran desktop-file-utils tbb-devel ninja-build strace
%if %{with tests}
BuildRequires: xorg-x11-server-Xvfb python3-typing-extensions
%if %{without bundled_gtest}
BuildRequires: gtest-devel gmock-devel
%endif
%endif
# Development Libraries
BuildRequires: freeimage-devel
BuildRequires: libXmu-devel
BuildRequires: mesa-libEGL-devel
BuildRequires: mesa-libGLU-devel
BuildRequires: opencascade-devel
BuildRequires: Coin4-devel
BuildRequires: python3-devel
BuildRequires: python3-matplotlib
BuildRequires: python3-pivy
BuildRequires: boost-devel
BuildRequires: eigen3-devel
BuildRequires: qt6-qtsvg-devel
BuildRequires: qt6-qttools-static
BuildRequires: fmt-devel
BuildRequires: xerces-c
BuildRequires: xerces-c-devel
BuildRequires: libspnav-devel
BuildRequires: python3-shiboken6-devel
BuildRequires: python3-pyside6-devel
BuildRequires: pyside6-tools
%if ! %{bundled_smesh}
BuildRequires:boost-devel Coin4-devel eigen3-devel freeimage-devel fmt-devel libglvnd-devel libicu-devel libspnav-devel libXmu-devel med-devel mesa-libEGL-devel mesa-libGLU-devel netgen-mesher-devel netgen-mesher-devel-private opencascade-devel openmpi-devel python3 python3-devel python3-matplotlib python3-pivy python3-pybind11 python3-pyside6-devel python3-shiboken6-devel pyside6-tools qt6-qttools-static qt6-qtsvg-devel vtk-devel xerces-c-devel yaml-cpp-devel
#pcl-devel
%if %{without bundled_smesh}
BuildRequires: smesh-devel
%endif
BuildRequires: netgen-mesher-devel
BuildRequires: netgen-mesher-devel-private
%if ! %{bundled_zipios}
%if %{without bundled_zipios}
BuildRequires: zipios++-devel
%endif
%if ! %{bundled_pycxx}
%if %{without bundled_pycxx}
BuildRequires: python3-pycxx-devel
%endif
BuildRequires: python3-pybind11
BuildRequires: libicu-devel
BuildRequires: vtk-devel
BuildRequires: openmpi-devel
BuildRequires: med-devel
BuildRequires: libkdtree++-devel
BuildRequires: pcl-devel
BuildRequires: python3
BuildRequires: libglvnd-devel
BuildRequires: yaml-cpp-devel
#BuildRequires: zlib-devel
# For appdata
%if 0%{?fedora}
BuildRequires: libappstream-glib
@@ -115,38 +73,31 @@ Requires: %{name}-data = %{epoch}:%{version}-%{release}
# Obsolete old doc package since it's required for functionality.
Obsoletes: %{name}-doc < 0.22-1
Requires: hicolor-icon-theme
Requires: hicolor-icon-theme fmt python3-matplotlib python3-pivy python3-collada python3-pyside6 qt6-assistant python3-typing-extensions python3-defusedxml
Requires: fmt
Requires: python3-pivy
Requires: python3-matplotlib
Requires: python3-collada
Requires: python3-pyside6
Requires: qt6-assistant
%if %{bundled_smesh}
%if %{with bundled_smesh}
Provides: bundled(smesh) = %{bundled_smesh_version}
%endif
%if %{bundled_pycxx}
Provides: bundled(python-pycxx)
%if %{with bundled_pycxx}
Provides: bundled(python-pycxx) = %{bundled_pycxx_version}
%endif
Recommends: python3-pysolar
Provides: bundled(libondselsolver) = %{bundled_ondsel_solver_version}
Recommends: python3-pysolar IfcOpenShell-python3
# plugins and private shared libs in %%{_libdir}/freecad/lib are private;
# prevent private capabilities being advertised in Provides/Requires
%define plugin_regexp /^\\\(libFreeCAD.*%(for i in %{plugins}; do echo -n "\\\|$i\\\|$iGui"; done)\\\)\\\(\\\|Gui\\\)\\.so/d
%{?filter_setup:
%filter_provides_in %{_libdir}/%{name}/lib
%filter_from_requires %{plugin_regexp}
%filter_from_provides %{plugin_regexp}
%filter_provides_in %{_libdir}/%{name}/Mod
%filter_requires_in %{_libdir}/%{name}/Mod
%filter_setup
}
%global plugin_exclude %( for i in %{plugins}; do echo -n "\|$i\(Gui\)\?"; done )
# prevent declaring Requires for internal FreeCAD libraries
%global lib_exclude %( for i in %{exported_libs}; do echo -n "\|$i"; done )
%global __requires_exclude_from ^%{_libdir}/%{name}/(lib|Mod)/.*
%global __provides_exclude_from ^%{_libdir}/%{name}/Mod/.*
%global __provides_exclude ^(libFreeCAD.*%{plugin_exclude})\.so.*
%global __requires_exclude ^(libFreeCAD.*%{plugin_exclude}%{lib_exclude})\.so.*
%description
FreeCAD is a general purpose Open Source 3D CAD/MCAD/CAx/CAE/PLM modeler, aimed
@@ -165,204 +116,211 @@ Requires: %{name} = %{epoch}:%{version}-%{release}
%description data
Data files for FreeCAD
%package libondselsolver-devel
Summary: Development file for OndselSolver
BuildArch: noarch
Requires: %{name} = %{epoch}:%{version}-%{release}
%description libondselsolver-devel
Development file for OndselSolver
#path that contain main FreeCAD sources for cmake
%global tests_resultdir %{_datadir}/%{name}/tests_result/%{_arch}
%if %{without debug_info}
%global debug_package %{nil}
%global _enable_debug_packages 0
%endif
%prep
rm -rf %{github_name}
# extract submodule archive and move in correct path
%setup -T -a 1 -c -q -D -n %{github_name}/src/3rdParty/ #OndselSolver
%setup -T -a 2 -c -q -D -n %{github_name}/src/3rdParty/ #GSL
%setup -T -a 3 -c -q -D -n %{github_name}/src/Mod/ #AddonManager
%setup -T -b 0 -q -D -n %{github_name}
# Remove bundled pycxx if we're not using it
%if ! %{bundled_pycxx}
rm -rf src/CXX
%endif
%if ! %{bundled_zipios}
rm -rf src/zipios++
#sed -i "s/zipios-config.h/zipios-config.hpp/g" \
# src/Base/Reader.cpp src/Base/Writer.h
%endif
# Removed bundled libraries
%setup -T -a 0 -q -c -n FreeCAD-1.0.2
%build
rm -rf build && mkdir build && cd build
# Deal with cmake projects that tend to link excessively.
LDFLAGS='-Wl,--as-needed -Wl,--no-undefined'; export LDFLAGS
# Deal with cmake projects that tend to link excessively.
CXXFLAGS='-Wno-error=cast-function-type'; export CXXFLAGS
LDFLAGS='-Wl,--as-needed -Wl,--no-undefined'; export LDFLAGS
# -DCMAKE_INSTALL_DATADIR=%{_datadir}/%{name} \
# -DCMAKE_INSTALL_DATAROOTDIR=%{_datadir} \
%define MEDFILE_INCLUDE_DIRS %{_includedir}/med/
%cmake \
-DCMAKE_INSTALL_PREFIX=%{_libdir}/%{name} \
-DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name} \
-DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \
-DRESOURCEDIR=%{_datadir}/%{name} \
-DFREECAD_USE_EXTERNAL_PIVY=TRUE \
-DFREECAD_USE_EXTERNAL_FMT=TRUE \
-DFREECAD_USE_PCL:BOOL=OFF \
-DFREECAD_QT_VERSION:STRING=6 \
-DOpenGL_GL_PREFERENCE=GLVND \
-DUSE_OCC=TRUE \
%if %{without bundled_pycxx}
-DPYCXX_INCLUDE_DIR=$(pkg-config --variable=includedir PyCXX) \
-DPYCXX_SOURCE_DIR=$(pkg-config --variable=srcdir PyCXX) \
%endif
%if %{without bundled_smesh}
-DFREECAD_USE_EXTERNAL_SMESH=TRUE \
%endif
%if %{without bundled_zipios}
-DFREECAD_USE_EXTERNAL_ZIPIOS=TRUE \
%endif
%if %{with tests}
-DENABLE_DEVELOPER_TESTS=TRUE \
%if %{without bundled_gtest}
-DFREECAD_USE_EXTERNAL_GTEST=TRUE \
%else
-DINSTALL_GTEST=OFF \
-DINSTALL_GMOCK=OFF \
%endif
%else
-DENABLE_DEVELOPER_TESTS=FALSE \
%endif
-DONDSELSOLVER_BUILD_EXE=TRUE \
-DBUILD_GUI=TRUE \
-G Ninja
%cmake \
-DCMAKE_INSTALL_PREFIX=%{_libdir}/%{name} \
-DCMAKE_INSTALL_DATADIR=%{_datadir}/%{name} \
-DCMAKE_INSTALL_DOCDIR=%{_docdir}/%{name} \
-DCMAKE_INSTALL_INCLUDEDIR=%{_includedir} \
-DRESOURCEDIR=%{_datadir}/%{name} \
-DFREECAD_USE_EXTERNAL_PIVY=TRUE \
-DFREECAD_USE_EXTERNAL_FMT=TRUE \
-DFREECAD_USE_PCL:BOOL=OFF \
-DFREECAD_QT_VERSION:STRING=6 \
-DSHIBOKEN_INCLUDE_DIR=%{_includedir}/shiboken6 \
-DSHIBOKEN_LIBRARY=-lshiboken6.%{py_suffix} \
-DPYTHON_SUFFIX=.%{py_suffix} \
-DPYSIDE_INCLUDE_DIR=/usr/include/PySide6 \
-DPYSIDE_LIBRARY=-lpyside6.%{py_suffix} \
-DPython3_EXECUTABLE:FILEPATH=/usr/bin/python3 \
-DMEDFILE_INCLUDE_DIRS=%{MEDFILE_INCLUDE_DIRS} \
-DOpenGL_GL_PREFERENCE=GLVND \
-DCOIN3D_INCLUDE_DIR=%{_includedir}/Coin4 \
-DCOIN3D_DOC_PATH=%{_datadir}/Coin4/Coin \
-DUSE_OCC=TRUE \
%if ! %{bundled_smesh}
-DFREECAD_USE_EXTERNAL_SMESH=TRUE \
-DSMESH_FOUND=TRUE \
-DSMESH_INCLUDE_DIR=%{_includedir}/smesh \
-DSMESH_DIR=`pwd`/../cMake \
%endif
%if ! %{bundled_zipios}
-DFREECAD_USE_EXTERNAL_ZIPIOS=TRUE \
%endif
%if ! %{bundled_pycxx}
-DPYCXX_INCLUDE_DIR=$(pkg-config --variable=includedir PyCXX) \
-DPYCXX_SOURCE_DIR=$(pkg-config --variable=srcdir PyCXX) \
%endif
-DPACKAGE_WCREF="%{release} (Git)" \
-DPACKAGE_WCURL="git://github.com/%{github_name}/FreeCAD.git main" \
-DENABLE_DEVELOPER_TESTS=FALSE \
-DBUILD_GUI=TRUE \
../
%cmake_build
make fc_version
for I in src/Build/Version.h src/Build/Version.h.out; do
sed -i 's,FCRevision \"Unknown\",FCRevision \"%{release} (Git)\",' $I
sed -i 's,FCRepositoryURL \"Unknown\",FCRepositoryURL \"git://github.com/FreeCAD/FreeCAD.git main\",' $I
done
%{make_build}
%install
cd build
%make_install
%cmake_install
# Symlink binaries to /usr/bin
mkdir -p %{buildroot}%{_bindir}
ln -s ../%{_lib}/%{name}/bin/FreeCAD %{buildroot}%{_bindir}/FreeCAD
ln -s ../%{_lib}/%{name}/bin/FreeCADCmd %{buildroot}%{_bindir}/FreeCADCmd
# Symlink binaries to /usr/bin
mkdir -p %{buildroot}%{_bindir}
ln -s ../%{_lib}/%{name}/bin/FreeCAD %{buildroot}%{_bindir}/FreeCAD
ln -s ../%{_lib}/%{name}/bin/FreeCADCmd %{buildroot}%{_bindir}/FreeCADCmd
mkdir %{buildroot}%{_metainfodir}/
mv %{buildroot}%{_libdir}/%{name}/share/metainfo/* %{buildroot}%{_metainfodir}/
# Remove header from external library that's erroneously installed
rm -rf %{buildroot}%{_libdir}/%{name}/include/E57Format
rm -rf %{buildroot}%{_includedir}/gmock
rm -rf %{buildroot}%{_includedir}/gtest
mkdir %{buildroot}%{_datadir}/applications/
mv %{buildroot}%{_libdir}/%{name}/share/applications/* %{buildroot}%{_datadir}/applications/
mkdir -p %{buildroot}%{_datadir}/thumbnailers/
mv %{buildroot}%{_libdir}/%{name}/share/thumbnailers/* %{buildroot}%{_datadir}/thumbnailers/
mkdir -p %{buildroot}%{_datadir}/icons/hicolor/scalable/
mv %{buildroot}%{_libdir}/%{name}/share/icons/hicolor/scalable/* %{buildroot}%{_datadir}/icons/hicolor/scalable/
mkdir -p %{buildroot}%{_datadir}/pixmaps/
mv %{buildroot}%{_libdir}/%{name}/share/pixmaps/* %{buildroot}%{_datadir}/pixmaps/
mkdir -p %{buildroot}%{_datadir}/mime/packages/
mv %{buildroot}%{_libdir}/%{name}/share/mime/packages/* %{buildroot}%{_datadir}/mime/packages/
pushd %{buildroot}%{_libdir}/%{name}/share/
rmdir metainfo/
rmdir applications/
rm -rf mime
rm -rf icons
popd
# Remove obsolete Start_Page.html
rm -f %{buildroot}%{_docdir}/%{name}/Start_Page.html
# Remove header from external library that's erroneously installed
rm -f %{buildroot}%{_libdir}/%{name}/include/E57Format/E57Export.h
rm -rf %{buildroot}%{_includedir}/OndselSolver/*
rm -f %{buildroot}%{_libdir}/%{name}/share/pkgconfig/OndselSolver.pc
# Bug maintainers to keep %%{plugins} macro up to date.
#
# Make sure there are no plugins that need to be added to plugins macro
new_plugins=`ls %{buildroot}%{_libdir}/%{name}/%{_lib} | sed -e '%{plugin_regexp}'`
if [ -n "$new_plugins" ]; then
echo -e "\n\n\n**** ERROR:\n" \
"\nPlugins not caught by regexp: " $new_plugins \
"\n\nPlugins in %{_libdir}/%{name}/lib do not exist in" \
"\nspecfile %%{plugins} macro. Please add these to" \
"\n%%{plugins} macro at top of specfile and rebuild.\n****\n" 1>&2
exit 1
fi
# Make sure there are no entries in the plugins macro that don't match plugins
for p in %{plugins}; do
if [ -z "`ls %{buildroot}%{_libdir}/%{name}/%{_lib}/$p*.so`" ]; then
set +x
echo -e "\n\n\n**** ERROR:\n" \
"\nExtra entry in %%{plugins} macro with no matching plugin:" \
"'$p'.\n\nPlease remove from %%{plugins} macro at top of" \
"\nspecfile and rebuild.\n****\n" 1>&2
exit 1
fi
done
# Bytecompile Python modules
%py_byte_compile %{__python3} %{buildroot}%{_libdir}/%{name}
rm -rf %{buildroot}%{_libdir}/%{name}/%{_lib}/cmake
rm -rf %{buildroot}%{_libdir}/%{name}/%{_lib}/pkgconfig
#Move files using `-DCMAKE_INSTALL_DATAROOTDIR=%%{_datadir}` break ctest
mkdir -p %{buildroot}%{_datadir}
mv %{buildroot}%{_libdir}/freecad/share/applications %{buildroot}%{_datadir}/
mkdir -p %{buildroot}%{_metainfodir}
mv %{buildroot}%{_libdir}/freecad/share/metainfo/* %{buildroot}%{_metainfodir}/
mkdir -p %{buildroot}%{_datadir}
mv %{buildroot}%{_libdir}/freecad/share/icons %{buildroot}%{_datadir}/
mv %{buildroot}%{_libdir}/freecad/share/pixmaps %{buildroot}%{_datadir}/
mv %{buildroot}%{_libdir}/freecad/share/mime %{buildroot}%{_datadir}/
mv %{buildroot}%{_libdir}/freecad/share/thumbnailers %{buildroot}%{_datadir}/
mv %{buildroot}%{_libdir}/freecad/share/pkgconfig %{buildroot}%{_datadir}/
%check
desktop-file-validate \
%{buildroot}%{_datadir}/applications/org.freecad.FreeCAD.desktop
%{?fedora:appstream-util validate-relax --nonet \
%{buildroot}%{_metainfodir}/*.metainfo.xml}
%if %{with tests}
mkdir -p %{buildroot}%tests_resultdir
if %ctest -E '^QuantitySpinBox_Tests_run$' &> %{buildroot}%tests_resultdir/ctest.result ; then
echo "ctest OK"
else
echo "**** Failed ctest ****"
touch %{buildroot}%tests_resultdir/ctest.failed
fi
if xvfb-run \%ctest -R '^QuantitySpinBox_Tests_run$' &>> %{buildroot}%tests_resultdir/ctest_gui.result ; then
echo "ctest gui OK"
else
echo "**** Failed ctest gui ****"
touch %{buildroot}%tests_resultdir/ctest_gui.failed
fi
%endif
desktop-file-validate %{buildroot}%{_datadir}/applications/org.freecad.FreeCAD.desktop
%{?fedora:appstream-util validate-relax --nonet %{buildroot}%{_metainfodir}/*.metainfo.xml}
# Bug maintainers to keep %%{plugins} macro up to date.
#
# Make sure there are no plugins that need to be added to plugins macro
%define plugin_regexp /^\\\(libFreeCAD.*%(for i in %{plugins}; do echo -n "\\\|$i"; done)\\\)\\\(\\\|Gui\\\)\\.so/d
%define exported_libs_regexp /^\\\(%(for i in %{exported_libs}; do echo -n "\\\|$i"; done)\\\)\\.so/d
new_plugins=`ls %{buildroot}%{_libdir}/%{name}/%{_lib} | sed -e '%{plugin_regexp}' -e '%exported_libs_regexp'`
if [ -n "$new_plugins" ]; then
echo -e "\n\n\n**** ERROR:\n" \
"\nPlugins not caught by regexps:" \
"\n" $new_plugins \
"\n\nPlugins in %{_libdir}/%{name}/lib do not exist in" \
"\nspecfile %%{plugins} or %%{exported_libs_regexp} macro." \
"\nPlease add these to %%{plugins} or %%{exported_libs}" \
"\nmacro at top of specfile" \
"\nand rebuild.\n****\n" 1>&2
exit 1
fi
# Make sure there are no entries in the plugins macro that don't match plugins
for p in %{plugins}; do
if [ -z "`ls %{buildroot}%{_libdir}/%{name}/%{_lib}/$p*.so`" ]; then
set +x
echo -e "\n\n\n**** ERROR:\n" \
"\nExtra entry in %%{plugins} macro with no matching plugin:" \
"'$p'.\n\nPlease remove from %%{plugins} macro at top of" \
"\nspecfile and rebuild.\n****\n" 1>&2
exit 1
fi
done
# Make sure there are no entries in the exported_libs_regexp macro that don't match plugins
for d in %{exported_libs}; do
if [ -z "`ls %{buildroot}%{_libdir}/%{name}/%{_lib}/$d*.so`" ]; then
set +x
echo -e "\n\n\n**** ERROR:\n" \
"\nExtra entry in %%{exported_libs} macro with no matching lib:" \
"'$d'.\n\nPlease remove from %%{exported_libs} macro at top of" \
"\nspecfile and rebuild.\n****\n" 1>&2
exit 1
fi
done
%post
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
/usr/bin/update-desktop-database &> /dev/null || :
/usr/bin/update-mime-database %{_datadir}/mime &> /dev/null || :
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null || :
/usr/bin/update-desktop-database &> /dev/null || :
/usr/bin/update-mime-database %{_datadir}/mime &> /dev/null || :
%postun
if [ $1 -eq 0 ] ; then
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
/usr/bin/update-desktop-database &> /dev/null || :
/usr/bin/update-mime-database %{_datadir}/mime &> /dev/null || :
if [ $1 -eq 0 ] ; then
/bin/touch --no-create %{_datadir}/icons/hicolor &>/dev/null
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || :
fi
/usr/bin/update-desktop-database &> /dev/null || :
/usr/bin/update-mime-database %{_datadir}/mime &> /dev/null || :
%posttrans
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor/scalable/apps &>/dev/null || :
/usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor/scalable/apps &>/dev/null || :
%files
%{_bindir}/*
%{_metainfodir}/*
%dir %{_libdir}/%{name}
%{_libdir}/%{name}/bin/
%{_libdir}/%{name}/%{_lib}/
%{_libdir}/%{name}/Ext/
%{_libdir}/%{name}/Mod/
%{_libdir}/%{name}/share/
%{_datadir}/applications/*
%{_datadir}/icons/hicolor/*
%{_datadir}/pixmaps/*
%{_datadir}/mime/packages/*
%{_datadir}/thumbnailers/*
#find a way to configure in cmake with %%name to avoid conflict with different package name
%{python3_sitelib}/freecad/*
%if %{with tests}
%tests_resultdir/*
%endif
%{_bindir}/*
%{_metainfodir}/*
%dir %{_libdir}/%{name}
%{_libdir}/%{name}/bin/
%{_libdir}/%{name}/%{_lib}/
%{_libdir}/%{name}/Ext/
%{_libdir}/%{name}/Mod/
%{_datadir}/applications/*
%{_datadir}/icons/hicolor/scalable/*
%{_datadir}/pixmaps/*
%{_datadir}/mime/packages/*
%{_datadir}/thumbnailers/*
%{_libdir}/../lib/python*/site-packages/%{name}/*
%files data
%{_datadir}/%{name}/
%{_docdir}/%{name}/LICENSE.html
%{_docdir}/%{name}/ThirdPartyLibraries.html
%{_datadir}/%{name}/
%{_docdir}/%{name}/LICENSE.html
%{_docdir}/%{name}/ThirdPartyLibraries.html
%files libondselsolver-devel
%{_datadir}/pkgconfig/OndselSolver.pc
%{_includedir}/OndselSolver/*
%changelog
* Mon Mar 10 2025 Leif-Jöran Olsson <info@friprogramvarusyndikatet.se> - 1.1.0-1
- Adding support for building with Qt6 and PySide6 for Fedora 40+
-3
View File
@@ -1,3 +0,0 @@
[rpkg]
auto_pack = False
user_macros = "${git_props:root}/rpkg.macros"
+1
View File
@@ -0,0 +1 @@
1
+1
View File
@@ -0,0 +1 @@
!/.fmf/
+12
View File
@@ -0,0 +1,12 @@
/ctest :
test: |
cat /usr/share/freecad/tests_result/`uname -m`/ctest.result
if [ -f /usr/share/freecad/tests_result/`uname -m`/ctest.failed ]; then
exit 1
fi
/ctest_gui :
test: |
cat /usr/share/freecad/tests_result/`uname -m`/ctest_gui.result
if [ -f /usr/share/freecad/tests_result/`uname -m`/ctest_gui.failed ]; then
exit 1
fi
+42
View File
@@ -0,0 +1,42 @@
/tests:
/TestAssemblyWorkbench :
test: /usr/bin/FreeCADCmd -t TestAssemblyWorkbench
/TestArch :
test: /usr/bin/FreeCADCmd -t TestArch
/TestCAMApp :
test: /usr/bin/FreeCADCmd -t TestCAMApp
/TestDraft :
test: /usr/bin/FreeCADCmd -t TestDraft
/TestFemApp :
test: /usr/bin/FreeCADCmd -t TestFemApp
/TestMaterialsApp :
test: /usr/bin/FreeCADCmd -t TestMaterialsApp
/MeshTestsApp :
test: /usr/bin/FreeCADCmd -t MeshTestsApp
/TestPartApp :
test: /usr/bin/FreeCADCmd -t TestPartApp
/TestPartDesignApp :
test: /usr/bin/FreeCADCmd -t TestPartDesignApp
/TestSketcherApp :
test: /usr/bin/FreeCADCmd -t TestSketcherApp
/TestSpreadsheet :
test: /usr/bin/FreeCADCmd -t TestSpreadsheet
/TestSurfaceApp :
test: /usr/bin/FreeCADCmd -t TestSurfaceApp
/TestTechDrawApp :
test: /usr/bin/FreeCADCmd -t TestTechDrawApp
/BaseTests :
test: /usr/bin/FreeCADCmd -t BaseTests
/UnitTests :
test: /usr/bin/FreeCADCmd -t UnitTests
/Document :
test: /usr/bin/FreeCADCmd -t Document
/Metadata :
test: /usr/bin/FreeCADCmd -t Metadata
/StringHasher :
test: /usr/bin/FreeCADCmd -t StringHasher
/UnicodeTests :
test: /usr/bin/FreeCADCmd -t UnicodeTests
/TestPythonSyntax :
test: /usr/bin/FreeCADCmd -t TestPythonSyntax
+74
View File
@@ -0,0 +1,74 @@
/tests:
/TestAssemblyWorkbench :
test: xvfb-run /usr/bin/FreeCAD -t TestAssemblyWorkbench
/TestArch :
test: xvfb-run /usr/bin/FreeCAD -t TestArch
/TestCAMApp :
test: xvfb-run /usr/bin/FreeCAD -t TestCAMApp
/TestDraft :
test: xvfb-run /usr/bin/FreeCAD -t TestDraft
/TestFemApp :
test: xvfb-run /usr/bin/FreeCAD -t TestFemApp
/TestMaterialsApp :
test: xvfb-run /usr/bin/FreeCAD -t TestMaterialsApp
/MeshTestsApp :
test: xvfb-run /usr/bin/FreeCAD -t MeshTestsApp
/TestPartApp :
test: xvfb-run /usr/bin/FreeCAD -t TestPartApp
/TestPartDesignApp :
test: xvfb-run /usr/bin/FreeCAD -t TestPartDesignApp
/TestSketcherApp :
test: xvfb-run /usr/bin/FreeCAD -t TestSketcherApp
/TestSpreadsheet :
test: xvfb-run /usr/bin/FreeCAD -t TestSpreadsheet
/TestSurfaceApp :
test: xvfb-run /usr/bin/FreeCAD -t TestSurfaceApp
/TestTechDrawApp :
test: xvfb-run /usr/bin/FreeCAD -t TestTechDrawApp
/BaseTests :
test: xvfb-run /usr/bin/FreeCAD -t BaseTests
/UnitTests :
test: xvfb-run /usr/bin/FreeCAD -t UnitTests
/Document :
test: xvfb-run /usr/bin/FreeCAD -t Document
/Metadata :
test: xvfb-run /usr/bin/FreeCAD -t Metadata
/StringHasher :
test: xvfb-run /usr/bin/FreeCAD -t StringHasher
/UnicodeTests :
test: xvfb-run /usr/bin/FreeCAD -t UnicodeTests
/TestPythonSyntax :
test: xvfb-run /usr/bin/FreeCAD -t TestPythonSyntax
/TestArchGui :
test: xvfb-run /usr/bin/FreeCAD -t TestArchGui
/TestCAMGui :
test: xvfb-run /usr/bin/FreeCAD -t TestCAMGui
/TestDraftGui :
test: xvfb-run /usr/bin/FreeCAD -t TestDraftGui
/TestFemGui :
test: xvfb-run /usr/bin/FreeCAD -t TestFemGui
/TestImportGui :
test: xvfb-run /usr/bin/FreeCAD -t TestImportGui
/TestMaterialsGui :
test: xvfb-run /usr/bin/FreeCAD -t TestMaterialsGui
/TestOpenSCADGui :
test: xvfb-run /usr/bin/FreeCAD -t TestOpenSCADGui
/TestPartGui :
test: xvfb-run /usr/bin/FreeCAD -t TestPartGui
/TestPartDesignGui :
test: xvfb-run /usr/bin/FreeCAD -t TestPartDesignGui
/TestSketcherGui :
test: xvfb-run /usr/bin/FreeCAD -t TestSketcherGui
/TestTechDrawGui :
test: xvfb-run /usr/bin/FreeCAD -t TestTechDrawGui
/Workbench :
test: xvfb-run /usr/bin/FreeCAD -t Workbench
/Menu :
test: xvfb-run /usr/bin/FreeCAD -t Menu
/Menu.MenuDeleteCases :
test: xvfb-run /usr/bin/FreeCAD -t Menu.MenuDeleteCases
/Menu.MenuCreateCases :
test: xvfb-run /usr/bin/FreeCAD -t Menu.MenuCreateCases
/GuiDocument :
test: xvfb-run /usr/bin/FreeCAD -t GuiDocument
+10
View File
@@ -0,0 +1,10 @@
summary:
Run All FreeCAD python tests
prepare:
how: install
package:
- xorg-x11-server-Xvfb
discover:
how: fmf
execute:
how: tmt
+4
View File
@@ -0,0 +1,4 @@
summary: Run All FreeCADCmd python tests
test: /usr/bin/FreeCADCmd -v
require: /usr/bin/FreeCADCmd
duration: 1m
-1
View File
@@ -36,6 +36,5 @@ if %ERRORLEVEL% neq 0 exit 1
ninja -C build install
if %ERRORLEVEL% neq 0 exit 1
rmdir /s /q "%LIBRARY_PREFIX%\doc"
ren %LIBRARY_PREFIX%\bin\FreeCAD.exe freecad.exe
ren %LIBRARY_PREFIX%\bin\FreeCADCmd.exe freecadcmd.exe
+1 -1
View File
@@ -42,7 +42,7 @@ find . -name "*.pyc" -type f -delete
# see https://github.com/FreeCAD/FreeCAD/issues/10144#issuecomment-1836686775
# and https://github.com/FreeCAD/FreeCAD-Bundle/pull/203
# and https://github.com/FreeCAD/FreeCAD-Bundle/issues/375
python ../scripts/fix_macos_lib_paths.py ${conda_env}/lib
python ../scripts/fix_macos_lib_paths.py ${conda_env}/lib -r
# build and install the launcher
cmake -B build launcher
@@ -4,5 +4,7 @@
<dict>
<key>com.apple.security.cs.disable-library-validation</key>
<true/>
<key>com.apple.security.get-task-allow</key>
<true/>
</dict>
</plist>
File diff suppressed because it is too large Load Diff
+2 -5
View File
@@ -135,15 +135,12 @@ requirements:
- libspnav
- xorg-xproto
- if: osx
then:
- blas * accelerate*
run:
- blas
- blas * openblas*
- blinker
- calculix
- debugpy
- defusedxml
- docutils
- gmsh
- graphviz
@@ -73,14 +73,20 @@ def scan_directory(directory, recursive=False):
file_dir = os.path.dirname(full_path)
rpaths_processed = set()
for rpath in rpaths:
if rpath == "@loader_path":
rpath = "@loader_path/"
if os.path.isabs(rpath) and os.path.samefile(file_dir, rpath):
if scanmode:
print(f'\nFound absolute path in LC_RPATH: {rpath}\nIn: {full_path}')
else:
remove_rpath(full_path, rpath)
if rpath in rpaths_processed:
print(f'\nFound duplicate RPATH: {rpath}\nIn: {full_path}')
remove_rpath(full_path, rpath)
if scanmode:
print(f'\nFound duplicate RPATH: {rpath}\nIn: {full_path}')
else:
remove_rpath(full_path, rpath)
rpaths_processed.add(rpath)
for reexport_dylib in reexport_dylibs:
if os.path.isabs(reexport_dylib):
@@ -1,7 +1,7 @@
#!/bin/bash
set -e
set -x
set -x
conda_env="fc_env"
@@ -46,6 +46,8 @@ cp -a ${conda_env}/Library/data ${copy_dir}/data
cp -a ${conda_env}/Library/Ext ${copy_dir}/Ext
cp -a ${conda_env}/Library/lib ${copy_dir}/lib
cp -a ${conda_env}/Library/Mod ${copy_dir}/Mod
mkdir -p ${copy_dir}/doc
cp -a ${conda_env}/Library/doc/{ThirdPartyLibraries.html,LICENSE.html} ${copy_dir}/doc
rm -rf ${conda_env}/bin_tmp
# Apply Patches
+1
View File
@@ -53,6 +53,7 @@ packages=(
pyqt5-dev-tools
pyside2-tools
python3-dev
python3-defusedxml
python3-git
python3-markdown
python3-matplotlib
+16
View File
@@ -63,6 +63,7 @@ environments:
- conda: https://conda.anaconda.org/conda-forge/linux-64/dav1d-1.2.1-hd590300_0.conda
- conda: https://conda.anaconda.org/conda-forge/linux-64/dbus-1.16.2-h3c4dab8_0.conda
- conda: https://conda.anaconda.org/conda-forge/linux-64/debugpy-1.8.15-py311hc665b79_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/docutils-0.21.2-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/linux-64/double-conversion-3.3.1-h5888daf_0.conda
@@ -489,6 +490,7 @@ environments:
- conda: https://conda.anaconda.org/conda-forge/linux-aarch64/dav1d-1.2.1-h31becfc_0.conda
- conda: https://conda.anaconda.org/conda-forge/linux-aarch64/dbus-1.16.2-heda779d_0.conda
- conda: https://conda.anaconda.org/conda-forge/linux-aarch64/debugpy-1.8.15-py311h8e4e6a5_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/docutils-0.21.2-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/linux-aarch64/double-conversion-3.3.1-h5ad3122_0.conda
@@ -903,6 +905,7 @@ environments:
- conda: https://conda.anaconda.org/conda-forge/osx-64/dav1d-1.2.1-h0dc2134_0.conda
- conda: https://conda.anaconda.org/conda-forge/osx-64/dbus-1.16.2-h27bd348_0.conda
- conda: https://conda.anaconda.org/conda-forge/osx-64/debugpy-1.8.15-py311hc651eee_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/docutils-0.21.2-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/osx-64/double-conversion-3.3.1-h240833e_0.conda
@@ -1232,6 +1235,7 @@ environments:
- conda: https://conda.anaconda.org/conda-forge/osx-arm64/dav1d-1.2.1-hb547adb_0.conda
- conda: https://conda.anaconda.org/conda-forge/osx-arm64/dbus-1.16.2-hda038a8_0.conda
- conda: https://conda.anaconda.org/conda-forge/osx-arm64/debugpy-1.8.15-py311ha59bd64_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/docutils-0.21.2-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/osx-arm64/double-conversion-3.3.1-h286801f_0.conda
@@ -1544,6 +1548,7 @@ environments:
- conda: https://conda.anaconda.org/conda-forge/noarch/cycler-0.12.1-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/win-64/dav1d-1.2.1-hcfcfb64_0.conda
- conda: https://conda.anaconda.org/conda-forge/win-64/debugpy-1.8.15-py311h5dfdfe8_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
- conda: https://conda.anaconda.org/conda-forge/noarch/docutils-0.21.2-pyhd8ed1ab_1.conda
- conda: https://conda.anaconda.org/conda-forge/win-64/double-conversion-3.3.1-he0c23c2_0.conda
@@ -4622,6 +4627,17 @@ packages:
- pkg:pypi/debugpy?source=hash-mapping
size: 3932954
timestamp: 1752827138613
- conda: https://conda.anaconda.org/conda-forge/noarch/defusedxml-0.7.1-pyhd8ed1ab_0.tar.bz2
sha256: 9717a059677553562a8f38ff07f3b9f61727bd614f505658b0a5ecbcf8df89be
md5: 961b3a227b437d82ad7054484cfa71b2
depends:
- python >=3.6
license: PSF-2.0
license_family: PSF
purls:
- pkg:pypi/defusedxml?source=hash-mapping
size: 24062
timestamp: 1615232388757
- conda: https://conda.anaconda.org/conda-forge/noarch/distlib-0.4.0-pyhd8ed1ab_0.conda
sha256: 6d977f0b2fc24fee21a9554389ab83070db341af6d6f09285360b2e09ef8b26e
md5: 003b8ba0a94e2f1e117d0bd46aebc901
+1
View File
@@ -16,6 +16,7 @@ coin3d = "*"
compilers = ">=1.10,<1.11"
conda-devenv = "*"
debugpy = "*"
defusedxml = "*"
docutils = "*"
doxygen = "*"
eigen = "*"
-4
View File
@@ -1,4 +0,0 @@
function git_commit_no {
commits=$(curl -s 'https://api.github.com/repos/FreeCAD/FreeCAD/compare/120ca87015...main' | grep "\"ahead_by\":" | sed -s 's/ //g' | sed -s 's/"ahead_by"://' | sed -s 's/,//')
echo -n $((commits + 1))
}
+4
View File
@@ -133,6 +133,10 @@
typedef long int Py_hash_t;
#endif
#if PY_VERSION_HEX >= 0x030d0000
#define Py_UNICODE_DEPRECATED
#endif
#ifndef PYCXX_PYTHON_2TO3
#define PYCXX_PYTHON_2TO3
#endif
+14 -14
View File
@@ -1783,12 +1783,12 @@ namespace Py
// Python strings return strings as individual elements.
// I'll try having a class Char which is a String of length 1
//
#if !defined(Py_LIMITED_API)
#if !defined(Py_LIMITED_API) && !defined(Py_UNICODE_DEPRECATED)
typedef std::basic_string<Py_UNICODE> unicodestring;
extern Py_UNICODE unicode_null_string[1];
#endif
typedef std::basic_string<Py_UCS4> ucs4string;
extern Py_UCS4 ucs4_null_string[1];
typedef std::basic_string<char32_t> ucs4string;
extern char32_t ucs4_null_string[1];
class PYCXX_EXPORT Byte: public Object
{
@@ -1979,7 +1979,7 @@ namespace Py
validate();
}
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
Char( Py_UNICODE v )
: Object( PyUnicode_FromOrdinal( v ), true )
{
@@ -1987,7 +1987,7 @@ namespace Py
}
#endif
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
Char( const unicodestring &v )
: Object( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, const_cast<Py_UNICODE*>( v.data() ),1 ), true )
{
@@ -2008,7 +2008,7 @@ namespace Py
return *this;
}
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
Char &operator=( const unicodestring &v )
{
set( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, const_cast<Py_UNICODE*>( v.data() ), 1 ), true );
@@ -2016,7 +2016,7 @@ namespace Py
}
#endif
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
Char &operator=( int v_ )
{
Py_UNICODE v( v_ );
@@ -2025,7 +2025,7 @@ namespace Py
}
#endif
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
Char &operator=( Py_UNICODE v )
{
set( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, &v, 1 ), true );
@@ -2152,19 +2152,19 @@ namespace Py
// Need these c'tors becuase Py_UNICODE is 2 bytes
// User may use "int" or "unsigned int" as the unicode type
String( const unsigned int *s, int length )
: SeqBase<Char>( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const Py_UCS4 *>( s ), length ), true )
: SeqBase<Char>( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const char32_t *>( s ), length ), true )
{
validate();
}
String( const int *s, int length )
: SeqBase<Char>( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const Py_UCS4 *>( s ), length ), true )
: SeqBase<Char>( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const char32_t *>( s ), length ), true )
{
validate();
}
#endif
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
String( const Py_UNICODE *s, int length )
: SeqBase<Char>( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, s, length ), true )
{
@@ -2185,7 +2185,7 @@ namespace Py
return *this;
}
#if !defined( Py_LIMITED_API )
#if !defined( Py_LIMITED_API ) && !defined(Py_UNICODE_DEPRECATED)
String &operator=( const unicodestring &v )
{
set( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, const_cast<Py_UNICODE *>( v.data() ), v.length() ), true );
@@ -2196,7 +2196,7 @@ namespace Py
#if !defined( Py_UNICODE_WIDE ) && !defined( Py_LIMITED_API )
String &operator=( const ucs4string &v )
{
set( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const Py_UCS4 *>( v.data() ), v.length() ), true );
set( PyUnicode_FromKindAndData( PyUnicode_4BYTE_KIND, reinterpret_cast<const char32_t *>( v.data() ), v.length() ), true );
return *this;
}
#endif
@@ -2237,7 +2237,7 @@ namespace Py
{
ifPyErrorThrowCxxException();
}
ucs4string ucs4( buf, size() );
ucs4string ucs4( reinterpret_cast<char32_t *>(buf), size() );
delete[] buf;
return ucs4;
+2 -2
View File
@@ -45,10 +45,10 @@ Py_ssize_t numeric_limits_max()
return std::numeric_limits<Py_ssize_t>::max();
}
#if !defined(Py_LIMITED_API)
#if !defined(Py_LIMITED_API) && !defined(Py_UNICODE_DEPRECATED)
Py_UNICODE unicode_null_string[1] = { 0 };
#endif
Py_UCS4 ucs4_null_string[1] = { 0 };
char32_t ucs4_null_string[1] = { 0 };
Type Object::type() const
{
+1 -1
View File
@@ -40,7 +40,7 @@
#define PYCXX_VERSION_MAJOR 7
#define PYCXX_VERSION_MINOR 1
#define PYCXX_VERSION_PATCH 9
#define PYCXX_VERSION_PATCH 11
#define PYCXX_MAKEVERSION( major, minor, patch ) ((major<<16)|(minor<<8)|(patch))
#define PYCXX_VERSION PYCXX_MAKEVERSION( PYCXX_VERSION_MAJOR, PYCXX_VERSION_MINOR, PYCXX_VERSION_PATCH )
#endif
+2
View File
@@ -38,6 +38,8 @@
#ifndef __PyCXX_wrap_python_hxx__
#define __PyCXX_wrap_python_hxx__
#include <FCConfig.h>
// On some platforms we have to include time.h to get select defined
#if !defined(__WIN32__) && !defined(WIN32) && !defined(_WIN32) && !defined(_WIN64)
#include <sys/time.h>
+36 -30
View File
@@ -7,7 +7,7 @@ AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: Right
AlignOperands: true
AlignOperands: true
AlignTrailingComments: true
AllowAllArgumentsOnNextLine: true
AllowAllConstructorInitializersOnNextLine: true
@@ -24,19 +24,20 @@ AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: MultiLine
BinPackArguments: true
BinPackParameters: true
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
BitFieldColonSpacing: Both
BraceWrapping:
AfterCaseLabel: true
AfterClass: true
AfterControlStatement: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterStruct: true
AfterUnion: true
AfterEnum: true
AfterFunction: true
AfterNamespace: true
AfterStruct: true
AfterUnion: true
AfterExternBlock: true
BeforeCatch: true
BeforeElse: true
IndentBraces: false
BeforeCatch: true
BeforeElse: true
IndentBraces: false
SplitEmptyFunction: true
SplitEmptyRecord: true
SplitEmptyNamespace: true
@@ -48,28 +49,32 @@ BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: AfterColon
BreakStringLiterals: true
ColumnLimit: 120
CommentPragmas: '^ IWYU pragma:'
ColumnLimit: 100
CommentPragmas: '@copydetails '
CompactNamespaces: false
ConstructorInitializerAllOnOneLineOrOnePerLine: false
ConstructorInitializerIndentWidth: 3
ContinuationIndentWidth: 3
Cpp11BracedListStyle: false
DeriveLineEnding: false
DerivePointerAlignment: false
EmptyLineBeforeAccessModifier: LogicalBlock
EmptyLineAfterAccessModifier: Never
FixNamespaceComments: false
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
Priority: 3
- Regex: '.*'
Priority: 1
IncludeBlocks: Preserve
IncludeCategories:
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 2
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
Priority: 3
- Regex: '.*'
Priority: 1
IncludeIsMainRegex: '(Test)?$'
IndentCaseLabels: true
IndentPPDirectives: None
IndentWidth: 3
IndentWidth: 3
IndentWrappedFunctionNames: true
InsertBraces: true
KeepEmptyLinesAtTheStartOfBlocks: true
Language: Cpp
MaxEmptyLinesToKeep: 1
@@ -83,13 +88,14 @@ PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 1000
PointerAlignment: Right
ReflowComments: true
SortIncludes: true
ReflowComments: true
SortIncludes: true
SortUsingDeclarations: true
SpaceAfterCStyleCast: false
SpaceAfterLogicalNot: false
SpaceAfterTemplateKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceBeforeCaseColon: false
SpaceBeforeCpp11BracedList: false
SpaceBeforeCtorInitializerColon: true
SpaceBeforeInheritanceColon: true
@@ -97,12 +103,12 @@ SpaceBeforeParens: ControlStatements
SpaceBeforeRangeBasedForLoopColon: true
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: true
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 3
UseTab: Never
...
Standard: c++14
TabWidth: 3
UseCRLF: false
UseTab: Never
+135 -44
View File
@@ -4,67 +4,151 @@ on: [push, pull_request]
jobs:
build:
name: ${{ matrix.config.name }} (${{ matrix.build_type }})
runs-on: ${{ matrix.config.os }}
if: "!contains(github.event.head_commit.message, '[skip ci]')"
strategy:
fail-fast: false
matrix:
build_type: ["Debug", "Release"]
config:
- {
name: "macOS Clang",
os: macos-latest,
}
- {
name: "Ubuntu GCC",
os: ubuntu-latest,
}
- {
name: "Windows MSVC",
os: windows-latest,
}
include:
- name: 🍏 macOS (Clang - Debug)
os: macos-latest
platform: macos
build_type: Debug
build_shared: OFF
build_test: ON
validation_level: 2
- name: 🍏 macOS (Clang, no validation - Release)
os: macos-latest
platform: macos
build_type: Release
build_shared: OFF
build_test: ON
validation_level: 0 # build one with no validation
- name: 🍏 macOS (Clang, Shared - Release)
os: macos-latest
platform: macos
build_type: Release
build_shared: ON
build_test: ON
validation_level: 2
- name: 🐧 Linux (GCC - Debug)
os: ubuntu-latest
platform: linux
build_type: Debug
build_shared: OFF
build_test: ON
validation_level: 2
- name: 🐧 Linux (GCC, extra validation - Release)
os: ubuntu-latest
platform: linux
build_type: Release
build_shared: OFF
build_test: ON
validation_level: 1 # build one with basic validation
- name: 🐧 Linux (GCC, Shared - Release)
os: ubuntu-latest
platform: linux
build_type: Release
build_shared: ON
build_test: ON
validation_level: 2
- name: 🪟 Windows (MSVC - Debug)
os: windows-latest
platform: windows
arch: x86_64
build_type: Debug
build_debug: ON
build_shared: OFF
build_test: ON
validation_level: 2
- name: 🪟 Windows (MSVC [32-bit] - Debug)
os: windows-latest
platform: windows
arch: x86
build_type: Debug
build_debug: ON
build_shared: OFF
build_test: OFF
validation_level: 2
- name: 🪟 Windows (MSVC - Release)
os: windows-latest
platform: windows
arch: x86_64
build_type: Release
build_shared: OFF
build_test: ON
validation_level: 2
- name: 🪟 Windows (MSVC, Shared - Release)
os: windows-latest
platform: windows
arch: x86_64
build_type: Release
build_shared: ON
build_test: ON
validation_level: 2
name: ${{ matrix.name }}
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
submodules: recursive
- name: Checkout Test Data
uses: actions/checkout@v4
with:
repository: 'asmaloney/libE57Format-test-data'
path: libE57Format-test-data
- name: Install Dependencies (macOS)
if: matrix.config.os == 'macos-latest'
if: matrix.platform == 'macos'
run: |
brew install ninja xerces-c
brew install ccache ninja xerces-c
- name: Install Dependencies (Ubuntu)
if: matrix.config.os == 'ubuntu-latest'
- name: Install Dependencies (Linux)
if: matrix.platform == 'linux'
run: |
sudo apt-get update
sudo apt-get install -y libxerces-c-dev ninja-build
- name: Install miniconda (Windows)
if: matrix.config.os == 'windows-latest'
uses: conda-incubator/setup-miniconda@v2
with:
auto-update-conda: true
channels: conda-forge
miniconda-version: 'latest'
sudo apt-get install -y ccache libxerces-c-dev ninja-build
sudo locale-gen fr_FR
- name: Install Dependencies (Windows)
if: matrix.config.os == 'windows-latest'
if: matrix.platform == 'windows'
uses: conda-incubator/setup-miniconda@v3
with:
channels: conda-forge
- name: Install More Dependencies (Windows)
if: matrix.platform == 'windows'
shell: bash -el {0}
run: |
conda install -y ninja xerces-c
conda install conda-forge::xerces-c
choco upgrade ccache ninja
ccache --version | head -n 1
echo "ninja $(ninja --version)"
- name: ccache
uses: hendrikmuhs/ccache-action@v1
with:
max-size: '5G'
key: ${{ matrix.os }}-${{ matrix.build_type }}
- name: Configure MSVC console (Windows)
if: matrix.config.os == 'windows-latest'
if: matrix.platform == 'windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{ matrix.arch }}
- name: Set environment for MSVC (Windows)
if: matrix.config.os == 'windows-latest'
- name: Output conda info (Windows)
if: matrix.platform == 'windows'
run: |
# Set these env vars so cmake picks the correct compiler
echo "CXX=cl.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
echo "CC=cl.exe" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
conda info
conda list
conda config --show-sources
conda config --show
printenv | sort
- name: Configure
run: >
@@ -74,9 +158,16 @@ jobs:
-B libE57Format-build
-G "Ninja"
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
-DCMAKE_CXX_FLAGS_DEBUG="-g -DE57_MAX_VERBOSE"
-DE57_BUILD_SHARED=${{ matrix.build_shared }}
-DE57_BUILD_TEST=${{ matrix.build_test }}
-DE57_VALIDATION_LEVEL=${{ matrix.validation_level }}
-DE57FORMAT_WARNING_AS_ERROR:BOOL=ON
-DE57FORMAT_SANITIZE_ALL:BOOL=ON
.
- name: Build
run: |
cmake --build libE57Format-build
run: cmake --build libE57Format-build
- name: Test
if: matrix.build_test == 'ON'
run: libE57Format-build/testE57
@@ -0,0 +1,19 @@
name: C++ Code Format
on:
push:
pull_request:
branches:
- master
jobs:
formatting-check:
name: Formatting Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Run clang-format style check
uses: jidicula/clang-format-action@v4.15.0
with:
clang-format-version: '18'
exclude-regex: 'extern'
+3
View File
@@ -0,0 +1,3 @@
build
.vscode
.cache
-42
View File
@@ -1,42 +0,0 @@
dist: xenial
sudo: false
language: cpp
env:
global:
# For coverity
- secure: "Ddou0BLHkn4V8b/Q6E56lUVz4woSXS8eI0IzRxyYqkDvXtqqjSlxqtu2fuU/awieA6Y5rzEHZrpHnvJU80uC+gnlIfMkIU9O0Cj0rwppKTTTWpXzohrESfXzJc8iZs+3gxpReZhWp6IGrfitdudfpFAgLWBENgzemWsHy7prnDcQQA99FBUhCuhbqhtXRR8wxXUWNQr2RntbFbH22Eqcwbd5a+OYpPSCtV296ZII6/iskMI3OeXCEGnqKBxe2L9oohcrTS/0beCLM7dhCflelns8MTGa1AYmJEwXf3/n4PmwRo7EjTpSBow70n9SCps5mS42+wRDU8FMBTNgqzBNjOdDojrPhijnEPfhRzFygsyfgoEmuZjD2MuXBSIwpYa9mFusVpN2BON3zZLvmw5Y1HuBadf3yLoD0/Vy1K6YBnQRMIm5JhVYj4hY8ogtPNVfjYjckHEPlCRcwzS5rwh/sZ2eYW30LW3IusCB2wu3/iR97jamBu3sEOY67ln3M6EOjnMPHApBqsVhapQv+XtOtxaVPzKVc1u6tlzRRijPCfcN6ssNHzFh1feqFopthapY4erfA+DrjQivW+E49Yv306ig6HVBbrMkOR+TX+bgDmZisLtbJ8d2eym063KuojBRqDlq8wrz0MlUXVIz2H0FhXPIho8z9Uj7fkswM+jQiJc="
matrix:
- BUILD_TYPE=Debug
- BUILD_TYPE=Release
compiler:
- clang
- gcc
before_install:
- echo -n | openssl s_client -connect https://scan.coverity.com:443 | sed -ne '/-BEGIN CERTIFICATE-/,/-END CERTIFICATE-/p' | sudo tee -a /etc/ssl/certs/ca-
addons:
apt:
packages:
- libxerces-c-dev
coverity_scan:
project:
name: "asmaloney/libE57Format"
description: "Library for reading & writing the E57 file format (fork of E57RefImpl) "
notification_email: asmaloney@gmail.com
build_command_prepend: "cmake -DCMAKE_BUILD_TYPE=Debug ."
build_command: "make -j2"
branch_pattern: coverity_scan
before_script:
- mkdir build-${BUILD_TYPE}
- cd build-${BUILD_TYPE}
- cmake -DCMAKE_BUILD_TYPE=${BUILD_TYPE} -DCMAKE_CXX_FLAGS_DEBUG="-g -DE57_MAX_VERBOSE" ..
script:
- if [[ "${COVERITY_SCAN_BRANCH}" != 1 ]]; then
$CC_FOR_BUILD -v && $CXX_FOR_BUILD -v && cmake --version;
make -j2;
fi
+207 -4
View File
@@ -1,16 +1,219 @@
# Changelog
All notable changes to this project will be documented in this file.
All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## 3.3.0 - (in progress)
## 2.2.1 - (in progress)
### Added
- {cmake} Generate a package version file ([#316](https://github.com/asmaloney/libE57Format/pull/316)) (Thanks SunBlack!)
### Changed
- {cmake} Require XercesC 3.2 and remove `USING_STATIC_XERCES` ([#317](https://github.com/asmaloney/libE57Format/pull/317)) (Thanks SunBlack!)
### Fixed
- {cmake} Added missing include for GNUInstallDirs ([#315](https://github.com/asmaloney/libE57Format/pull/315)) (Thanks Adrian!)
If you built without testing on, the cmake files were not installed to the correct location.
## [3.2.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.2.0) - 2024-06-27
### Added
- {cmake} Added `E57_INSTALL_CMAKEDIR` option to override where the cmake files are installed. ([#305](https://github.com/asmaloney/libE57Format/pull/305))
This defaults to `lib/cmake/E57Format` and the path is relative to `CMAKE_INSTALL_PREFIX`.
### Changed
- {cmake} If building as a shared library, set [VERSION](https://cmake.org/cmake/help/v3.15/prop_tgt/VERSION.html) & [SOVERSION](https://cmake.org/cmake/help/v3.15/prop_tgt/SOVERSION.html). ([#304](https://github.com/asmaloney/libE57Format/pull/304))
- {cmake} Don't force warnings as errors when building self. ([#299](https://github.com/asmaloney/libE57Format/pull/299))
- {cmake} Use git tag in library version for more precision. ([#298](https://github.com/asmaloney/libE57Format/pull/298))
- {license} Re-license all my (asmaloney) MIT files to BSL-1.0. It is just easier to have it all under one license. ([#296](https://github.com/asmaloney/libE57Format/pull/296))
- {format} Update to clang-format 18 & reformat code. ([#286](https://github.com/asmaloney/libE57Format/pull/286))
- Add "E57\_" to macros in E57Exception.h. ([#285](https://github.com/asmaloney/libE57Format/pull/285))
- "De-deprecate" methods in **E57SimpleWriter**. These methods can be useful when writing batches. ([#284](https://github.com/asmaloney/libE57Format/pull/284))
### Fixed
- Update CRCpp to fix MSVC and MinGW warnings. ([#302](https://github.com/asmaloney/libE57Format/pull/302))
- Fix warnings about redefinition of `_LARGEFILE64_SOURCE` and `__LARGE64_FILES` ([#301](https://github.com/asmaloney/libE57Format/pull/301)) (Thanks Niklas!)
- Fix building with emscripten. (Note that the project doesn't officially support emscripten.) ([#288](https://github.com/asmaloney/libE57Format/pull/288)) (Thanks maz-1!)
- {standard conformance} CompressedVectors always write an index packet. This is required by the standard (9.3.5). ([#295](https://github.com/asmaloney/libE57Format/pull/295))
- {standard conformance} **E57SimpleReader** accepts files containing zero scans. ([#283](https://github.com/asmaloney/libE57Format/pull/283))
- {cmake} Replace deprecated "exec_program" with "execute_process". ([#282](https://github.com/asmaloney/libE57Format/pull/282))
- Fix potential invalid range exceptions when reading integer nodes. ([#278](https://github.com/asmaloney/libE57Format/pull/278))
## [3.1.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.1.1) - 2023-11-28
### Fixed
- Fix library version in CMakeLists.txt. (Thanks Olli!)
## [3.1.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.1.0) - 2023-11-20
### Added
- {cmake} New option `E57_RELEASE_LTO` controls whether link-time optimization is on for release builds. It defaults to `ON`. ([#254](https://github.com/asmaloney/libE57Format/pull/254))
CMake forces "thin" LTO (see [this issue](https://gitlab.kitware.com/cmake/cmake/-/issues/23136)) which is a problem if compiling statically for distribution (e.g. in a package manager). Generally you will only want to turn this off for distributing static release builds.
### Changed
- Trying to read a Data3D with zero records which has an ill-formed header will now throw an `ErrorData3DReadInvalidZeroRecords` exception instead of `ErrorInternal`. ([#264](https://github.com/asmaloney/libE57Format/pull/264))
> Note that previous versions of this library (and E57RefImpl itself) could write these headers incorrectly. This was also fixed in this release (see below).
- {cmake} Remove `E57_VISIBILITY_HIDDEN` option. ([#259](https://github.com/asmaloney/libE57Format/pull/259))
I cannot get extern templates to work across all of gcc, clang, apple clang, and MSVC when using "hidden" visibility with shared libraries.
### Fixed
- Fix #include to avoid MSVC compilation error with Visual Studio 2017 ([#268](https://github.com/asmaloney/libE57Format/pull/268)) (Thanks Thomas!)
- {standard conformance} A compressed vector with 0 records must still write a data packet. ([#266](https://github.com/asmaloney/libE57Format/pull/266))
- {standard conformance} Fix reading a compressed vector with 0 points which has an empty data packet. ([#267](https://github.com/asmaloney/libE57Format/pull/267))
- {standard conformance} Compressed vectors with an invalid section ID now throw an `ErrorBadCVPacket` exception if `E57_VALIDATION_LEVEL` > 0. ([#265](https://github.com/asmaloney/libE57Format/pull/265))
- Fix clang warnings about implicit conversions in _SourceDestBufferImpl.cpp_. Apple's clang doesn't warn about these, but it looks like the official clang releases do. ([#257](https://github.com/asmaloney/libE57Format/pull/257)) (Thanks Martin!)
## [3.0.2](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.2) - 2023-07-22
### Fixed
- Fix `E57_VERBOSE` build. ([#251](https://github.com/asmaloney/libE57Format/pull/251)) (Thanks Jia!)
- {standard conformance} Fix invalid range exception in FloatNode implementation. ([#250](https://github.com/asmaloney/libE57Format/pull/250))
- Fix reading of index packets. ([#249](https://github.com/asmaloney/libE57Format/pull/249))
- Fix several places where we should be checking for MSVC, not WIN32. ([#248](https://github.com/asmaloney/libE57Format/pull/248))
- Fix "unnecessary semicolons" warnings which prevented building with GCC <= 10. ([#241](https://github.com/asmaloney/libE57Format/pull/241)) (Thanks Andre!)
## [3.0.1](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.1) - 2023-03-15
### Added
- {ci} Added an MSVC 32-bit build. ([#235](https://github.com/asmaloney/libE57Format/pull/235))
### Fixed
- {cmake} Turn off inter-procedural optimization in debug builds. Link-time optimization can make debugging more difficult. ([#240](https://github.com/asmaloney/libE57Format/pull/240))
- {cmake} Don't force a debug postfix if `CMAKE_DEBUG_POSTFIX` is defined.([#239](https://github.com/asmaloney/libE57Format/pull/239))
- {cmake} Don't force install locations. This prevents overriding them using `CMAKE_INSTALL_BINDIR` & `CMAKE_INSTALL_LIBDIR`.([#237](https://github.com/asmaloney/libE57Format/pull/237))
- Fix warnings which prevented building on 32-bit systems. ([#233](https://github.com/asmaloney/libE57Format/pull/233), [#234](https://github.com/asmaloney/libE57Format/pull/234))
## [3.0.0](https://github.com/asmaloney/libE57Format/releases/tag/v3.0.0) - 2023-02-23
There have been _many_ changes around the `Simple API` in this release to fix some problems, avoid potential errors, and simplify the use of the API. Where possible these changes are marked as `deprecated` to be removed later. The compiler will produce warnings for these indicating what needs to change. Other changes could not be marked deprecated but will break the API, requiring code changes. The notable ones are marked with 🚧 below.
### Added
- Add address (ASan) and undefined behaviour (UBSan) sanitizers. These are controlled by `E57FORMAT_SANITIZE_ALL`, `E57FORMAT_SANITIZE_ADDRESS` and `E57FORMAT_SANITIZE_ADDRESS`. They are not included when building with MSVC.
- Add new `E57Version.h` header for more convenient access to version information. ([#197](https://github.com/asmaloney/libE57Format/pull/197)).
- Add `ImageFile::extensionsLookupPrefix()` overload for more concise user code. ([#161](https://github.com/asmaloney/libE57Format/pull/161))
- Added a constructor & destructor for **E57SimpleData**'s `Data3DPointsData_t`. This will create all the required buffers based on an `e57::Data3D` struct and handle their cleanup. See the `SimpleWriter` tests for examples. ([#149](https://github.com/asmaloney/libE57Format/pull/149))
> **Note:** I strongly recommend these new constructors be used to simplify your code and help prevent errors.
- A new **E57SimpleReader** constructor takes a `ReaderOptions` struct which allows setting the checksum policy.
```cpp
Reader( const ustring &filePath, const ReaderOptions &options );
```
- {test} Added testing using [GoogleTest](https://github.com/google/googletest). For details, please see [test/README.md](test/README.md) ([#121](https://github.com/asmaloney/libE57Format/pull/121))
- Added `E57Exception::errorStr()` to get the error string directly. ([#128](https://github.com/asmaloney/libE57Format/pull/128))
- {cmake} Use [ccache](https://ccache.dev/) if available. ([#129](https://github.com/asmaloney/libE57Format/pull/129))
- {ci} Added a CI check for proper clang-formatted code. ([#125](https://github.com/asmaloney/libE57Format/pull/125))
### Changed
- Now requires a **[C++14](https://en.cppreference.com/w/cpp/14)** compatible compiler.
- Now requires **[CMake](https://cmake.org/) >= 3.15**. ([#205](https://github.com/asmaloney/libE57Format/pull/205))
- 🚧 **DEBUG** and **VERBOSE** macros were changed to simplify and clarify:
- New `E57_ENABLE_DIAGNOSTIC_OUTPUT` controls the inclusion of the code for the `dump()` functions on nodes. I don't see any real reason to turn this off, but I left the capability in for compatibility.
- New `E57_VALIDATION_LEVEL=N` replaces `E57_DEBUG` (N=1) and `E57_MAX_DEBUG` (N=2).
- `E57_MAX_VERBOSE` was consolidated with `E57_VERBOSE` since they were essentially the same.
- When building itself, warnings are now treated as errors. ([#205](https://github.com/asmaloney/libE57Format/pull/205), [#211](https://github.com/asmaloney/libE57Format/pull/211))
- Clean up global const and enum names to use the `e57` namespace and avoid repetition. ([#176](https://github.com/asmaloney/libE57Format/pull/176))
- i.e. instead of `e57::E57_STRUCTURE`, we now use `e57::TypeStructure`
- {format} Update clang-format rules for clang-format 15. ([#168](https://github.com/asmaloney/libE57Format/pull/168), [#179](https://github.com/asmaloney/libE57Format/pull/179))
- Change default checksum policies to an enum. ([#166](https://github.com/asmaloney/libE57Format/pull/166))
Old | New
--|--
CHECKSUM_POLICY_NONE | ChecksumPolicy::None
CHECKSUM_POLICY_SPARSE | ChecksumPolicy::Sparse
CHECKSUM_POLICY_HALF | ChecksumPolicy::Half
CHECKSUM_POLICY_ALL | ChecksumPolicy::All
- Avoid implicit conversion in constructors. ([#135](https://github.com/asmaloney/libE57Format/pull/135))
- Update [CRCpp](https://github.com/d-bahr/CRCpp) to 1.2. ([#130](https://github.com/asmaloney/libE57Format/pull/130))
- **E57Exception** changes ([#118](https://github.com/asmaloney/libE57Format/pull/118)):
- mark methods as `noexcept`
- use `private` instead of `protected`
- Rename **E57Simple**'s `Data3DPointsData` and `Data3DPointsData_d` structs to `Data3DPointsFloat` and `Data3DPointsDouble` respectively. ([#180](https://github.com/asmaloney/libE57Format/pull/180))
- 🚧 **E57Simple:** Specifying the node type for cartesian & spherical points, time stamp, and intensity is now explicit using new fields (`pointRangeNodeType`, `angleNodeType`, `timeNodeType`, and `intensityNodeType`) and a new enum (`NumericalNodeType`). ([#178](https://github.com/asmaloney/libE57Format/pull/178))
- For examples, please see _test/src/testSimpleWriter.cpp_.
- Simplify the **E57SimpleWriter** API with `WriteImage2DData()` for images and `WriteData3DData()` for 3D data. This reduces code, hides complexity, and avoids potential errors. ([#171](https://github.com/asmaloney/libE57Format/pull/171))
- As part of this simplification, `WriteData3DData()` will now fill in any missing min/max values for cartesian & spherical points, intensity, and time stamps by looking at the data.([#175](https://github.com/asmaloney/libE57Format/pull/175))
- 🚧 **E57Simple:** Intensity now uses `double` instead of `float`. ([#178](https://github.com/asmaloney/libE57Format/pull/178))
- 🚧 **E57Simple:** Colours now use `uint16_t` instead of `uint8_t`. ([#167](https://github.com/asmaloney/libE57Format/pull/167))
- 🚧 Change **E57SimpleData**'s Data3D field name from `pointsSize` to `pointCount`. ([#164](https://github.com/asmaloney/libE57Format/pull/164))
- 🚧 Min/max fields in **E57SimpleData**'s Data3D's point fields were a mix of floats and doubles. Since the fields are doubles, set them all to doubles and use the new `Data3DPointsData_t` constructor to set them properly for floats. ([#153](https://github.com/asmaloney/libE57Format/pull/153))
> **Note:** If you were previously relying on these to be floats and are not using the new `Data3DPointsData_t` constructor, you will need to set these.
- 🚧 Renamed the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's fields in **E57SimpleData**'s `PointStandardizedFieldsAvailable` to be in line with existing code. ([#149](https://github.com/asmaloney/libE57Format/pull/149))
- `normalX` renamed to `normalXField`
- `normalY` renamed to `normalYField`
- `normalZ` renamed to `normalZField`
### Deprecated
- `e57::Utilities::getVersions()`. ([#197](https://github.com/asmaloney/libE57Format/pull/197))
- `e57::Data3DPointsData` and `e57::Data3DPointsData_d` types. ([#180](https://github.com/asmaloney/libE57Format/pull/180))
- Many global const and enum names. The compiler will produce warnings including the replacement symbols (note that enumerators will not produce warnings on C++14, but they will on C++17). ([#176](https://github.com/asmaloney/libE57Format/pull/176))
- `e57::Writer::NewImage2D`and `e57::Writer::SetUpData3DPointsData`. ([#171](https://github.com/asmaloney/libE57Format/pull/171))
- Old default checksum policies (`CHECKSUM_POLICY_NONE`, `CHECKSUM_POLICY_SPARSE`, `CHECKSUM_POLICY_HALF`, and `CHECKSUM_POLICY_ALL`). ([#166](https://github.com/asmaloney/libE57Format/pull/166))
- The old `e57::Reader` constructor taking only `filePath`. ([#139](https://github.com/asmaloney/libE57Format/pull/139))
- The old `e57::Writer` constructor taking only `filePath`. ([#117](https://github.com/asmaloney/libE57Format/pull/117))
### Fixed
- Fix several potential divide-by-zero cases. ([#224](https://github.com/asmaloney/libE57Format/pull/224))
- {ci} Now builds shared library versions as well. ([#219](https://github.com/asmaloney/libE57Format/pull/219))
- {win} Fixes shared library build warnings. ([#215](https://github.com/asmaloney/libE57Format/pull/215), [#216](https://github.com/asmaloney/libE57Format/pull/216), [#217](https://github.com/asmaloney/libE57Format/pull/217))
- Fix the code which shortens floating point numbers when converted to strings. The impact of it being incorrect was negligible since it's just the floating point representation in the XML portion of the file. ([#214](https://github.com/asmaloney/libE57Format/pull/214))
- Turned on a lot of compiler warnings and fixed them. ([#201](https://github.com/asmaloney/libE57Format/pull/201), [#202](https://github.com/asmaloney/libE57Format/pull/202), [#203](https://github.com/asmaloney/libE57Format/pull/203), [#204](https://github.com/asmaloney/libE57Format/pull/204), [#205](https://github.com/asmaloney/libE57Format/pull/205), [#207](https://github.com/asmaloney/libE57Format/pull/207), [#209](https://github.com/asmaloney/libE57Format/pull/209))
- Fix writing floating point numbers when `std::locale::global` is set. ([#174](https://github.com/asmaloney/libE57Format/pull/174))
- E57XmlParser: Parse doubles in a locale-independent way. ([#173](https://github.com/asmaloney/libE57Format/pull/173)) (Thanks Hugal31!)
- E57SimpleReader: Ensure scaled integer fields are set as best we can when reading. ([#158](https://github.com/asmaloney/libE57Format/pull/158))
- Fix the [E57_EXT_surface_normals](http://www.libe57.org/E57_EXT_surface_normals.txt) extension's URI in **E57SimpleWriter**. ([#143](https://github.com/asmaloney/libE57Format/pull/143))
- {win} Fix conversion warning when compiling with debug on. ([#124](https://github.com/asmaloney/libE57Format/pull/124))
- Add errno detail to `E57_ERROR_OPEN_FAILED` exception. ([#119](https://github.com/asmaloney/libE57Format/pull/119), [#120](https://github.com/asmaloney/libE57Format/pull/120))
## [2.3.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.3.0) - 2022-10-04
### Added
- {cmake} Added `E57_VISIBILITY_HIDDEN` option to control [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html). Defaults to `ON`. ([#104](https://github.com/asmaloney/libE57Format/pull/104)) (Thanks Nigel!)
- Added BSD support. ([#99](https://github.com/asmaloney/libE57Format/pull/99)) (Thanks Christophe!)
### Changed
- Updated &amp; reorganized the [online API docs](https://asmaloney.github.io/libE57Format-docs/) and changed to a [cleaner theme](https://github.com/jothepro/doxygen-awesome-css).
- Change file creation to use _0666_ permissions on [POSIX](https://en.wikipedia.org/wiki/POSIX) systems. ([#105](https://github.com/asmaloney/libE57Format/pull/105)) (Thanks Nigel!)
- {cmake} [CXX_VISIBILITY_PRESET](https://cmake.org/cmake/help/latest/prop_tgt/LANG_VISIBILITY_PRESET.html) is now set and `ON` by default. ([#104](https://github.com/asmaloney/libE57Format/pull/104)) (Thanks Nigel!)
- A new **E57SimpleWriter** constructor takes a `WriterOptions` struct which allows setting the file's GUID.
```cpp
Writer( const ustring &filePath, const WriterOptions &options );
```
The old constructor taking only `coordinateMetadata` is deprecated and will be removed in the future. ([#96](https://github.com/asmaloney/libE57Format/pull/96)) (Thanks Nigel!)
- Change `E57_DEBUG`, `E57_MAX_DEBUG`, `E57_VERBOSE`, `E57_MAX_VERBOSE`, `E57_WRITE_CRAZY_PACKET_MODE` from **#defines** to cmake options. ([#80](https://github.com/asmaloney/libE57Format/pull/80)) (Thanks Nigel!)
### Fixed
- Fix **E57SimpleWriter**'s writing of invalid quaternions. It now defaults to the identity quaternion. ([#108](https://github.com/asmaloney/libE57Format/pull/108)) (Thanks Nigel!)
- Fix **E57SimpleReader** to handle missing `images2D` and `isAtomicClockReferenced` nodes. ([#90](https://github.com/asmaloney/libE57Format/pull/90)) (Thanks Olli!)
- Fix **BitpackIntegerDecoder** sometimes reading past end of input buffer. ([#87](https://github.com/asmaloney/libE57Format/pull/87)) (Thanks Nigel!)
- Fix compilation when some debug options are set. ([#81](https://github.com/asmaloney/libE57Format/pull/81), [#82](https://github.com/asmaloney/libE57Format/pull/82), [#84](https://github.com/asmaloney/libE57Format/pull/84)) (Thanks Nigel!)
- Fix compilation with [musl libc](https://musl.libc.org/) ([#70](https://github.com/asmaloney/libE57Format/pull/70)) (Thanks Dimitri!)
- Add missing include for [GCC 11](https://gcc.gnu.org/gcc-11/porting_to.html#header-dep-changes) ([#68](https://github.com/asmaloney/libE57Format/pull/68)) (Thanks bartoszek!)
**Note:** The next release will be 3.0 and will require a [C++14](https://en.cppreference.com/w/cpp/14) compiler.
## [2.2.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.2.0) - 2021-04-01
### Added
@@ -35,7 +238,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
### Other
- Removed all internal usage of dynamic_cast<>. ([#39](https://github.com/asmaloney/libE57Format/pull/39)) (Thanks Jiri!)
- Split classes out from E57FormatImpl.[h,cpp] intot their own files.
- Split classes out from E57FormatImpl.[h,cpp] into their own files.
## [2.1.0](https://github.com/asmaloney/libE57Format/releases/tag/v2.1) - 2020-04-01
+142 -83
View File
@@ -3,8 +3,8 @@
#
# Use git blame to see all the changes and who has contributed.
#
# Copyright 2018-2023 Andy Maloney <asmaloney@gmail.com>
# Original work Copyright 2010-2012 Roland Schwarz, Riegl LMS GmbH
# Modified work Copyright 2018-2020 Andy Maloney <asmaloney@gmail.com>
#
# Permission is hereby granted, free of charge, to any person or organization
# obtaining a copy of the software and accompanying documentation covered by
@@ -28,10 +28,12 @@
# ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
cmake_minimum_required( VERSION 3.10.0 )
cmake_minimum_required( VERSION 3.15 )
# Set a private module find path
set( CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake/Modules/" )
set( CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_CURRENT_SOURCE_DIR}/cmake/" )
message( STATUS "Using CMake ${CMAKE_VERSION}" )
project( E57Format
DESCRIPTION
@@ -39,10 +41,20 @@ project( E57Format
LANGUAGES
CXX
VERSION
2.2.1
3.2.0
)
string( TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPERCASE )
# Creates a build tag which is used in the REVISION_ID
# e.g. "x86_64-darwin-AppleClang140"
include( Tags )
include( GitInfo )
# Collect all our current git info using:
# https://github.com/cppmf/GitInfo.cmake
GitInfo( ${CMAKE_CURRENT_SOURCE_DIR} )
# GitInfoReport()
# Check if we are building ourself or being included and use this to set some defaults
if ( ${PROJECT_NAME} STREQUAL ${CMAKE_PROJECT_NAME} )
@@ -65,7 +77,7 @@ if ( E57_BUILDING_SELF )
endif()
find_package( Threads REQUIRED )
find_package( XercesC REQUIRED )
find_package( XercesC 3.2 REQUIRED )
option( E57_BUILD_SHARED
"Compile E57Format as a shared library"
@@ -77,105 +89,116 @@ if( BUILD_SHARED_LIBS )
endif()
#########################################################################################
# Various levels of cross checking and verification in the code.
# Cross checking and runtime verification in the code.
# The extra code does not change the file contents.
# Recommend that E57_DEBUG remain defined even for production versions.
# E57_VALIDATION_LEVEL=0 off
# E57_VALIDATION_LEVEL=1 basic
# E57_VALIDATION_LEVEL=2 deep (implies basic) - checks at the packet level, so it will be slower
set( E57_VALIDATION_LEVEL "1" CACHE STRING "Runtime validation level (0 = OFF, 1 = basic, 2 = deep)" )
option( E57_DEBUG "Compile library with minimal debug checking" ON )
option( E57_MAX_DEBUG "Compile library with maximum debug checking" OFF )
# Output detailed logging while processing.
option( E57_VERBOSE "Compile library with verbose logging" OFF )
# Various levels of printing to the console of what is going on in the code.
# Optional
option( E57_VERBOSE "Compile library with verbose logging" OFF )
option( E57_MAX_VERBOSE "Compile library with maximum verbose logging" OFF )
# Enable/disable code which dumps detailed node info to std::ostream. (See NodeImpl::dump())
# Instead of always including this code, it is an option for backwards compatibility.
# The only real reason to turn this off would be for slightly smaller binaries.
option( E57_ENABLE_DIAGNOSTIC_OUTPUT "Include code for diagnostic output using dump() on nodes" ON )
# Enable writing packets that are correct but will stress the reader.
option( E57_WRITE_CRAZY_PACKET_MODE "Compile library to enable reader-stressing packets" OFF )
# Other compile options
# Link-time optiomization
# CMake forces "thin" LTO (see https://gitlab.kitware.com/cmake/cmake/-/issues/23136)
# which is a problem if compiling statically for distribution (e.g. in a package manager).
# Generally you will only want to turn this off for distributing static release builds.
option( E57_RELEASE_LTO "Compile release library with link-time optimization" ON )
#########################################################################################
set( revision_id "${PROJECT_NAME}-${PROJECT_VERSION}-${${PROJECT_NAME}_BUILD_TAG}" )
message( STATUS "[E57] Revision ID: ${revision_id}" )
# Need to explicitly set the source files to add_library()
if(${CMAKE_VERSION} VERSION_LESS "3.11.0")
file(GLOB E57Format_SOURCES src/[^.]*.cpp)
set( REVISION_ID "${PROJECT_NAME}-${PROJECT_VERSION}-${${PROJECT_NAME}_BUILD_TAG}" )
if ( GIT_LATEST_TAG )
set( REVISION_ID "${REVISION_ID} (git ${GIT_LATEST_TAG})" )
endif()
message( STATUS "[${PROJECT_NAME}] Revision ID: ${REVISION_ID}" )
# Target
if ( E57_BUILD_SHARED )
message( STATUS "[E57] Building shared library" )
message( STATUS "[${PROJECT_NAME}] Building shared library" )
add_library( E57Format SHARED ${E57Format_SOURCES})
else()
message( STATUS "[E57] Building static library" )
message( STATUS "[${PROJECT_NAME}] Building static library" )
add_library( E57Format STATIC ${E57Format_SOURCES})
endif()
include(CheckIPOSupported)
check_ipo_supported(RESULT ipo_ok OUTPUT ipo_msg)
if(NOT ipo_ok)
set(E57_RELEASE_LTO Off)
endif()
include( E57ExportHeader )
include( GitUpdate )
# Main sources and includes
add_subdirectory( extern/CRCpp )
add_subdirectory( include )
add_subdirectory( src )
include( ClangFormat )
# Target properties
set_target_properties( E57Format
PROPERTIES
CXX_STANDARD 11
CXX_STANDARD_REQUIRED YES
CXX_EXTENSIONS NO
DEBUG_POSTFIX "-d"
CXX_EXTENSIONS NO
EXPORT_COMPILE_COMMANDS ON
POSITION_INDEPENDENT_CODE ON
INTERPROCEDURAL_OPTIMIZATION ${E57_RELEASE_LTO}
INTERPROCEDURAL_OPTIMIZATION_DEBUG OFF
)
if ( NOT DEFINED CMAKE_DEBUG_POSTFIX )
set_target_properties( E57Format
PROPERTIES
DEBUG_POSTFIX "-d"
)
endif()
if ( E57_BUILD_SHARED )
set_target_properties( E57Format
PROPERTIES
VERSION ${PROJECT_VERSION}
SOVERSION ${PROJECT_VERSION_MAJOR}
)
endif()
target_compile_features( ${PROJECT_NAME}
PRIVATE
cxx_std_14
)
# Warnings
include( CompilerWarnings )
# Check our validation level
string( STRIP "${E57_VALIDATION_LEVEL}" E57_VALIDATION_LEVEL )
if ( NOT E57_VALIDATION_LEVEL MATCHES "^[0-2]$" )
message( FATAL_ERROR "[${PROJECT_NAME}] E57_VALIDATION_LEVEL should be 0-2: '${E57_VALIDATION_LEVEL}'" )
else()
message( STATUS "[${PROJECT_NAME}] Setting validation level to ${E57_VALIDATION_LEVEL}" )
endif ()
# Target definitions
target_compile_definitions( E57Format
PRIVATE
CRCPP_USE_CPP11
CRCPP_BRANCHLESS
REVISION_ID="${revision_id}"
REVISION_ID="${REVISION_ID}"
E57_VALIDATION_LEVEL=${E57_VALIDATION_LEVEL}
$<$<BOOL:${E57_ENABLE_DIAGNOSTIC_OUTPUT}>:E57_ENABLE_DIAGNOSTIC_OUTPUT>
$<$<BOOL:${E57_VERBOSE}>:E57_VERBOSE>
$<$<BOOL:${E57_WRITE_CRAZY_PACKET_MODE}>:E57_WRITE_CRAZY_PACKET_MODE>
)
if ( E57_DEBUG )
target_compile_definitions( E57Format PRIVATE E57_DEBUG )
endif()
if ( E57_MAX_DEBUG )
target_compile_definitions( E57Format PRIVATE E57_MAX_DEBUG )
endif()
if ( E57_VERBOSE )
target_compile_definitions( E57Format PRIVATE E57_VERBOSE )
endif()
if ( E57_MAX_VERBOSE )
target_compile_definitions( E57Format PRIVATE E57_MAX_VERBOSE )
endif()
if ( E57_WRITE_CRAZY_PACKET_MODE )
target_compile_definitions( E57Format PRIVATE E57_WRITE_CRAZY_PACKET_MODE )
endif()
if ( WIN32 )
option( USING_STATIC_XERCES "Turn on if you are linking with Xerces as a static lib" OFF )
if ( USING_STATIC_XERCES )
target_compile_definitions( E57Format
PUBLIC
XERCES_STATIC_LIBRARY
)
endif()
endif()
# Suppress all warnings for this specific 3rd-party target
target_compile_options(E57Format PRIVATE
$<$<CXX_COMPILER_ID:GNU,Clang>:-w>
$<$<CXX_COMPILER_ID:MSVC>:/w>
)
# sanitizers
include( Sanitizers )
# Target Libraries
target_link_libraries( E57Format PRIVATE XercesC::XercesC )
@@ -186,21 +209,57 @@ install(
E57Format
EXPORT
E57Format-export
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
)
# CMake package files
#install(
# EXPORT
# E57Format-export
# DESTINATION lib/cmake/E57Format
#)
# ccache
# Turns on ccache if found
include( ccache )
#install(
# FILES
# ${CMAKE_CURRENT_SOURCE_DIR}/cmake/e57format-config.cmake
# DESTINATION
# lib/cmake/E57Format
#)
# Formatting
include( ClangFormat )
# Testing
option( E57_BUILD_TEST
"Build tests"
${E57_BUILDING_SELF}
)
if ( E57_BUILD_TEST )
message( STATUS "[${PROJECT_NAME}] Testing enabled" )
enable_testing()
add_subdirectory( test )
endif()
# CMake package files
include( GNUInstallDirs )
set( E57_INSTALL_CMAKEDIR
"${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME}"
CACHE STRING
"Install path for ${PROJECT_NAME} CMake files"
)
message( STATUS "[${PROJECT_NAME}] CMake files install to ${CMAKE_INSTALL_PREFIX}/${E57_INSTALL_CMAKEDIR}" )
install(
EXPORT
E57Format-export
DESTINATION
"${E57_INSTALL_CMAKEDIR}"
)
include(CMakePackageConfigHelpers)
write_basic_package_version_file (
e57format-config-version.cmake
VERSION ${PROJECT_VERSION}
COMPATIBILITY SameMajorVersion
)
install(
FILES
${CMAKE_CURRENT_SOURCE_DIR}/cmake/e57format-config.cmake
${CMAKE_CURRENT_BINARY_DIR}/e57format-config-version.cmake
DESTINATION
"${E57_INSTALL_CMAKEDIR}"
)
+24 -8
View File
@@ -1,21 +1,37 @@
# How To Contribute
## Code Changes
These are some of the things you can do to contribute to the project:
## 💰 Financial
Given that I'm an independent developer without funding, financial support is appreciated. If you would like to support the project financially (especially if you sell a product which uses this library), you can use the [sponsors page](https://github.com/sponsors/asmaloney) for one-off or recurring support, or we can arrange <a href="mailto:asmaloney@gmail.com?subject=libE57Format B2B Sponsorship">B2B invoicing</a> of some kind. Thank you!
## ✍ Write About The Project
If you find the project useful, spread the word! Articles, mastodon posts, tweets, blog posts, instagram photos - whatever you're into. Please include a referral back to the repository page: https://github.com/asmaloney/libE57Format
## ⭐️ Add a Star
If you found this project useful, please consider starring it! It helps me gauge how useful this project is.
## ☝ Raise Issues
If you run into something which doesn't work as expected, raising [an issue](https://github.com/asmaloney/libE57Format/issues) with all the relevant information to reproduce it would be helpful.
## 🐞 Bug Fixes & 🧪 New Things
I am happy to review any [pull requests](https://github.com/asmaloney/libE57Format/pulls). Please keep them as short as possible. Each pull request should be atomic and only address one issue. This helps with the review process.
Note that I will not accept everything, but I welcome discussion. If you are proposing a big change, please raise it as [an issue](https://github.com/asmaloney/libE57Format/issues) first for discussion.
### Formatting
This project uses [clang-format](https://clang.llvm.org/docs/ClangFormat.html) to format the code. There is a cmake target (_format_) - which runs _clang-format_ on the source files. After changes have been made, and before you submit your pull request, please run the following:
This project uses [clang-format](https://clang.llvm.org/docs/ClangFormat.html) to format the code. There is a cmake target (_e57-clang-format_) - which runs _clang-format_ on the source files. After changes have been made, and before you submit your pull request, please run the following:
```sh
cmake --build . --target format
cmake --build . --target e57-clang-format
```
## Documentation
## 📖 Documentation
The [documentation](https://github.com/asmaloney/libE57Format) is a bit old and could use some lovin'. You can submit changes over in the [libE57Format-docs](https://github.com/asmaloney/libE57Format-docs) repository.
## Financial
If you would like to support the project financially, you can use the **Sponsor** button at the top of the [libE57Format](https://github.com/asmaloney/libE57Format) repository page.
+131 -25
View File
@@ -1,53 +1,159 @@
# libE57Format
[![Build Status](https://travis-ci.org/asmaloney/libE57Format.svg?branch=master)](https://travis-ci.org/asmaloney/libE57Format)
[![GitHub release (latest by date)](https://img.shields.io/github/v/release/asmaloney/libE57Format)](https://github.com/asmaloney/libE57Format/releases/latest) [![Docs](https://img.shields.io/badge/docs-online-orange)](https://asmaloney.github.io/libE57Format-docs/) [![GitHub](https://img.shields.io/github/license/asmaloney/libE57Format)](LICENSE) ![Build](https://github.com/asmaloney/libE57Format/actions/workflows/build.yml/badge.svg)
A library to provide read & write support for the E57 file format.
This is a fork of [E57RefImpl](https://sourceforge.net/projects/e57-3d-imgfmt/) v1.1.332. The original source is from [E57RefImpl 1.1.332](https://sourceforge.net/projects/e57-3d-imgfmt/files/E57Refimpl-src/) and then everything was stripped out except the main implementation for reading and writing E57.
This version also removes the dependency on [Boost](https://www.boost.org/) and requires C++11.
Many, many other changes were made prior to the first release of this fork. See the [CHANGELOG](CHANGELOG.md) and git history for details.
libE57Format is a C++ library which provides read & write support for the ASTM-standard [E57 file format](https://www.astm.org/e2807-11r19e01.html) on Linux, macOS, and Windows. E57 files store 3D point cloud data (produced by 3D imaging systems such as laser scanners), attributes associated with 3D point data (color & intensity), and 2D images (photos taken using a 3D imaging system).
## Documentation
The doxygen-generated documentation may be [found here](https://asmaloney.github.io/libE57Format-docs/). These docs are generated and saved in the [libE57Format-docs](https://github.com/asmaloney/libE57Format-docs) repo.
## Contributing
## Commercial Use
Please see [CONTRIBUTING](CONTRIBUTING.md).
If you are using this library in commercial software, please [contribute to the project](/CONTRIBUTING.md).
## Why Fork?
Of course the open source license allows you to just take and not give anything back. It is perfectly Legal, but it is not Right and it's not good for the project.
The E57RefImpl code hasn't been touched in years and I wanted to make changes to compile this library with macOS. Forking it gives me a bit more freedom to update the code and make changes as required.
Over the many years I've worked on this library, I have received precisely _zero_ contributions (PRs, documentation updates, improved testing, financial support) from the many million/billion-dollar companies who use it in their software.
I changed the name of the project so that it is not confused with the **E57RefImpl** project.
The more companies that leech on Open Source instead of nurturing it, the less healthy & viable the ecosystem is.
I have also changed the main include file's name from `E57Foundation.h` to `E57Format.h` to make sure there is no inclusion confusion.
## Requirements
Versions of **libE57Format** started at 2.0.
- a [C++14](https://en.cppreference.com/w/cpp/14) compatible compiler
- [CMake](https://cmake.org/) >= 3.15
- [clang-format](https://clang.llvm.org/docs/ClangFormat.html) for code formatting
- (_optional_) [ccache](https://ccache.dev/) to speed up rebuilds
## Dependencies
- [Xerces-C++](https://xerces.apache.org/xerces-c/) (for parsing XML)
### Installing Dependencies On Linux (Ubuntu)
```sh
$ sudo apt install libxerces-c-dev clang-format
```
### Installing Dependencies On macOS (homebrew)
```sh
$ brew install ccache clang-format xerces-c
```
## Build, Install, & Test
Here's how you build & install a release version with the defaults:
```
$ cmake -B E57-build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=E57-install libE57Format
$ cmake --build E57-build --parallel
$ cmake --install E57-build
```
If CMake can't find the xerces-c library, you can set [CMAKE_PREFIX_PATH](https://cmake.org/cmake/help/latest/variable/CMAKE_PREFIX_PATH.html) to point at it.
```
$ cmake -B E57-build \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=E57-install \
-DCMAKE_PREFIX_PATH=/path/to/xerces-c \
libE57Format
```
Once the library is built, you can run the tests like this:
```
$ cd E57-build
$ ./test/testE57
[==========] Running 36 tests from 8 test suites.
[----------] Global test environment set-up.
[----------] 1 test from TestData
[ RUN ] TestData.RepoExists
...
```
See [test/README](test/README.md) for details about testing and the test data.
## 🍴 Fork (2018)
This is a fork of [E57RefImpl](https://sourceforge.net/projects/e57-3d-imgfmt/). The original source is from [E57RefImpl 1.1.332](https://sourceforge.net/projects/e57-3d-imgfmt/files/E57Refimpl-src/).
The original code had not been touched in several years and I wanted to make changes to compile it on macOS. Forking it gave me more freedom to update the code and make changes as required. Everything was stripped out except the main implementation for reading & writing E57 files.
- I changed the name of the project so that it is not confused with the **E57RefImpl** project.
- I changed the main include file's name from `E57Foundation.h` to `E57Format.h` to make sure there is no inclusion confusion.
- Versions of **libE57Format** started at 2.0.
- I fixed it to compile and run on macOS.
- It no longer depends on [Boost](https://www.boost.org/).
- It now requires [C++14](https://en.cppreference.com/w/cpp/14). (Version 2.x required [C++11](https://en.cppreference.com/w/cpp/11).)
Many, many other changes were made prior to the first release of this fork, and it has diverged significantly since. See the [CHANGELOG](CHANGELOG.md) and git history for details.
### E57Simple API
Since the original fork, [Jiri Hörner](https://github.com/ptc-jhoerner) has added the E57Simple API from the old reference implementation and updated it.
[Jiri Hörner](https://github.com/ptc-jhoerner) added the E57Simple API from the old reference implementation and updated it.
### Tools
This _Simple API_ has evolved since this original port to fix some problems and to make it more foolproof & easier to use. Please see the [CHANGELOG](CHANGELOG.md) for version 3.
[Ryan Baumann](https://github.com/ryanfb) has updated the `e57unpack` and `e57validate` tools to work with **libE57Format**. You can find them in the [e57tools](https://github.com/ryanfb/e57tools) repo.
## Projects Using libE57Format
- [AliceVision](https://github.com/alicevision/AliceVision)
- [CloudCompare](https://github.com/CloudCompare/CloudCompare)
- [MeshLab](https://github.com/cnr-isti-vclab/meshlab)
- [pye57](https://github.com/davidcaron/pye57)
These projects use hard forks of libE57Format:
- [FreeCAD](https://github.com/FreeCAD/FreeCAD)
- [PDAL](https://github.com/PDAL/PDAL)
There are also many commercial products using libE57Format. If any of them would like to sponsor the project and be listed here, please <a href="mailto:asmaloney@gmail.com?subject=libE57Format Sponsorship">contact Andy</a>.
## How To Contribute
These are some of the things you can do to contribute to the project:
### 💰 Financial
Given that I'm an independent developer without funding, financial support is appreciated. If you would like to support the project financially (especially if you sell a product which uses this library), you can use the [sponsors page](https://github.com/sponsors/asmaloney) for one-off or recurring support, or we can arrange <a href="mailto:asmaloney@gmail.com?subject=libE57Format B2B Sponsorship">B2B invoicing</a> of some kind. Thank you!
### ✍ Write About The Project
If you find the project useful, spread the word! Articles, mastodon posts, tweets, blog posts, instagram photos - whatever you're into. Please include a referral back to the repository page: https://github.com/asmaloney/libE57Format
### ⭐️ Add a Star
If you found this project useful, please consider starring it! It helps me gauge how useful this project is.
### ☝ Raise Issues
If you run into something which doesn't work as expected, raising [an issue](https://github.com/asmaloney/libE57Format/issues) with all the relevant information to reproduce it would be helpful.
### 🐞 Bug Fixes & 🧪 New Things
I am happy to review any [pull requests](https://github.com/asmaloney/libE57Format/pulls). Please keep them as short as possible. Each pull request should be atomic and only address one issue. This helps with the review process.
Note that I will not accept everything, but I welcome discussion. If you are proposing a big change, please raise it as [an issue](https://github.com/asmaloney/libE57Format/issues) first for discussion.
#### Formatting
This project uses [clang-format](https://clang.llvm.org/docs/ClangFormat.html) to format the code. There is a cmake target (_e57-clang-format_) - which runs _clang-format_ on the source files. After changes have been made, and before you submit your pull request, please run the following:
```sh
cmake --build . --target e57-clang-format
```
### 📖 Documentation
The [documentation](https://github.com/asmaloney/libE57Format) is a bit old and could use some lovin'. You can submit changes over in the [libE57Format-docs](https://github.com/asmaloney/libE57Format-docs) repository.
## License
This project as a whole is licensed under the [**BSL-1.0**](https://opensource.org/licenses/BSL-1.0) license - see the [LICENSE](LICENSE.md) file for details.
This project is licensed under the [**BSL-1.0** license](https://opensource.org/licenses/BSL-1.0) - see the [LICENSE](LICENSE.md) file for details.
Individual source files may contain the following tag instead of the full license text:
SPDX-License-Identifier: BSL-1.0
Some CMake files are licensed under the **MIT** license - see the [LICENSE-MIT](LICENSE-MIT.txt) file for details.
These files contain the following tag instead of the full license text:
SPDX-License-Identifier: MIT
Using SPDX enables machine processing of license information based on the [SPDX License Identifiers](https://spdx.org/ids) and makes it easier for developers to see at a glance which license they are dealing with.
+32
View File
@@ -0,0 +1,32 @@
# SPDX-License-Identifier: BSL-1.0
# Copyright 2020 Andy Maloney <asmaloney@gmail.com>
find_program( E57_CLANG_FORMAT_PROGRAM NAMES clang-format )
if ( E57_CLANG_FORMAT_PROGRAM )
message( STATUS "[${PROJECT_NAME}] Using clang-format: ${E57_CLANG_FORMAT_PROGRAM}" )
get_target_property( e57_sources ${PROJECT_NAME} SOURCES )
# Remove some files from the list
list( FILTER e57_sources EXCLUDE REGEX ".*/E57Export.h" )
list( FILTER e57_sources EXCLUDE REGEX ".*/extern/.*" )
# Get list of test files. We cannot use get_target_property here
# since we will not have a target if E57_BUILD_TEST is off.
file( GLOB e57_test_sources
LIST_DIRECTORIES false
CONFIGURE_DEPENDS
${PROJECT_SOURCE_DIR}/test/include/*.h
${PROJECT_SOURCE_DIR}/test/src/*.cpp
)
list( APPEND e57_sources ${e57_test_sources} )
add_custom_target( e57-clang-format
COMMAND ${E57_CLANG_FORMAT_PROGRAM} --style=file -i ${e57_sources}
COMMENT "Running clang-format..."
COMMAND_EXPAND_LISTS
VERBATIM
)
endif()
+112
View File
@@ -0,0 +1,112 @@
# SPDX-License-Identifier: BSL-1.0
# Copyright 2022 Andy Maloney <asmaloney@gmail.com>
string( TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPERCASE )
if ( NOT MSVC )
option( ${PROJECT_NAME_UPPERCASE}_WARN_EVERYTHING "Turn on all warnings (not recommended - used for lib development)" OFF )
endif()
option( ${PROJECT_NAME_UPPERCASE}_WARNING_AS_ERROR "Treat warnings as errors" OFF )
# Set some helper variables for readability
set( compiler_is_clang "$<OR:$<CXX_COMPILER_ID:AppleClang>,$<CXX_COMPILER_ID:Clang>>" )
set( compiler_is_gnu "$<CXX_COMPILER_ID:GNU>" )
set( compiler_is_msvc "$<CXX_COMPILER_ID:MSVC>" )
target_compile_options( ${PROJECT_NAME}
PRIVATE
# MSVC only
$<${compiler_is_msvc}:
/W4
/w14263 # 'function': member function does not override any base class virtual member function
/w14296 # 'operator': expression is always 'boolean_value'
/w14311 # 'variable': pointer truncation from 'type1' to 'type2'
/w14545 # expression before comma evaluates to a function which is missing an argument list
/w14546 # function call before comma missing argument list
/w14547 # 'operator': operator before comma has no effect; expected operator with side-effect
/w14549 # 'operator': operator before comma has no effect; did you intend 'operator'?
/w14619 # pragma warning: there is no warning number 'number'
/w14640 # thread un-safe static member initialization
/w14905 # wide string literal cast to 'LPSTR'
/w14906 # string literal cast to 'LPWSTR'
/wd4251 # 'type' : class 'type1' needs to have dll-interface to be used by clients of class 'type2'
>
# Clang and GNU common options
$<$<OR:${compiler_is_clang},${compiler_is_gnu}>:
-Wall
-Wcast-align
-Wextra
-Wformat=2
-Wnon-virtual-dtor
-Wnull-dereference
-Woverloaded-virtual
-Wpedantic
-Wshadow
-Wunused
>
# Clang only
$<${compiler_is_clang}:
-Wdocumentation
-Wno-documentation-deprecated-sync # because enumerator [[deprecated]] attribute is C++17
>
# GNU only
$<${compiler_is_gnu}:
-Wduplicated-branches
-Wduplicated-cond
-Wlogical-op
>
)
# Turn on (almost) all warnings on Clang, Apple Clang, and GNU.
# Useful for internal development, but too noisy for general development.
function( set_warn_everything )
message( STATUS "[${PROJECT_NAME}] Turning on (almost) all warnings")
target_compile_options( ${PROJECT_NAME}
PRIVATE
# Clang and GNU
$<$<OR:${compiler_is_clang},${compiler_is_gnu}>:
-Weverything
-Wno-c++98-compat
-Wno-c++98-compat-pedantic
-Wno-padded
>
# Clang only
$<${compiler_is_clang}:
-Wno-documentation-deprecated-sync # because enumerator [[deprecated]] attribute is C++17
>
)
endfunction()
if ( NOT MSVC AND ${PROJECT_NAME_UPPERCASE}_WARN_EVERYTHING )
set_warn_everything()
endif()
# Treat warnings as errors
function( set_warning_as_error )
message( STATUS "[${PROJECT_NAME}] Treating warnings as errors")
if ( CMAKE_VERSION VERSION_GREATER_EQUAL "3.24" )
set_target_properties( ${PROJECT_NAME}
PROPERTIES
COMPILE_WARNING_AS_ERROR ON
)
else()
# This will do nothing on compilers other than MSVC, Clang, Apple Clang, and GNU compilers.
target_compile_options( ${PROJECT_NAME}
PRIVATE
$<${compiler_is_msvc}:
/WX
>
$<$<OR:${compiler_is_clang},${compiler_is_gnu}>:
-Werror
>
)
endif()
endfunction()
if ( ${PROJECT_NAME_UPPERCASE}_WARNING_AS_ERROR )
set_warning_as_error()
endif()
@@ -1,11 +1,13 @@
# SPDX-License-Identifier: MIT
# SPDX-License-Identifier: BSL-1.0
# Copyright 2020 Andy Maloney <asmaloney@gmail.com>
# Generate the export header file for E57Format
include( GenerateExportHeader )
set( comment "// NOTE: This is a generated file. Any changes will be overwritten." )
set( comment "\r
// NOTE: This is a generated file. Any changes will be overwritten."
)
generate_export_header( E57Format
EXPORT_FILE_NAME E57Export.h
+122
View File
@@ -0,0 +1,122 @@
# ---------------------------------------------------------------------------- #
#
# Copyright (c) 2020 C++ Modern Framework
#
# https://github.com/cppmf/GitInfo.cmake
#
# ---------------------------------------------------------------------------- #
# Modified June 2024 - Andy Maloney <asmaloney@gmail.com>
# - remove some vars we aren't using
# - fix spelling/grammar
# ---------------------------------------------------------------------------- #
#
# Following variables will be set when calling GitInfo
#
# GIT_DIR: path to the project .git directory
# GIT_IS_DIRTY: whether or not the working tree is dirty
# GIT_HEAD_BRANCH : name of the branch associated to HEAD
# GIT_REVISION_HASH: current HEAD sha hash
# GIT_REVISION: short version of GIT_REVISION_HASH
# GIT_REVISION_NAME: name associated to GIT_REVISION_HASH
# GIT_REMOTE_ORIGIN_URL : origin remote url
# GIT_LATEST_TAG_LONG : most recent tag of the current branch
# GIT_LATEST_TAG : most recent tagname of the current branch
#
# ---------------------------------------------------------------------------- #
# This is the main function to call in project CMakeLists.txt
# source should point to the root project directory
function(GitInfo source)
# Check is source is a valid path
if(NOT EXISTS ${source})
message(FATAL_ERROR "'${source}' is not a valid path")
endif()
# Define the possible location of the .git directory
set(GIT_DIR "${source}/.git")
# Check if .git folder exist
if(EXISTS ${GIT_DIR})
#
set(GIT_DIR "${GIT_DIR}" CACHE PATH "Project .git directory")
# Check if git is installed
if(NOT GIT_FOUND)
find_package(Git QUIET)
endif()
if(NOT GIT_FOUND)
message(AUTHOR_WARNING "Git not found, cannot get git information")
return()
endif()
# name of the branch associated to HEAD
execute_process(COMMAND ${GIT_EXECUTABLE} rev-parse --abbrev-ref HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_HEAD_BRANCH OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_HEAD_BRANCH "${GIT_HEAD_BRANCH}" CACHE INTERNAL "name of the branch associated to HEAD")
# git revision full hash
execute_process(COMMAND ${GIT_EXECUTABLE} show -s "--format=%H" HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_REVISION_HASH OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_REVISION_HASH "${GIT_REVISION_HASH}" CACHE INTERNAL "git revision full hash")
# short version of git revision
execute_process(COMMAND ${GIT_EXECUTABLE} show -s "--format=%h" HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_REVISION OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_REVISION "${GIT_REVISION}" CACHE INTERNAL "short version of git revision")
# short version of git revision name
execute_process(COMMAND ${GIT_EXECUTABLE} show -s "--format=%s" HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_REVISION_NAME OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_REVISION_NAME "${GIT_REVISION_NAME}" CACHE INTERNAL "short version of git revision name")
# origin remote url
execute_process(COMMAND ${GIT_EXECUTABLE} config --get remote.origin.url
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_REMOTE_ORIGIN_URL OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_REMOTE_ORIGIN_URL "${GIT_REMOTE_ORIGIN_URL}" CACHE INTERNAL "git origin remote url")
# most recent tag of the current branch
execute_process(COMMAND ${GIT_EXECUTABLE} describe --tags --abbrev=0 HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_LATEST_TAG_LONG OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_LATEST_TAG_LONG "${GIT_LATEST_TAG_LONG}" CACHE INTERNAL "git most recent tag of the current branch")
# most recent tagname of the current branch
execute_process(COMMAND ${GIT_EXECUTABLE} describe --tags HEAD
WORKING_DIRECTORY ${source}
OUTPUT_VARIABLE GIT_LATEST_TAG OUTPUT_STRIP_TRAILING_WHITESPACE)
set(GIT_LATEST_TAG "${GIT_LATEST_TAG}" CACHE INTERNAL "git most recent tagname of the current branch")
endif()
endfunction()
# Report git information
function(GitInfoReport)
message(STATUS "")
message(STATUS "----------------------------------------------------")
message(STATUS " GitInfo.cmake")
message(STATUS "")
message(STATUS "GIT_DIR : ${GIT_DIR}")
message(STATUS "")
message(STATUS "GIT_HEAD_BRANCH : ${GIT_HEAD_BRANCH}")
message(STATUS "GIT_REVISION : ${GIT_REVISION}")
message(STATUS "GIT_REVISION_HASH : ${GIT_REVISION_HASH}")
message(STATUS "GIT_REVISION_NAME : ${GIT_REVISION_NAME}")
message(STATUS "")
message(STATUS "GIT_REMOTE_ORIGIN_URL : ${GIT_REMOTE_ORIGIN_URL}")
message(STATUS "GIT_LATEST_TAG_LONG : ${GIT_LATEST_TAG_LONG}")
message(STATUS "GIT_LATEST_TAG : ${GIT_LATEST_TAG}")
message(STATUS "")
message(STATUS "----------------------------------------------------")
message(STATUS "")
endfunction()
+22
View File
@@ -0,0 +1,22 @@
find_package( Git QUIET )
if ( GIT_FOUND AND EXISTS "${PROJECT_SOURCE_DIR}/.git" )
# Update submodules as needed
option( E57_GIT_SUBMODULE_UPDATE "Check submodules and update during build" ON )
if ( E57_GIT_SUBMODULE_UPDATE )
message( STATUS "Submodule update using git (${GIT_EXECUTABLE})" )
message( STATUS "Submodule update directory: ${CMAKE_CURRENT_SOURCE_DIR}" )
execute_process( COMMAND ${GIT_EXECUTABLE} submodule update --init --recursive
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
RESULT_VARIABLE GIT_SUBMOD_RESULT
ERROR_VARIABLE GIT_SUBMOD_RESULT)
if ( GIT_SUBMOD_RESULT EQUAL "0" )
message( STATUS "Submodule update complete" )
else()
message( FATAL_ERROR "Submodule update failed with ${GIT_SUBMOD_RESULT}, please checkout submodules" )
endif()
endif()
endif()
@@ -1,19 +0,0 @@
# SPDX-License-Identifier: MIT
# Copyright 2020 Andy Maloney <asmaloney@gmail.com>
find_program( E57_CLANG_FORMAT_EXE NAMES clang-format )
if ( E57_CLANG_FORMAT_EXE )
get_target_property( e57_sources ${PROJECT_NAME} SOURCES )
# Remove some files from the list
list( FILTER e57_sources EXCLUDE REGEX ".*/E57Export.h" )
list( FILTER e57_sources EXCLUDE REGEX ".*/extern/.*" )
add_custom_target( format
COMMAND clang-format --style=file -i ${e57_sources}
COMMENT "Running clang-format..."
COMMAND_EXPAND_LISTS
VERBATIM
)
endif()
-41
View File
@@ -1,41 +0,0 @@
# This file defines the variables
# ${PROJECT_NAME}_BUILD_TAG
# calculate the tag
set(T_ ${CMAKE_SYSTEM_PROCESSOR})
if (CMAKE_CL_64)
set(T_ ${T_}_64)
endif (CMAKE_CL_64)
string(TOLOWER ${CMAKE_SYSTEM_NAME} T1_)
set(T_ ${T_}-${T1_})
if (MSVC90)
set(T1_ "-vc90")
elseif (MSVC10)
set(T1_ "-vc100")
elseif (MSVC80)
set(T1_ "-vc80")
elseif (MSVC71)
set(T1_ "-vc711")
elseif (MSVC70)
set(T1_ "-vc7")
elseif (MINGW)
set(T1_ "-mgw")
exec_program(${CMAKE_CXX_COMPILER}
ARGS ${CMAKE_CXX_COMPILER_ARG1} -dumpversion
OUTPUT_VARIABLE T2_
)
string(REGEX REPLACE "([0-9])\\.([0-9])(\\.[0-9])?" "\\1\\2" T2_ ${T2_})
set(T1_ ${T1_}${T2_})
elseif (CMAKE_COMPILER_IS_GNUCXX)
set(T1_ "-gcc")
exec_program(${CMAKE_CXX_COMPILER}
ARGS ${CMAKE_CXX_COMPILER_ARG1} -dumpversion
OUTPUT_VARIABLE T2_
)
string(REGEX REPLACE "([0-9])\\.([0-9])(\\.[0-9])?" "\\1\\2" T2_ ${T2_})
set(T1_ ${T1_}${T2_})
else()
set(T1_)
endif()
set(T_ ${T_}${T1_})
set(${PROJECT_NAME}_BUILD_TAG ${T_})
+93
View File
@@ -0,0 +1,93 @@
# SPDX-License-Identifier: BSL-1.0
# Copyright 2023 Andy Maloney <asmaloney@gmail.com>
# Note: In theory address sanitization should work on MSVC, but I could not get it working.
# If you know how to fix it, please submit a PR:
# https://github.com/asmaloney/libE57Format/pulls
string( TOUPPER ${PROJECT_NAME} PROJECT_NAME_UPPERCASE )
set( compiler_is_clang "$<OR:$<CXX_COMPILER_ID:AppleClang>,$<CXX_COMPILER_ID:Clang>>" )
set( compiler_is_gnu "$<CXX_COMPILER_ID:GNU>" )
set( compiler_is_msvc "$<CXX_COMPILER_ID:MSVC>" )
set( compiler_is_not_msvc "$<NOT:${compiler_is_msvc}>" )
if ( NOT MSVC )
option( ${PROJECT_NAME_UPPERCASE}_SANITIZE_ALL "Enable all sanitizers if available." OFF )
option( ${PROJECT_NAME_UPPERCASE}_SANITIZE_ADDRESS "Enable address sanitizer (ASan) if available." OFF )
option( ${PROJECT_NAME_UPPERCASE}_SANITIZE_UNDEFINED "Enable memory sanitizer (UBSan) if available." OFF )
endif()
function( enable_address_sanitizer target )
message( STATUS "[${target}] Enabling address sanitizer (ASan)" )
target_compile_options( ${target}
PRIVATE
$<${compiler_is_not_msvc}:
-fno-omit-frame-pointer
-fsanitize=address
>
$<${compiler_is_msvc}:
/fsanitize=address
/INCREMENTAL:NO
/Zi
>
)
target_link_options( ${target}
PUBLIC
$<${compiler_is_not_msvc}:
-fno-omit-frame-pointer
-fsanitize=address
>
$<${compiler_is_msvc}:
/DEBUG
/INCREMENTAL:NO
>
)
endfunction()
function( enable_undefined_sanitizer target )
if ( MSVC )
message( WARNING "[${target}] Undefined behaviour sanitizer (UBSan) not available for MSVC" )
return()
endif()
message( STATUS "[${target}] Enabling undefined behaviour sanitizer (UBSan)" )
target_compile_options( ${target}
PRIVATE
-fsanitize=undefined
)
target_link_options( ${target}
PUBLIC
-fsanitize=undefined
)
endfunction()
function( enable_all_sanitizers target )
if ( MSVC )
return()
endif()
unset( ${PROJECT_NAME_UPPERCASE}_SANITIZE_ADDRESS CACHE )
unset( ${PROJECT_NAME_UPPERCASE}_SANITIZE_UNDEFINED CACHE )
enable_address_sanitizer( ${target} )
enable_undefined_sanitizer( ${target} )
endfunction()
if ( NOT MSVC )
if ( ${PROJECT_NAME_UPPERCASE}_SANITIZE_ALL )
enable_all_sanitizers( ${PROJECT_NAME} )
else()
if ( ${PROJECT_NAME_UPPERCASE}_SANITIZE_ADDRESS )
enable_address_sanitizer( ${PROJECT_NAME} )
endif()
if ( ${PROJECT_NAME_UPPERCASE}_SANITIZE_UNDEFINED )
enable_undefined_sanitizer( ${PROJECT_NAME} )
endif()
endif()
endif()
+39
View File
@@ -0,0 +1,39 @@
# This file defines the variables
# ${PROJECT_NAME}_BUILD_TAG
set( T_ ${CMAKE_SYSTEM_PROCESSOR} )
string( TOLOWER ${CMAKE_SYSTEM_NAME} T1_ )
function( add_compiler_version )
execute_process(
COMMAND ${CMAKE_CXX_COMPILER} ${CMAKE_CXX_COMPILER_ARG1} -dumpversion
OUTPUT_VARIABLE T2_
)
string( REGEX REPLACE "([0-9])\\.([0-9])(\\.[0-9])?" "\\1\\2" T2_ ${T2_} )
string( STRIP ${T2_} T2_ )
set( T1_ ${T1_}${T2_} PARENT_SCOPE )
endfunction()
# default to just the CMake compiler ID
set( T1_ ${CMAKE_CXX_COMPILER_ID} )
# special cases to add versions and other info
if ( MSVC )
if ( CMAKE_CL_64 )
set( T_ ${T_}_64 )
endif()
set( T1_ "vc${MSVC_VERSION}" )
elseif ( MINGW )
set( T1_ "MinGW" )
add_compiler_version()
elseif ( CMAKE_CXX_COMPILER_ID STREQUAL "GNU" )
set( T1_ "gcc" )
add_compiler_version()
elseif ( CMAKE_CXX_COMPILER_ID MATCHES "Clang")
add_compiler_version()
endif()
set( T_ ${T_}-${T1_} )
set( ${PROJECT_NAME}_BUILD_TAG ${T_} )
+15
View File
@@ -0,0 +1,15 @@
# SPDX-License-Identifier: BSL-1.0
# Copyright 2022 Andy Maloney <asmaloney@gmail.com>
# See: https://crascit.com/2016/04/09/using-ccache-with-cmake/
find_program( CCACHE_PROGRAM ccache )
if ( CCACHE_PROGRAM )
message( STATUS "[${PROJECT_NAME}] Using ccache: ${CCACHE_PROGRAM}" )
set_target_properties( ${PROJECT_NAME}
PROPERTIES
CXX_COMPILER_LAUNCHER "${CCACHE_PROGRAM}"
C_COMPILER_LAUNCHER "${CCACHE_PROGRAM}"
)
endif()
+9 -3
View File
@@ -1,14 +1,20 @@
# SPDX-License-Identifier: MIT
# SPDX-License-Identifier: BSL-1.0
# Copyright © Andy Maloney <asmaloney@gmail.com>
# CRCpp from here: https://github.com/d-bahr/CRCpp
target_compile_definitions( ${PROJECT_NAME}
PRIVATE
CRCPP_USE_CPP11
CRCPP_BRANCHLESS
)
target_sources( ${PROJECT_NAME}
PRIVATE
${CMAKE_CURRENT_LIST_DIR}/inc/CRC.h
inc/CRC.h
)
target_include_directories( ${PROJECT_NAME}
PRIVATE
${CMAKE_CURRENT_LIST_DIR}/inc
inc
)
+1 -1
View File
@@ -1,5 +1,5 @@
CRC++
Copyright (c) 2016, Daniel Bahr
Copyright (c) 2022, Daniel Bahr
All rights reserved.
Redistribution and use in source and binary forms, with or without
+68 -1
View File
@@ -82,7 +82,24 @@ int main(int argc, char ** argv)
This will return the same CRC as the first example.
Both of the above examples compute a CRC bit-by-bit. However, CRC++ also supports lookup tables, as the following example demonstrates:
If you need to compute a CRC on an input that is not a multiple of `CHAR_BIT` (usually 8 bits), use the `CalculateBits()` function instead:
```cpp
int main(int argc, char ** argv)
{
const unsigned char data[] = { 0x98, 0x76, 0x54, 0x32, 0x10 };
// Second argument is the number of bits. The input data must
// be a whole number of bytes. Pad any used bits with zeros.
std::uint32_t crc = CRC::CalculateBits(data, 37, CRC::CRC_32());
std::cout << std::hex << crc;
return 0;
}
```
The above examples compute a CRC bit-by-bit. However, CRC++ also supports lookup tables, as the following example demonstrates:
```cpp
int main(int argc, char ** argv)
@@ -149,6 +166,56 @@ Define to enables C++11 features (move semantics, constexpr, static_assert, etc.
* `#define CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS`
Define to include definitions for little-used CRCs. Not defined by default.
### Build
CRC does not require a build for basic usage; simply include the header file in your project.
Unit tests and documentation can be built manually with the project files provided or automatically with CMake.
To build documentation manually:
```bash
cd doxygen
doxygen Doxyfile.dox
```
To build unit tests manually via Make:
```bash
# Build
cd test/prj/gcc
make [debug|release]
# Run unit tests
bin/unittest
```
Project files and solutions for Visual Studio 2015, 2017 and 2022 are provided in `test/prj`. Simply open the solution file and run the project; no additional configuration should be necessary.
CMake can also be used to build the documentation and unit tests. An out-of-source build is recommended. In this example, we will do an out-of-source build in the `build` directory:
```bash
mkdir -p build
cd build
cmake .. [-DBUILD_DOC=ON]
# Build and run unit tests
make tests
# Build documentation
make doxygen
# Install header file
sudo make install
```
Unit tests are built by default. Enable the `BUILD_DOC` CMake flag to also build documentation (requires [Doxygen](https://www.doxygen.nl/index.html)).
### Documentation
https://d-bahr.github.io/CRCpp/
### License
CRC++ is free to use and provided under a BSD license.
### References
Catalog of CRCs: https://reveng.sourceforge.io/crc-catalogue/
5G-NR Specification 3GPP TS 38.212: https://www.etsi.org/deliver/etsi_ts/138200_138299/138212/15.03.00_60/ts_138212v150300p.pdf
USB 2.0 Specification: https://www.usb.org/document-library/usb-20-specification
+471 -60
View File
@@ -1,11 +1,11 @@
/**
@file CRC.h
@author Daniel Bahr
@version 0.2.0.6
@version 1.2.0.0
@copyright
@parblock
CRC++
Copyright (c) 2016, Daniel Bahr
Copyright (c) 2022, Daniel Bahr
All rights reserved.
Redistribution and use in source and binary forms, with or without
@@ -52,7 +52,7 @@
multiplication in the bit-by-bit calculation instead of a small conditional. The branchless implementation
may be faster on processor architectures which support single-instruction integer multiplication.
#define CRCPP_USE_CPP11 - Define to enables C++11 features (move semantics, constexpr, static_assert, etc.).
#define CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS - Define to include definitions for little-used CRCs.
#define CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS - Define to include definitions for little-used CRCs.
*/
#ifndef CRCPP_CRC_H_
@@ -127,6 +127,12 @@
# define crcpp_constexpr const
#endif
#if defined(_MSC_VER) && !defined(__clang__) && !defined(__INTEL_COMPILER)
/* Disable warning C4127: conditional expression is constant. */
#pragma warning(push)
#pragma warning(disable : 4127)
#endif
#ifdef CRCPP_USE_NAMESPACE
namespace CRCPP
{
@@ -202,6 +208,18 @@ public:
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType Calculate(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable, CRCType crc);
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateBits(const void * data, crcpp_size size, const Parameters<CRCType, CRCWidth> & parameters);
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateBits(const void * data, crcpp_size size, const Parameters<CRCType, CRCWidth> & parameters, CRCType crc);
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateBits(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable);
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateBits(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable, CRCType crc);
// Common CRCs up to 64 bits.
// Note: Check values are the computed CRCs when given an ASCII input of "123456789" (without null terminator)
#ifdef CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
@@ -212,16 +230,20 @@ public:
static const Parameters< crcpp_uint8, 6> & CRC_6_CDMA2000A();
static const Parameters< crcpp_uint8, 6> & CRC_6_CDMA2000B();
static const Parameters< crcpp_uint8, 6> & CRC_6_ITU();
static const Parameters< crcpp_uint8, 6> & CRC_6_NR();
static const Parameters< crcpp_uint8, 7> & CRC_7();
#endif
static const Parameters< crcpp_uint8, 8> & CRC_8();
#ifdef CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
static const Parameters< crcpp_uint8, 8> & CRC_8_EBU();
static const Parameters< crcpp_uint8, 8> & CRC_8_HDLC();
static const Parameters< crcpp_uint8, 8> & CRC_8_MAXIM();
static const Parameters< crcpp_uint8, 8> & CRC_8_WCDMA();
static const Parameters< crcpp_uint8, 8> & CRC_8_LTE();
static const Parameters<crcpp_uint16, 10> & CRC_10();
static const Parameters<crcpp_uint16, 10> & CRC_10_CDMA2000();
static const Parameters<crcpp_uint16, 11> & CRC_11();
static const Parameters<crcpp_uint16, 11> & CRC_11_NR();
static const Parameters<crcpp_uint16, 12> & CRC_12_CDMA2000();
static const Parameters<crcpp_uint16, 12> & CRC_12_DECT();
static const Parameters<crcpp_uint16, 12> & CRC_12_UMTS();
@@ -232,8 +254,10 @@ public:
static const Parameters<crcpp_uint16, 16> & CRC_16_ARC();
static const Parameters<crcpp_uint16, 16> & CRC_16_BUYPASS();
static const Parameters<crcpp_uint16, 16> & CRC_16_CCITTFALSE();
static const Parameters<crcpp_uint16, 16> & CRC_16_MCRF4XX();
#ifdef CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
static const Parameters<crcpp_uint16, 16> & CRC_16_CDMA2000();
static const Parameters<crcpp_uint16, 16> & CRC_16_CMS();
static const Parameters<crcpp_uint16, 16> & CRC_16_DECTR();
static const Parameters<crcpp_uint16, 16> & CRC_16_DECTX();
static const Parameters<crcpp_uint16, 16> & CRC_16_DNP();
@@ -254,6 +278,9 @@ public:
static const Parameters<crcpp_uint32, 24> & CRC_24();
static const Parameters<crcpp_uint32, 24> & CRC_24_FLEXRAYA();
static const Parameters<crcpp_uint32, 24> & CRC_24_FLEXRAYB();
static const Parameters<crcpp_uint32, 24> & CRC_24_LTEA();
static const Parameters<crcpp_uint32, 24> & CRC_24_LTEB();
static const Parameters<crcpp_uint32, 24> & CRC_24_NRC();
static const Parameters<crcpp_uint32, 30> & CRC_30();
#endif
static const Parameters<crcpp_uint32, 32> & CRC_32();
@@ -299,8 +326,8 @@ private:
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateRemainder(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable, CRCType remainder);
template <typename IntegerType>
static crcpp_constexpr IntegerType BoundedConstexprValue(IntegerType x);
template <typename CRCType, crcpp_uint16 CRCWidth>
static CRCType CalculateRemainderBits(unsigned char byte, crcpp_size numBits, const Parameters<CRCType, CRCWidth> & parameters, CRCType remainder);
};
/**
@@ -320,13 +347,13 @@ inline CRC::Table<CRCType, CRCWidth> CRC::Parameters<CRCType, CRCWidth>::MakeTab
/**
@brief Constructs a CRC table from a set of CRC parameters
@param[in] parameters CRC parameters
@param[in] params CRC parameters
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRC::Table<CRCType, CRCWidth>::Table(const Parameters<CRCType, CRCWidth> & parameters) :
parameters(parameters)
inline CRC::Table<CRCType, CRCWidth>::Table(const Parameters<CRCType, CRCWidth> & params) :
parameters(params)
{
InitTable();
}
@@ -334,13 +361,13 @@ inline CRC::Table<CRCType, CRCWidth>::Table(const Parameters<CRCType, CRCWidth>
#ifdef CRCPP_USE_CPP11
/**
@brief Constructs a CRC table from a set of CRC parameters
@param[in] parameters CRC parameters
@param[in] params CRC parameters
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRC::Table<CRCType, CRCWidth>::Table(Parameters<CRCType, CRCWidth> && parameters) :
parameters(::std::move(parameters))
inline CRC::Table<CRCType, CRCWidth>::Table(Parameters<CRCType, CRCWidth> && params) :
parameters(::std::move(params))
{
InitTable();
}
@@ -395,7 +422,8 @@ inline void CRC::Table<CRCType, CRCWidth>::InitTable()
static crcpp_constexpr CRCType BIT_MASK((CRCType(1) << (CRCWidth - CRCType(1))) |
((CRCType(1) << (CRCWidth - CRCType(1))) - CRCType(1)));
static crcpp_constexpr CRCType SHIFT(CRC::BoundedConstexprValue(CHAR_BIT - CRCWidth));
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CHAR_BIT >= CRCWidth) ? static_cast<CRCType>(CHAR_BIT - CRCWidth) : 0);
CRCType crc;
unsigned char byte = 0;
@@ -414,7 +442,7 @@ inline void CRC::Table<CRCType, CRCWidth>::InitTable()
{
// Undo the special operation at the end of the CalculateRemainder()
// function for non-reflected CRCs < CHAR_BIT.
crc <<= SHIFT;
crc = static_cast<CRCType>(crc << SHIFT);
}
table[byte] = crc;
@@ -425,7 +453,7 @@ inline void CRC::Table<CRCType, CRCWidth>::InitTable()
/**
@brief Computes a CRC.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] parameters CRC parameters
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@@ -444,7 +472,7 @@ inline CRCType CRC::Calculate(const void * data, crcpp_size size, const Paramete
@brief Appends additional data to a previous CRC calculation.
@note This function can be used to compute multi-part CRCs.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] parameters CRC parameters
@param[in] crc CRC from a previous calculation
@tparam CRCType Integer type for storing the CRC result
@@ -466,7 +494,7 @@ inline CRCType CRC::Calculate(const void * data, crcpp_size size, const Paramete
/**
@brief Computes a CRC via a lookup table.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] lookupTable CRC lookup table
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@@ -488,7 +516,7 @@ inline CRCType CRC::Calculate(const void * data, crcpp_size size, const Table<CR
@brief Appends additional data to a previous CRC calculation using a lookup table.
@note This function can be used to compute multi-part CRCs.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] lookupTable CRC lookup table
@param[in] crc CRC from a previous calculation
@tparam CRCType Integer type for storing the CRC result
@@ -509,6 +537,149 @@ inline CRCType CRC::Calculate(const void * data, crcpp_size size, const Table<CR
return Finalize<CRCType, CRCWidth>(remainder, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
}
/**
@brief Computes a CRC.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data, in bits
@param[in] parameters CRC parameters
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@return CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRCType CRC::CalculateBits(const void * data, crcpp_size size, const Parameters<CRCType, CRCWidth> & parameters)
{
CRCType remainder = parameters.initialValue;
// Calculate the remainder on a whole number of bytes first, then call
// a special-case function for the remaining bits.
crcpp_size wholeNumberOfBytes = size / CHAR_BIT;
if (wholeNumberOfBytes > 0)
{
remainder = CalculateRemainder(data, wholeNumberOfBytes, parameters, remainder);
}
crcpp_size remainingNumberOfBits = size % CHAR_BIT;
if (remainingNumberOfBits != 0)
{
unsigned char lastByte = *(reinterpret_cast<const unsigned char *>(data) + wholeNumberOfBytes);
remainder = CalculateRemainderBits(lastByte, remainingNumberOfBits, parameters, remainder);
}
// No need to mask the remainder here; the mask will be applied in the Finalize() function.
return Finalize<CRCType, CRCWidth>(remainder, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
}
/**
@brief Appends additional data to a previous CRC calculation.
@note This function can be used to compute multi-part CRCs.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data, in bits
@param[in] parameters CRC parameters
@param[in] crc CRC from a previous calculation
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@return CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRCType CRC::CalculateBits(const void * data, crcpp_size size, const Parameters<CRCType, CRCWidth> & parameters, CRCType crc)
{
CRCType remainder = UndoFinalize<CRCType, CRCWidth>(crc, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
// Calculate the remainder on a whole number of bytes first, then call
// a special-case function for the remaining bits.
crcpp_size wholeNumberOfBytes = size / CHAR_BIT;
if (wholeNumberOfBytes > 0)
{
remainder = CalculateRemainder(data, wholeNumberOfBytes, parameters, parameters.initialValue);
}
crcpp_size remainingNumberOfBits = size % CHAR_BIT;
if (remainingNumberOfBits != 0)
{
unsigned char lastByte = *(reinterpret_cast<const unsigned char *>(data) + wholeNumberOfBytes);
remainder = CalculateRemainderBits(lastByte, remainingNumberOfBits, parameters, remainder);
}
// No need to mask the remainder here; the mask will be applied in the Finalize() function.
return Finalize<CRCType, CRCWidth>(remainder, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
}
/**
@brief Computes a CRC via a lookup table.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data, in bits
@param[in] lookupTable CRC lookup table
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@return CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRCType CRC::CalculateBits(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable)
{
const Parameters<CRCType, CRCWidth> & parameters = lookupTable.GetParameters();
CRCType remainder = parameters.initialValue;
// Calculate the remainder on a whole number of bytes first, then call
// a special-case function for the remaining bits.
crcpp_size wholeNumberOfBytes = size / CHAR_BIT;
if (wholeNumberOfBytes > 0)
{
remainder = CalculateRemainder(data, wholeNumberOfBytes, lookupTable, remainder);
}
crcpp_size remainingNumberOfBits = size % CHAR_BIT;
if (remainingNumberOfBits != 0)
{
unsigned char lastByte = *(reinterpret_cast<const unsigned char *>(data) + wholeNumberOfBytes);
remainder = CalculateRemainderBits(lastByte, remainingNumberOfBits, parameters, remainder);
}
// No need to mask the remainder here; the mask will be applied in the Finalize() function.
return Finalize<CRCType, CRCWidth>(remainder, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
}
/**
@brief Appends additional data to a previous CRC calculation using a lookup table.
@note This function can be used to compute multi-part CRCs.
@param[in] data Data over which CRC will be computed
@param[in] size Size of the data, in bits
@param[in] lookupTable CRC lookup table
@param[in] crc CRC from a previous calculation
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@return CRC
*/
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRCType CRC::CalculateBits(const void * data, crcpp_size size, const Table<CRCType, CRCWidth> & lookupTable, CRCType crc)
{
const Parameters<CRCType, CRCWidth> & parameters = lookupTable.GetParameters();
CRCType remainder = UndoFinalize<CRCType, CRCWidth>(crc, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
// Calculate the remainder on a whole number of bytes first, then call
// a special-case function for the remaining bits.
crcpp_size wholeNumberOfBytes = size / CHAR_BIT;
if (wholeNumberOfBytes > 0)
{
remainder = CalculateRemainder(data, wholeNumberOfBytes, lookupTable, parameters.initialValue);
}
crcpp_size remainingNumberOfBits = size % CHAR_BIT;
if (remainingNumberOfBits > 0)
{
unsigned char lastByte = *(reinterpret_cast<const unsigned char *>(data) + wholeNumberOfBytes);
remainder = CalculateRemainderBits(lastByte, remainingNumberOfBits, parameters, remainder);
}
// No need to mask the remainder here; the mask will be applied in the Finalize() function.
return Finalize<CRCType, CRCWidth>(remainder, parameters.finalXOR, parameters.reflectInput != parameters.reflectOutput);
}
/**
@brief Reflects (i.e. reverses the bits within) an integer value.
@param[in] value Value to reflect
@@ -523,8 +694,8 @@ inline IntegerType CRC::Reflect(IntegerType value, crcpp_uint16 numBits)
for (crcpp_uint16 i = 0; i < numBits; ++i)
{
reversedValue = (reversedValue << 1) | (value & 1);
value >>= 1;
reversedValue = static_cast<IntegerType>((reversedValue << 1) | (value & 1));
value = static_cast<IntegerType>(value >> 1);
}
return reversedValue;
@@ -591,7 +762,7 @@ inline CRCType CRC::UndoFinalize(CRCType crc, CRCType finalXOR, bool reflectOutp
/**
@brief Computes a CRC remainder.
@param[in] data Data over which the remainder will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] parameters CRC parameters
@param[in] remainder Running CRC remainder. Can be an initial value or the result of a previous CRC remainder calculation.
@tparam CRCType Integer type for storing the CRC result
@@ -620,7 +791,7 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
CRCType polynomial = CRC::Reflect(parameters.polynomial, CRCWidth);
while (size--)
{
remainder ^= *current++;
remainder = static_cast<CRCType>(remainder ^ *current++);
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < CHAR_BIT; ++i)
@@ -631,9 +802,9 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
// remainder = (remainder >> 1) ^ polynomial;
// else
// remainder >>= 1;
remainder = (remainder >> 1) ^ ((remainder & 1) * polynomial);
remainder = static_cast<CRCType>((remainder >> 1) ^ ((remainder & 1) * polynomial));
#else
remainder = (remainder & 1) ? ((remainder >> 1) ^ polynomial) : (remainder >> 1);
remainder = static_cast<CRCType>((remainder & 1) ? ((remainder >> 1) ^ polynomial) : (remainder >> 1));
#endif
}
}
@@ -644,11 +815,12 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
#ifndef CRCPP_BRANCHLESS
static crcpp_constexpr CRCType CRC_HIGHEST_BIT_MASK(CRCType(1) << CRC_WIDTH_MINUS_ONE);
#endif
static crcpp_constexpr CRCType SHIFT(BoundedConstexprValue(CRCWidth - CHAR_BIT));
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CRCWidth >= CHAR_BIT) ? static_cast<CRCType>(CRCWidth - CHAR_BIT) : 0);
while (size--)
{
remainder ^= (static_cast<CRCType>(*current++) << SHIFT);
remainder = static_cast<CRCType>(remainder ^ (static_cast<CRCType>(*current++) << SHIFT));
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < CHAR_BIT; ++i)
@@ -659,9 +831,9 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
// remainder = (remainder << 1) ^ parameters.polynomial;
// else
// remainder <<= 1;
remainder = (remainder << 1) ^ (((remainder >> CRC_WIDTH_MINUS_ONE) & 1) * parameters.polynomial);
remainder = static_cast<CRCType>((remainder << 1) ^ (((remainder >> CRC_WIDTH_MINUS_ONE) & 1) * parameters.polynomial));
#else
remainder = (remainder & CRC_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ parameters.polynomial) : (remainder << 1);
remainder = static_cast<CRCType>((remainder & CRC_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ parameters.polynomial) : (remainder << 1));
#endif
}
}
@@ -672,14 +844,15 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
#ifndef CRCPP_BRANCHLESS
static crcpp_constexpr CRCType CHAR_BIT_HIGHEST_BIT_MASK(CRCType(1) << CHAR_BIT_MINUS_ONE);
#endif
static crcpp_constexpr CRCType SHIFT(BoundedConstexprValue(CHAR_BIT - CRCWidth));
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CHAR_BIT >= CRCWidth) ? static_cast<CRCType>(CHAR_BIT - CRCWidth) : 0);
CRCType polynomial = parameters.polynomial << SHIFT;
remainder <<= SHIFT;
CRCType polynomial = static_cast<CRCType>(parameters.polynomial << SHIFT);
remainder = static_cast<CRCType>(remainder << SHIFT);
while (size--)
{
remainder ^= *current++;
remainder = static_cast<CRCType>(remainder ^ *current++);
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < CHAR_BIT; ++i)
@@ -690,14 +863,14 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
// remainder = (remainder << 1) ^ polynomial;
// else
// remainder <<= 1;
remainder = (remainder << 1) ^ (((remainder >> CHAR_BIT_MINUS_ONE) & 1) * polynomial);
remainder = static_cast<CRCType>((remainder << 1) ^ (((remainder >> CHAR_BIT_MINUS_ONE) & 1) * polynomial));
#else
remainder = (remainder & CHAR_BIT_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ polynomial) : (remainder << 1);
remainder = static_cast<CRCType>((remainder & CHAR_BIT_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ polynomial) : (remainder << 1));
#endif
}
}
remainder >>= SHIFT;
remainder = static_cast<CRCType>(remainder >> SHIFT);
}
return remainder;
@@ -706,7 +879,7 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
/**
@brief Computes a CRC remainder using lookup table.
@param[in] data Data over which the remainder will be computed
@param[in] size Size of the data
@param[in] size Size of the data, in bytes
@param[in] lookupTable CRC lookup table
@param[in] remainder Running CRC remainder. Can be an initial value or the result of a previous CRC remainder calculation.
@tparam CRCType Integer type for storing the CRC result
@@ -722,37 +895,35 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
{
while (size--)
{
#if defined(WIN32) || defined(_WIN32) || defined(WINCE)
#if defined(_MSC_VER) && !defined(__clang__) && !defined(__INTEL_COMPILER)
// Disable warning about data loss when doing (remainder >> CHAR_BIT) when
// remainder is one byte long. The algorithm is still correct in this case,
// though it's possible that one additional machine instruction will be executed.
# if defined(_MSC_VER)
# pragma warning (push)
# pragma warning (disable : 4333)
# endif
#endif
remainder = (remainder >> CHAR_BIT) ^ lookupTable[static_cast<unsigned char>(remainder ^ *current++)];
#if defined(WIN32) || defined(_WIN32) || defined(WINCE)
# if defined(_MSC_VER)
remainder = static_cast<CRCType>((remainder >> CHAR_BIT) ^ lookupTable[static_cast<unsigned char>(remainder ^ *current++)]);
#if defined(_MSC_VER) && !defined(__clang__) && !defined(__INTEL_COMPILER)
# pragma warning (pop)
# endif
#endif
}
}
else if (CRCWidth >= CHAR_BIT)
{
static crcpp_constexpr CRCType SHIFT(BoundedConstexprValue(CRCWidth - CHAR_BIT));
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CRCWidth >= CHAR_BIT) ? static_cast<CRCType>(CRCWidth - CHAR_BIT) : 0);
while (size--)
{
remainder = (remainder << CHAR_BIT) ^ lookupTable[static_cast<unsigned char>((remainder >> SHIFT) ^ *current++)];
remainder = static_cast<CRCType>((remainder << CHAR_BIT) ^ lookupTable[static_cast<unsigned char>((remainder >> SHIFT) ^ *current++)]);
}
}
else
{
static crcpp_constexpr CRCType SHIFT(BoundedConstexprValue(CHAR_BIT - CRCWidth));
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CHAR_BIT >= CRCWidth) ? static_cast<CRCType>(CHAR_BIT - CRCWidth) : 0);
remainder <<= SHIFT;
remainder = static_cast<CRCType>(remainder << SHIFT);
while (size--)
{
@@ -760,26 +931,94 @@ inline CRCType CRC::CalculateRemainder(const void * data, crcpp_size size, const
remainder = lookupTable[static_cast<unsigned char>(remainder ^ *current++)];
}
remainder >>= SHIFT;
remainder = static_cast<CRCType>(remainder >> SHIFT);
}
return remainder;
}
/**
@brief Function to force a compile-time expression to be >= 0.
@note This function is used to avoid compiler warnings because all constexpr values are evaluated
in a function even in a branch will never be executed. This also means we don't need pragmas
to get rid of warnings, but it still can be computed at compile-time. Win-win!
@param[in] x Compile-time expression to bound
@tparam CRCType Integer type for storing the CRC result
@tparam CRCWidth Number of bits in the CRC
@return Non-negative compile-time expression
*/
template <typename IntegerType>
inline crcpp_constexpr IntegerType CRC::BoundedConstexprValue(IntegerType x)
template <typename CRCType, crcpp_uint16 CRCWidth>
inline CRCType CRC::CalculateRemainderBits(unsigned char byte, crcpp_size numBits, const Parameters<CRCType, CRCWidth> & parameters, CRCType remainder)
{
return (x < IntegerType(0)) ? IntegerType(0) : x;
// Slightly different implementations based on the parameters. The current implementations try to eliminate as much
// computation from the inner loop (looping over each bit) as possible.
if (parameters.reflectInput)
{
CRCType polynomial = CRC::Reflect(parameters.polynomial, CRCWidth);
remainder = static_cast<CRCType>(remainder ^ byte);
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < numBits; ++i)
{
#ifdef CRCPP_BRANCHLESS
// Clever way to avoid a branch at the expense of a multiplication. This code is equivalent to the following:
// if (remainder & 1)
// remainder = (remainder >> 1) ^ polynomial;
// else
// remainder >>= 1;
remainder = static_cast<CRCType>((remainder >> 1) ^ ((remainder & 1) * polynomial));
#else
remainder = static_cast<CRCType>((remainder & 1) ? ((remainder >> 1) ^ polynomial) : (remainder >> 1));
#endif
}
}
else if (CRCWidth >= CHAR_BIT)
{
static crcpp_constexpr CRCType CRC_WIDTH_MINUS_ONE(CRCWidth - CRCType(1));
#ifndef CRCPP_BRANCHLESS
static crcpp_constexpr CRCType CRC_HIGHEST_BIT_MASK(CRCType(1) << CRC_WIDTH_MINUS_ONE);
#endif
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CRCWidth >= CHAR_BIT) ? static_cast<CRCType>(CRCWidth - CHAR_BIT) : 0);
remainder = static_cast<CRCType>(remainder ^ (static_cast<CRCType>(byte) << SHIFT));
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < numBits; ++i)
{
#ifdef CRCPP_BRANCHLESS
// Clever way to avoid a branch at the expense of a multiplication. This code is equivalent to the following:
// if (remainder & CRC_HIGHEST_BIT_MASK)
// remainder = (remainder << 1) ^ parameters.polynomial;
// else
// remainder <<= 1;
remainder = static_cast<CRCType>((remainder << 1) ^ (((remainder >> CRC_WIDTH_MINUS_ONE) & 1) * parameters.polynomial));
#else
remainder = static_cast<CRCType>((remainder & CRC_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ parameters.polynomial) : (remainder << 1));
#endif
}
}
else
{
static crcpp_constexpr CRCType CHAR_BIT_MINUS_ONE(CHAR_BIT - 1);
#ifndef CRCPP_BRANCHLESS
static crcpp_constexpr CRCType CHAR_BIT_HIGHEST_BIT_MASK(CRCType(1) << CHAR_BIT_MINUS_ONE);
#endif
// The conditional expression is used to avoid a -Wshift-count-overflow warning.
static crcpp_constexpr CRCType SHIFT((CHAR_BIT >= CRCWidth) ? static_cast<CRCType>(CHAR_BIT - CRCWidth) : 0);
CRCType polynomial = static_cast<CRCType>(parameters.polynomial << SHIFT);
remainder = static_cast<CRCType>((remainder << SHIFT) ^ byte);
// An optimizing compiler might choose to unroll this loop.
for (crcpp_size i = 0; i < numBits; ++i)
{
#ifdef CRCPP_BRANCHLESS
// Clever way to avoid a branch at the expense of a multiplication. This code is equivalent to the following:
// if (remainder & CHAR_BIT_HIGHEST_BIT_MASK)
// remainder = (remainder << 1) ^ polynomial;
// else
// remainder <<= 1;
remainder = static_cast<CRCType>((remainder << 1) ^ (((remainder >> CHAR_BIT_MINUS_ONE) & 1) * polynomial));
#else
remainder = static_cast<CRCType>((remainder & CHAR_BIT_HIGHEST_BIT_MASK) ? ((remainder << 1) ^ polynomial) : (remainder << 1));
#endif
}
remainder = static_cast<CRCType>(remainder >> SHIFT);
}
return remainder;
}
#ifdef CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
@@ -909,6 +1148,25 @@ inline const CRC::Parameters<crcpp_uint8, 6> & CRC::CRC_6_ITU()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-6 NR.
@note The parameters are static and are delayed-constructed to reduce memory
footprint.
@note CRC-6 NR has the following parameters and check value:
- polynomial = 0x21
- initial value = 0x00
- final XOR = 0x00
- reflect input = false
- reflect output = false
- check value = 0x15
@return CRC-6 NR parameters
*/
inline const CRC::Parameters<crcpp_uint8, 6> & CRC::CRC_6_NR()
{
static const Parameters<crcpp_uint8, 6> parameters = { 0x21, 0x00, 0x00, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-7 JEDEC.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -965,6 +1223,24 @@ inline const CRC::Parameters<crcpp_uint8, 8> & CRC::CRC_8_EBU()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-8 HDLC (ISO/IEC 13239:2002).
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@note CRC-8 HDLC has the following parameters and check value:
- polynomial = 0x07
- initial value = 0xFF
- final XOR = 0xFF
- reflect input = true
- reflect output = true
- check value = 0x2F
@return CRC-8 HDLC parameters
*/
inline const CRC::Parameters<crcpp_uint8, 8> & CRC::CRC_8_HDLC()
{
static const Parameters<crcpp_uint8, 8> parameters = { 0x07, 0xFF, 0xFF, true, true };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-8 MAXIM (aka CRC-8 DOW-CRC).
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -1001,6 +1277,24 @@ inline const CRC::Parameters<crcpp_uint8, 8> & CRC::CRC_8_WCDMA()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-8 LTE.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@note CRC-8 LTE has the following parameters and check value:
- polynomial = 0x9B
- initial value = 0x00
- final XOR = 0x00
- reflect input = false
- reflect output = false
- check value = 0xEA
@return CRC-8 LTE parameters
*/
inline const CRC::Parameters<crcpp_uint8, 8> & CRC::CRC_8_LTE()
{
static const Parameters<crcpp_uint8, 8> parameters = { 0x9B, 0x00, 0x00, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-10 ITU.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -1055,6 +1349,25 @@ inline const CRC::Parameters<crcpp_uint16, 11> & CRC::CRC_11()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-11 NR.
@note The parameters are static and are delayed-constructed to reduce memory
footprint.
@note CRC-11 NR has the following parameters and check value:
- polynomial = 0x621
- initial value = 0x000
- final XOR = 0x000
- reflect input = false
- reflect output = false
- check value = 0x5CA
@return CRC-11 NR parameters
*/
inline const CRC::Parameters<crcpp_uint16, 11> & CRC::CRC_11_NR()
{
static const Parameters<crcpp_uint16, 11> parameters = { 0x621, 0x000, 0x000, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-12 CDMA2000.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -1218,6 +1531,24 @@ inline const CRC::Parameters<crcpp_uint16, 16> & CRC::CRC_16_CCITTFALSE()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-16 MCRF4XX.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@note CRC-16 MCRF4XX has the following parameters and check value:
- polynomial = 0x1021
- initial value = 0xFFFF
- final XOR = 0x0000
- reflect input = true
- reflect output = true
- check value = 0x6F91
@return CRC-16 MCRF4XX parameters
*/
inline const CRC::Parameters<crcpp_uint16, 16> & CRC::CRC_16_MCRF4XX()
{
static const Parameters<crcpp_uint16, 16> parameters = { 0x1021, 0xFFFF, 0x0000, true, true};
return parameters;
}
#ifdef CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
/**
@brief Returns a set of parameters for CRC-16 CDMA2000.
@@ -1237,6 +1568,24 @@ inline const CRC::Parameters<crcpp_uint16, 16> & CRC::CRC_16_CDMA2000()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-16 CMS.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@note CRC-16 CMS has the following parameters and check value:
- polynomial = 0x8005
- initial value = 0xFFFF
- final XOR = 0x0000
- reflect input = false
- reflect output = false
- check value = 0xAEE7
@return CRC-16 CMS parameters
*/
inline const CRC::Parameters<crcpp_uint16, 16> & CRC::CRC_16_CMS()
{
static const Parameters<crcpp_uint16, 16> parameters = { 0x8005, 0xFFFF, 0x0000, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-16 DECT-R (aka CRC-16 R-CRC).
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -1400,6 +1749,7 @@ inline const CRC::Parameters<crcpp_uint16, 16> & CRC::CRC_16_USB()
static const Parameters<crcpp_uint16, 16> parameters = { 0x8005, 0xFFFF, 0xFFFF, true, true };
return parameters;
}
#endif // CRCPP_INCLUDE_ESOTERIC_CRC_DEFINITIONS
/**
@@ -1529,6 +1879,63 @@ inline const CRC::Parameters<crcpp_uint32, 24> & CRC::CRC_24_FLEXRAYB()
return parameters;
}
/**
@brief Returns a set of parameters for CRC-24 LTE-A/NR-A.
@note The parameters are static and are delayed-constructed to reduce memory
footprint.
@note CRC-24 LTE-A has the following parameters and check value:
- polynomial = 0x864CFB
- initial value = 0x000000
- final XOR = 0x000000
- reflect input = false
- reflect output = false
- check value = 0xCDE703
@return CRC-24 LTE-A parameters
*/
inline const CRC::Parameters<crcpp_uint32, 24> & CRC::CRC_24_LTEA()
{
static const Parameters<crcpp_uint32, 24> parameters = { 0x864CFB, 0x000000, 0x000000, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-24 LTE-B/NR-B.
@note The parameters are static and are delayed-constructed to reduce memory
footprint.
@note CRC-24 LTE-B has the following parameters and check value:
- polynomial = 0x800063
- initial value = 0x000000
- final XOR = 0x000000
- reflect input = false
- reflect output = false
- check value = 0x23EF52
@return CRC-24 LTE-B parameters
*/
inline const CRC::Parameters<crcpp_uint32, 24> & CRC::CRC_24_LTEB()
{
static const Parameters<crcpp_uint32, 24> parameters = { 0x800063, 0x000000, 0x000000, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-24 NR-C.
@note The parameters are static and are delayed-constructed to reduce memory
footprint.
@note CRC-24 NR-C has the following parameters and check value:
- polynomial = 0xB2B117
- initial value = 0x000000
- final XOR = 0x000000
- reflect input = false
- reflect output = false
- check value = 0xF48279
@return CRC-24 NR-C parameters
*/
inline const CRC::Parameters<crcpp_uint32, 24> & CRC::CRC_24_NRC()
{
static const Parameters<crcpp_uint32, 24> parameters = { 0xB2B117, 0x000000, 0x000000, false, false };
return parameters;
}
/**
@brief Returns a set of parameters for CRC-30 CDMA.
@note The parameters are static and are delayed-constructed to reduce memory footprint.
@@ -1700,4 +2107,8 @@ inline const CRC::Parameters<crcpp_uint64, 64> & CRC::CRC_64()
}
#endif
#if defined(_MSC_VER) && !defined(__clang__) && !defined(__INTEL_COMPILER)
#pragma warning(pop)
#endif
#endif // CRCPP_CRC_H_

Some files were not shown because too many files have changed in this diff Show More