Commit Graph

1583 Commits

Author SHA1 Message Date
Frank David Martínez M
f1366e8a75 Base: Remove assertion on isForceXML() (#27491)
This fixes a difference between Main code and LS3 Code ported during TNP big merge. The Issue generates a crash if FreeCAD is compiled in Debug Mode: #27489.
2026-02-13 11:51:52 -06:00
Chris Hennes
0f23770ad7 Merge pull request #27064 from ScholliYT/addObjectNameTo3mfExport
Mesh: Add object name attribute to 3MF export
2026-02-08 03:22:56 -06:00
wmayer
2c3d9e2bb7 Base: Add C++ iostate methods to Writer class 2026-02-05 10:58:12 +01:00
captain0xff
79632dd3c6 App: handle symlinks in Application::processFiles & DocInfo::getDocPath 2026-02-02 19:50:36 +01:00
freecad-gh-actions-translation-bot
0b7da82433 Update translations from Crowdin 2026-02-02 11:49:57 +01:00
Kacper Donat
bf83b9bfde Base: Add TimeTracker (#26305)
* Base: Add TimeTracker

This adds TimeTracker utility that can be used to orchestrate code
with time measurements in an easy way and detect performance issues.

* Update src/Base/TimeInfo.h

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

---------

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2026-01-31 20:00:40 +01:00
Tom Stein
49c80ebe5c Mesh: Add object name attribute to 3MF export
Export mesh object names as 'name' attribute in 3MF files according to
the 3MF specification. This allows downstream tools to identify objects
by their original FreeCAD names.

Changes:
- Moved Exporter::xmlEscape() to Base XMLTools::escapeXml() for shared XML entity escaping
- Update Writer3MF::AddMesh() to accept and output object names with default "" where no attribute will be added
- Updated all codepaths leading to 3mf exports to include the object name
2026-01-31 09:09:27 +01:00
Petter Reinholdtsen
78b017130a Base: Removed unused private variable decimals to avoid lint issue.
The linter report 'private field 'decimals' is not used'.  The
getDecimals() method return pack.defDecimals, which was also
used to set the value of the decimals variable in the initializer,
so the decimals variable is redundant.
2026-01-18 20:29:51 +01:00
tritao
69058376e6 Base: Remove Boost-based signals and switch to FastSignals. 2026-01-07 21:16:16 +00:00
wmayer
f9cbeb91b1 Simplify code using xerces namespace 2026-01-07 14:37:59 +01:00
marioalexis
0f148f6e63 Base: Add millitesla unit 2025-12-16 14:26:31 -03:00
marioalexis
bfb0efd5f9 Base: Insert SPDX specifier in parser script 2025-12-16 14:26:31 -03:00
freecad-gh-actions-translation-bot
f7483a08b4 Update translations from Crowdin 2025-12-08 22:31:48 -06:00
Ladislav Michl
90086d3e31 Revert "[Base]retrieve unit text"
This reverts both pointless and broken commit c9fffa6789.
2025-12-03 17:43:53 +01:00
Chris Hennes
dfb9baf678 Merge pull request #24262 from mnesarco/pyi-fixes-1 2025-11-29 20:23:37 -06:00
github-actions
68cb0a3270 Update translations from Crowdin 2025-11-25 21:20:42 -06:00
Andrew Burks
bad2989b7b #25474 Added read-only warnings when saving documents (#25532)
* #25474 Added read-only warnings when saving documents

Block saving a file and notify user if windows is unable to save to the file for any reason, or the read-only attribute is checked. Also check std::filesystem::perms for write permission and other checks in FileInfo::isWritable(), although it doesn't seem to matter on windows.

Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-11-23 05:09:32 +00:00
Chris Hennes
4d0c35dd2d Core: Convert transparency to alpha (#24891)
* Core: Convert transparency to alpha

Create new `Base::getVersion()` function for extracting a program
version enumeration given a version string.

Convert transparency to alpha value for old project files.

* Base/App: Address review comments

---------

Co-authored-by: wmayer <wmayer@freecad.org>
2025-11-17 17:15:19 +01:00
Stephan T. Lavavej
9e6509a3a4 Avoid using non-Standard std::locale::empty() for MSVC 2025-11-14 00:22:18 -06:00
github-actions
8432fab0a9 Update translations from Crowdin 2025-11-11 23:44:18 -06:00
pre-commit-ci[bot]
5e0dd60ee5 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2025-11-11 19:34:32 +00:00
Frank Martinez
3561d25c2d [License] Fix pyi license headers. 2025-11-11 13:26:18 -05:00
Frank Martinez
7fe379e5ea [bindings] remove redundant signatures. batch1 2025-11-11 13:23:10 -05:00
Frank Martinez
1cf57d6e11 [bindings] Format with yapf (precommit will reformat) 2025-11-11 13:23:10 -05:00
Frank Martinez
1b0c0399e9 [bindings] Fix overload order 2025-11-11 13:23:10 -05:00
Frank Martinez
2ada443c18 Clean unused imports in .pyi files 2025-11-11 13:23:10 -05:00
Frank Martinez
39d15c011e black formatting 2025-11-11 13:23:10 -05:00
Frank Martinez
47e3162dcb [bindings] re-shape some keyword-only signatures 2025-11-11 13:23:09 -05:00
Frank Martinez
0eae00b9a1 [bindings] Code formatting 2025-11-11 13:23:09 -05:00
Frank Martinez
748004b4e4 [bindings] fix signatures in pyi files 2025-11-11 13:16:26 -05:00
pre-commit-ci[bot]
25c3ba7338 All: Reformat according to new standard 2025-11-11 13:49:01 +01:00
marioalexis
06131ce8b5 Base: Restore schema spec for electromagnetic potential unit - fix #25093 2025-11-06 15:05:25 +01:00
github-actions
11fecb1558 Update translations from Crowdin 2025-10-27 21:06:54 -05:00
Chris Hennes
d97c7cc95c Core: Switch away from deprecated wstring_convert and codecvt_utf8 2025-10-21 09:01:59 +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
github-actions
50d1dec4e0 Update translations from Crowdin 2025-10-20 09:57:05 -05:00
wandererfan
c9fffa6789 [Base]retrieve unit text
Co-authored-by: Chris Hennes <chennes@pioneerlibrarysystem.org>
2025-10-20 08:54:52 -05:00
PhoneDroid
2a56489feb [ Base ]: Updated SPDX 2025-10-14 10:00:04 -05:00
Chris Hennes
9780cf931f Update translations 2025-10-05 2025-10-07 19:21:58 +02:00
sliptonic
1c816da43b Merge pull request #24114 from chennes/addDirectoryIsWritable
Base: Refine directory permissions test
2025-10-06 10:35:21 -05:00
Chris Hennes
39d39f34c3 Update translations 2025-09-25 2025-09-25 17:25:13 +02:00
Chris Hennes
465bd7ef5c Base: Refine directory permissions test 2025-09-21 13:16:35 -05:00
Chris Hennes
29c69a4689 Update translations 2025-09-15 2025-09-16 09:55:13 +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
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
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
Chris Hennes
58a8d589a7 Update translations 2025-09-09 2025-09-10 08:53:41 +02:00
wmayer
93db4c7d8a CMake: Replace include_directories with target_include_directories 2025-09-08 19:04:34 +02:00
Chris Hennes
1f05f5eda4 Merge pull request #23351 from 3x380V/fileinfo
Core: Modernize Fileinfo
2025-09-07 21:28:11 -05:00