Commit Graph

44030 Commits

Author SHA1 Message Date
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
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
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](194d461b21...28eb668aaf)

---
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