Commit Graph

34240 Commits

Author SHA1 Message Date
pre-commit-ci[bot]
5fd4e5acc5 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2023-09-10 16:01:37 +02:00
wmayer
811abd699c Sheet: remove trailing whitespace
pre-commit.com hooks will remove the trailing whitespaces from the .ts files
2023-09-10 16:01:37 +02:00
wmayer
b5d363baf1 Sheet: Apply clang format 2023-09-10 16:01:37 +02:00
wmayer
50bb81e6fc Sheet: Apply clang format 2023-09-10 16:01:37 +02:00
wmayer
4d3c9ce1c5 Sheet: Apply clang format 2023-09-10 16:01:37 +02:00
wmayer
76656ea3b3 Sheet: Add to pre-commit hooks 2023-09-10 16:01:37 +02:00
pre-commit-ci[bot]
1b33e4cb4b [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2023-09-10 12:37:47 +02:00
wmayer
ee0dd92233 Drawing: Apply clang format 2023-09-10 12:37:47 +02:00
wmayer
e694a4f381 Drawing: Add to pre-commit hooks 2023-09-10 12:37:47 +02:00
wmayer
7bc320faf4 Show: Apply clang format 2023-09-10 12:20:59 +02:00
wmayer
aaaddb6186 Show: Add to pre-commit hooks 2023-09-10 12:20:59 +02:00
wmayer
33f114a4cb Plot: Apply clang format 2023-09-10 11:31:36 +02:00
wmayer
f3143c022e Plot: Add to pre-commit hooks 2023-09-10 11:31:36 +02:00
wmayer
780ce5c766 JtReader: Apply clang format 2023-09-10 11:25:51 +02:00
wmayer
ac020f6ea9 JtReader: Add to pre-commit hooks 2023-09-10 11:25:51 +02:00
wmayer
1285b43315 Cloud: Apply clang format 2023-09-10 11:10:12 +02:00
wmayer
81a1498dc9 Cloud: Add to pre-commit hooks 2023-09-10 11:10:12 +02:00
andrea
63a82b0b17 The DownloadStatistics.py file is the duplication of the githubstats.py file 2023-09-09 17:55:25 +02:00
andrea
4897202bc4 fix vtk > 6.1 check 2023-09-09 17:52:11 +02:00
andrea
19272554e1 Removed old code using qt<5.4 2023-09-09 17:50:51 +02:00
mosfet80
67a0d077e1 Delete src/Tools/astylerc
Removed config file for  astylerc c c++ formatter tool
2023-09-09 01:12:49 +02:00
wmayer
26cd974e08 Gui: fix clang-tidy warning 2023-09-08 21:45:10 +02:00
Michael Tuma
32c5968069 Made the interval that the Python profiler runs at configurable
Added a "User parameter:BaseApp/Preferences/PythonConsole/ProfilerInterval" int
property which sets how often (in milliseconds) the Python profiler runs while
Python code is running. Setting this value to zero will totally disable it.

Also added a preference in the Python console screen which allows the user to
set the value of this property to between 0 (disabled) and 5000 (once every 5
seconds). (+1 squashed commits)

Squashed commits:

[cca88ac633] Made the Python profiler only run when the console is running code

This has two purposes. First, it prevents a performance impact from running the
profiler whenever Python code is running. Second, it prevents crashes caused by
Qt's process events function being called too frequently. When the Python code
is running in the console, it monopolizes the main thread and prevents events
from being processed. Therefore, causing events to be processed in the callback
should not force events to be processed too frequently, because the normal loop
is being prevented by the Python code. (+1 squashed commits)

Squashed commits:

[45f86917e6] Made long-running Python code not freeze the GUI without multithreading

Removed the background thread running Python code and replaced it with a custom
profiler which the Python interpreter runs frequently (at every Python opcode I
believe) on the main thread whenever Python code is running. The profiler will
make Qt process any new events every 200 ms, preventing "App not responding"
messages and making sure any Ctrl+C keypresses will be processed. This prevents
the previous issue where running anything GUI-related from Python would crash
the program (because Qt isn't thread-safe). (+1 squashed commits)

Squashed commits:

[0ef7d810b3] Made the process of getting thread IDs cross-platform compatible

Instead of using <threads.h>, now the standard <thread> header from C++
11 is used to find the thread ID, since <threads.h> is apparently not
available on Windows. (+1 squashed commits)

Squashed commits:

[74c7b867f2] # This is a combination of 2 commits.

Python from the console now runs in the background

In a nutshell, all Python code which is input from the interactive console
now runs in a seperate QThread which runs in the background, instead of
on the UI thread. This means that long operates operations will no longer
cause the app to display an "App not responding" message, because the UI
thread is now free to keep running unencumbered.

However, it is still not possible to run multiple Python statements at
the same time. If the user tries to run some Python while a previous
statement is still being processed, instead it will display an error
message in the console stating that the previous command is still
being processed.

I also added a seperate QTimer which runs once every 100ms to flush any
output from the Python code back to the console. I can't flush the output
to the console from the background thread because the relevant Qt5 code
is not thread-safe (it causes random segfaults). So I added this timer
as a work-around, since it runs in the main UI thread.

Implemented Ctrl+C keyboard interrupts in the console

This is implemented by detecting a Ctrl+C key event in the Python
console in the main Qt UI thread, and sending a keyboard interrupt
to the background thread that runs the Python code.
2023-09-08 21:45:10 +02:00
wmayer
f1ef5c4729 Tux: apply clang format 2023-09-08 18:06:03 +02:00
wandererfan
728b2ec841 [Part]fix canScale logic
- fix canScale logic
- remove unused method
- add more comments
2023-09-08 18:04:26 +02:00
wandererfan
495ae5df75 [Part]correct handling of preselected objects 2023-09-08 18:04:26 +02:00
mosfet80
22971a05dc Update FCConfig.h
Clean fcconfig
2023-09-08 18:01:43 +02:00
FEA-eng
bf207019be Fixed minor typo in FEM preferences
solver --> solvers
2023-09-08 11:01:11 -05:00
andrea
dccca2b7ed fix compilation warning 2023-09-08 14:13:36 +02:00
wmayer
381efa3b35 Gui: filter warning about dead keys
Forum thread: https://forum.freecad.org/viewtopic.php?t=80981
2023-09-08 14:12:24 +02:00
wmayer
8a56da4ee0 Sandbox: [skip ci] fix build failures 2023-09-08 11:47:16 +02:00
Yorik van Havre
3645d8be3b Merge pull request #10556 from Roy-043/Draft-arcTracker-did-not-take-Working-Plane-rotation-into-account
Draft: arcTracker did not take Working Plane rotation into account
2023-09-08 11:36:25 +02:00
mosfet80
574953a4f5 Update CMakeLists.txt
Freecad use qt5 or qt6
2023-09-07 23:06:11 +02:00
Chris Hennes
b2042f36c6 Tools: Fix Start translation TS file name 2023-09-07 23:05:25 +02:00
luzpaz
6810c5703d Fix various typos 2023-09-07 20:34:49 +02:00
wandererfan
c700a9feb8 [TD]fix fail on multiple empty annotation 2023-09-07 13:11:09 -04:00
wandererfan
d7f5764b9e [Part]code review changes for FeatureScale 2023-09-07 18:21:56 +02:00
wandererfan
90aef60f32 [Part]add scale command & feature 2023-09-07 18:21:56 +02:00
Roy-043
2cbe037ce8 Start: Improve "Switch workbench after loading" tooltip
Make it clearer that this property is different from the "Start up workbench".
2023-09-07 09:39:08 -05:00
sliptonic
137baa1a0a Merge pull request #10567 from petterreinholdtsen/debian-1120-desktop-extra-categories
Add XDG desktop category X-CNC also used by LinuxCNC.
2023-09-07 09:06:02 -05:00
wmayer
c9774cdacc Test: add test for default file system encoding 2023-09-06 23:54:42 +02:00
Ajinkya Dahale
5300e70eab [Core] Avoid some seg-fault because of PySequence_Check(nullptr) 2023-09-06 16:17:21 +02:00
wandererfan
4dd2b8d757 [TD]refactor print routines out of MDIViewPage 2023-09-06 08:58:33 -04:00
wmayer
5e911daae2 Part: add tests to ensure that the fixed methods work correctly 2023-09-06 12:14:37 +02:00
wmayer
e6d350e719 Part: when replacing PyArg_ParseTupleAndKeywords with Base::Wrapped_ParseTupleAndKeywords then in a few cases the negation of the expression has been removed.
See also: https://forum.freecad.org/viewtopic.php?t=80958
2023-09-06 11:53:56 +02:00
wmayer
2a65715248 Mesh: fixes issue #10075: 3MF files exported from FreeCAD don't work in PrusaSlicer
Add an option to force to always write a mesh as model type even if it's not a solid
2023-09-06 07:28:07 +02:00
mosfet80
9583c1c0cb Delete src/Tools/plugins/widget/FreeCAD_widgets.vcxproj.user
removed Visual studio user personal file
2023-09-06 07:22:01 +02:00
mosfet80
f33ca32ddc Delete src/Tools/plugins/widget/FreeCAD_widgets.vcxproj.filters
removed custom Visual Studio filter file
2023-09-06 07:22:01 +02:00
Petter Reinholdtsen
e93e76edcc Add XDG desktop category X-CNC also used by LinuxCNC.
This ensure FreeCAD and LinuxCNC both show up in the CNC submenu when
both are installed.
2023-09-06 01:02:29 +02:00
FEA-eng
6171feb560 Update MainWindow.cpp
fixed small typo in the warning about 0.22 being dev version not for production use
2023-09-05 15:40:16 -05:00