Commit Graph

606 Commits

Author SHA1 Message Date
freecad-gh-actions-translation-bot
9b07585b88 Update translations from Crowdin 2025-12-17 21:10:10 -06:00
Kacper Donat
a96f3535b6 Gui: Fix segfault in Safe Mode
This fixes segfault that was caused by changing settings in
FirstStartWidget that triggered change event on not fully intialized
StartView.

It is quick and dirty fix that just disables handling of the event
causing segfault until widget is fully ready. The correct solution would
be to remove the logic that changes settings from the widget (as it
should not be there) and instad move it to another place in pipeline.
This would be however much more work and segfault should be fixed ASAP.
2025-12-15 21:06:51 -06:00
freecad-gh-actions-translation-bot
97b9193d71 Update translations from Crowdin 2025-12-08 22:31:48 -06:00
github-actions
914b34cc1a Update translations from Crowdin 2025-11-25 21:20:42 -06:00
github-actions
bb748b15ea Update translations from Crowdin 2025-11-11 23:44:18 -06:00
pre-commit-ci[bot]
9fe130cd73 All: Reformat according to new standard 2025-11-11 13:49:01 +01:00
PhoneDroid
4b0c6fe80a [ Start ]: Update SPDX License Identifiers 2025-11-03 11:57:06 -06:00
github-actions
a3c2454a61 Update translations from Crowdin 2025-10-27 21:06:54 -05:00
github-actions
5ae4bbf837 Update translations from Crowdin 2025-10-20 09:57:05 -05:00
Chris Hennes
8500ed0520 Update translations 2025-10-05 2025-10-07 19:21:58 +02:00
Chris Hennes
1c6d9c79fb Update translations 2025-09-25 2025-09-25 17:25:13 +02:00
Markus Reitböck
4400cb2bec 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
Chris Hennes
ea85d3fed0 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
Chris Hennes
02721eec37 Update translations 2025-09-15 2025-09-16 09:55:13 +02:00
Markus Reitböck
496b31b087 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
Chris Hennes
ff349c81d6 Merge pull request #23746 from 3x380V/cmake
CMake: Use scoped include and library directories
2025-09-10 21:54:51 -05:00
Chris Hennes
23bcfd12ff Update translations 2025-09-09 2025-09-10 08:53:41 +02:00
wmayer
ac51455a0a CMake: Replace include_directories with target_include_directories 2025-09-08 19:04:34 +02:00
Chris Hennes
c0d1151633 Update translations 2025-09-03 2025-09-04 11:37:11 +02:00
Chris Hennes
e36d5db583 Update translations 2025-08-30 2025-09-01 17:44:54 +02:00
Chris Hennes
f3c675ed5b Update translations 2025-08-28 16:14:49 +02:00
MisterMakerNL
6d81d0556a 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
Max Wilfinger
ab5e9e0ded 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
tetektoza
a2250dd85d 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
Chris Hennes
40b1ea294c Update translations 2025-08-18 17:55:24 +02:00
Benjamin Nauck
88f24ff7c3 Start: Fix bug causing <none> to show in wb selector 2025-08-12 11:09:00 -05:00
Carlos Nihelton
f2fadec102 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
xtemp09
2d12f2d9d8 Add "Clear Recent files list" item (#22638)
* Add "Clear Recent files" item

---------

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-07-23 04:11:48 +00:00
Max Wilfinger
a1aaa15733 Start: Update UI strings for consistency 2025-06-29 11:27:43 -05:00
Syres916
3eb160ac87 [Start] add Tooltip to show full path when the ShortCustomFolder is true 2025-06-08 22:11:05 +02:00
Syres916
39f8d8ef64 [Start] show the actual custom folder name...
...instead of 'Custom Folder'
2025-06-08 16:19:19 +02:00
Chris Hennes
b83dfa2ae7 Merge pull request #21706 from 3x380V/fix_start
Start: Fix crash
2025-06-02 09:45:09 -05:00
Yorik van Havre
640642eed2 Translations: Merged crowdin translations 2025-06-02 11:48:26 +02:00
Yorik van Havre
26e16765b0 Translations: updated ts files 2025-06-02 11:07:28 +02:00
wmayer
a88623ff24 Start: Fix possible crash when opening Start page
Procedure to trigger the crash:
* Create a document
* Create a spreadsheet and open it
* Close the 3D view
* Open the Start page
* It may or may not crash but the program is in an undefined state

The reason of the crash is caused by an inappropriate use of static_cast.
This bug is caused by PR 17152.

To fix the crash use dynamic_cast instead. If the cast fails it returns
a null pointer instead of a dangling pointer.
2025-06-02 08:22:28 +02:00
Alfredo Monclus
a46dfd3213 Start: fix thumbnails not keeping aspect ratio 2025-05-29 15:00:37 +02:00
Ladislav Michl
34768d41b2 Start: fix restoring of user saved Unit schema
This is partially reverting change done in 1155f0d752.

Fixes: 1155f0d752 ("Base: simplify UnitsSchemas management")
2025-05-20 19:46:02 +02:00
bofdahof
ba2c2ca5ad Console: rename PascalCase named methods to camelCase 2025-05-06 17:50:21 +02:00
bofdahof
353acbb27b Base: simplify UnitsSchemas management
Fixes: Maintaining schemas is difficult and error-prone

- Facilitate easy schemas add, remove, change, etc.
- Remove 14 files containing approx 2,190 lines of if/else code and data
- Place data in one file (UnitsSchemasData.h) using a normalized structure (including special functions)
- Isolate and simplify data operations (code)
- Remove schemas enum to keep data independent of code
- Separate responsibilities: Specifications, data, schemas, schema
- Add schema data 'isDefault'
- Add schema data name
- Prefer algorithms to raw loops
- Add schemas unit tests
- Tweak quantity unit tests
2025-04-27 00:45:54 +02:00
Chris Hennes
b2e3659efe Start: Apply reviewer suggestion
Co-authored-by: Pieter Hijma <pieterhijma@users.noreply.github.com>
2025-04-21 21:21:52 +02:00
Chris Hennes
71932ac724 Start: Refactor f3d to use worker threads 2025-04-21 21:21:52 +02:00
Adrian Insaurralde Avalos
5635c41ed5 Start: refactor f3d previews, use caching and configurable f3d path 2025-04-21 21:21:52 +02:00
MaxiV
5f3c1aa5e8 Start: Switch to using QProcess, not std::system 2025-04-21 21:21:52 +02:00
MaxiV
55dd1f875d Start: add f3d previews 2025-04-21 21:21:52 +02:00
Furgo
6864ac4e0d Start: set specific zoom level for new BIM projects (#20271)
* Gui: allow viewDefaultOrientation function to accept the None value, as per the docstring

* Start, BIM: set specific zoom level for new BIM projects
2025-03-25 09:36:43 +01:00
Kacper Donat
3454a5938e Merge pull request #20216 from alfrix/start_fixes_5
Start: fix newbuttons vertical sizing
2025-03-23 17:10:19 +01:00
Alfredo Monclus
8fb23b9117 start: fix file cards not respecting styling 2025-03-22 18:59:11 +00:00
Alfredo Monclus
87b3052572 start: fix newfilebuttons sizehint and split it into it's own widget 2025-03-22 15:52:55 -03:00
Alfredo Monclus
b4afa87042 start: modify the flowlayout to have homogeneous rows 2025-03-22 15:39:46 -03:00
tritao
cdab9c7837 CMake: Cleanup targets with transitive dependencies 2025-03-17 12:12:06 +00:00