Commit Graph

30 Commits

Author SHA1 Message Date
Benjamin Nauck
c77de32b78 App: Use std::numeric_limits and std::numbers instead of defines 2025-03-29 13:32:37 +01:00
Andrea
146d8a356b change MIN_boost_version
ubuntu version 20.04 is no longer supported.
The minimum boost version used for freecad is now 1.74 (ubuntu 22.04) https://launchpad.net/ubuntu/jammy/+package/libboost-system-dev
2025-02-15 13:33:32 -06:00
Chris Hennes
417e188256 App: Add utility method to get app name with version included 2025-02-03 12:05:16 -05:00
Jonas Bähr
91a95369f2 Main: Avoid Popups in Console Mode
When in console mode, some messages from CLI interaction still resulted
in popup dialogs, e.g. the response from `--help` or `--version`. This
is becasue those information are communicated via exceptions and those
exceptions prevented the console mode from being properly set.
By using a scope guard the console mode flag is now evaluated in all
cases. The code to display those messages got refactored into dedicated
methods which now also take care of console mode.
2025-01-27 17:47:16 +01:00
wmayer
6f5259af26 App: Apply clang format (part 1) 2024-11-21 07:54:24 +01:00
wmayer
e7096e457f Core: Generate a static random number in Application::applicationPid()
Using Qt's QCoreApplication::applicationPid() doesn't always give a unique ID so that multiple FreeCAD instances cannot be executed at the same time.
This fixes #17678
2024-11-06 13:52:31 -05:00
Yuri D'Elia
f6e4c6829f App: Fix build with pch
Include <cfloat> for DBL_MAX
2024-01-02 19:29:02 +01:00
Uwe
6d4a90c605 [App] sort includes in PreCompiled.h
- also remove a superfluous private: statement
- also remove an unnecessary include
2023-02-18 14:53:11 +01:00
luz paz
056d1aea87 Fix various typos and grammatical issues 2022-11-30 12:45:29 +01:00
wmayer
a8ac45b090 Replace std::ignore with boost::ignore_unused()
According to https://isocpp.org/blog/2016/09/quick-q-stdignore-for-ignoring-unused-variable std::ignore is not supposed to be used for this
2022-07-15 13:15:47 +02:00
wmayer
a261249217 App: replace ctime() with boost's date/time functions in Application::logStatus() 2021-09-30 19:50:19 +02:00
wmayer
a6e7bdf849 allow to enable PCH for gcc and clang 2021-05-03 17:37:58 +02:00
Benjamin Nauck
358cb01a9c [App] Switch from boost::tuple to std::tuple
It's better to use the standard lib when possible
2021-03-06 19:31:06 +01:00
wmayer
9e39b41ca6 App: in document observer classes replace boost::bind with std::bind to fix build failure with C++17 2021-03-05 13:26:26 +01:00
wmayer
eac4062b3f Boost: [skip ci] Fix build warnings from deprecated Boost headers (v1.75) 2020-12-29 15:34:25 +01:00
Mateusz Skowroński
98f63ba60f Fix build warnings from deprecated Boost headers (they are used internally by Boost). Thanks @wwmayer for the hint. 2020-12-29 10:20:53 +01:00
luz paz
84553bf191 App: Fix header uniformity, trailing whitespace, and doxygen headers 2020-11-19 13:38:37 +01:00
wmayer
56c608932f Win: [skip ci] check if NOMINMAX is already defined before setting it 2020-11-11 13:34:42 +01:00
wmayer
730154a684 boost 1.73.0: The practice of declaring the Bind placeholders (_1, _2, ...) in the global namespace is deprecated 2020-06-12 17:51:33 +02:00
luz.paz
019f73852c src/App: [skip ci] fix header uniformity
This PR fixes header uniformity across all `src/App` files
2019-12-25 11:38:43 +01:00
lorenz
e9e1c89929 add missing include to Precompiled.h 2019-09-25 20:06:36 +02:00
Zheng, Lei
be6ec3fdfc App: Property related API changes
Property:

* Extended property status bitset. Mirror most of PropertyType and
  allow dynamic change property type.

* Cache property name and type to improve performance

* Centralize property status change signalling

* Change aboutToSetValue()/hasSetValue() to virtual

* Add new API getFullName() to obtain full quanlified name of the property

AtomicPropertyChangeInterface:

* Allow calling aboutToSetValue()/hasSetValue() when actually changed

PropertyLists:

* Refactor implementation by an abstract class PropertyListBase and a
  template class PropertyListsT, to allow better code reuse.
  PropertyListT is derived from AtomicPropertyChangeInterface to allow
  more efficient change on individual elements.

* All list type property now accept setting python value as a dictionary
  with index as key to set individual element of a list.

* Add touch list for more efficient handling of value changes. The list
  contains the index of changed value. And empty touch list should be
  treated as the entire list is changed. PropertyContainerPy expose this
  functionality with getPropertyTouchList().

PropertyPersistentObject:

* New property to allow dynamic creation of any FreeCAD object derived
  from Base::Persistence, and use it as a property.

DynamicProperty:

* Use boost multi_index_container for efficient property lookup while
  keeping order.

* Modify to be allowed to use in PropertyContainer directly

PropertyContainer:

* Use boost multi_index_container for efficient property lookup while
  keeping order.

* Allow adding/removing dynamic property on all property container

* Modify Save/Restore() to persist property status, and better handle
  transient property which can now be dynamically enabled/disabled per
  object.

* Add new API getFullName() to obtain full quanlified name of the property.
  Implemented by Document, DocumentObject, and also
  ViewProviderDocumentObject if future patch

DocumentObject and FeaturePython are modified to accommondate the
dynamic property changes.

Removed get/setCustomAttribute() implementation from DocumentObjectPy,
and rely on PropertyContainerPy for the implementation, because of the
additional dynamic property support in property container.

Gui::ViewProviderDocumentObject, which is derived from
PropertyContainer, is also modified accordingly
2019-08-17 14:52:09 +02:00
wmayer
36271b4052 move from deprecated boost.signals to boost.signals2 library 2018-10-30 19:09:03 +01:00
wmayer
0260370b65 + add option to switch off precompiled header 2018-07-25 20:17:11 +02:00
Stefan Tröger
fe8e69f122 Add missing header for random numbers 2017-06-19 15:37:09 +02:00
Stefan Tröger
0ae9346b3c Extenions: Drop virtual inheritance
Due to problems onthe windows platform the virtual inheritance approach must be dropped. NExt to the already reimplemented proeprty interface the Type interface is reimplemented too. This change allows to revert some earlier changes.
2016-10-08 12:48:34 +02:00
Stefan Tröger
92a294f6aa Extensions: Windows fixes 2016-10-08 12:48:34 +02:00
wmayer
f6023d36d2 + rework BoundingBox class and its Python binding 2015-10-11 00:18:53 +02:00
Mateusz Skowroński
05f95c0506 Fix files encoding. Go from ISO8859-1 to UTF-8. 2015-09-21 19:50:49 -03:00
wmayer
120ca87015 + unify DLL export defines to namespace names
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5000 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-10-10 13:44:52 +00:00