Commit Graph

179 Commits

Author SHA1 Message Date
pre-commit-ci[bot]
222a2520b1 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2023-09-12 13:02:35 -04:00
Chris Hennes
714cb0a309 Points: Final application of pre-commit 2023-09-04 08:18:51 -05:00
wmayer
8d24f0c021 Points: apply clang-formatting 2023-09-01 20:07:54 +02:00
wmayer
e456b50c6e Points: modernize C++: use default member init 2023-08-23 00:55:03 +02:00
wmayer
5d585de259 Points: for E57 reader move from float to double 2023-08-22 12:44:38 +02:00
wmayer
43ec243292 Points: modernize C++: use equals default 2023-08-22 12:37:37 +02:00
wmayer
db3a429100 Points: modernize C++: return braced init list 2023-08-19 11:35:41 +02:00
wmayer
9f42af487b Points: modernize C++: use range-based for loop 2023-08-15 17:20:01 +02:00
wmayer
9f456d712b modernize C++: use equals delete 2023-08-10 17:29:05 +02:00
wmayer
0af4990817 modernize C++: make unique 2023-08-07 19:51:30 -06:00
wmayer
86e56ec842 fixes #9134: Points Merge doesn't keep Color information 2023-05-12 13:12:14 +02:00
joha2
d870201e3b Points: show now returns an GeoFeature object
* Added one return statement into try-catch block which returns the appropriate object (instead of `None`).
* Behaviour now in line with `Part.show`.

Example:

```Python
>>> import Points
>>> pp = Points.Points()
>>> pp.addPoints([(1,2,3),(4,5,6)])
>>> go = Points.show(pp)
>>> go  # Former behaviour was to return None
<GeoFeature object>
>>> go.ViewObject.ShapeColor = (1,0,0)
>>> go.ViewObject.ShapeColor = (1.,0.,0.)
>>> go.ViewObject.PointSize = 20
```
2023-04-04 11:35:59 +02:00
wmayer
d196f8c496 Mod: catch exception raised by Rotation::setValue 2023-03-01 18:43:15 +01:00
wmayer
0d23594107 Core: add functions setPackedARGB and fromPackedRGBA 2023-02-26 10:11:53 +01:00
wmayer
41e6c17605 Points: use Color::getPackedARGB() for pcl colors 2023-02-26 10:11:53 +01:00
wmayer
a58ede8b9a Points: support of surface normals and fix handling with intensity 2022-12-22 20:17:49 +01:00
wmayer
3e576c3bca Points: refactor E57Reader 2022-12-22 19:14:38 +01:00
wmayer
f0a4ec8240 Points: fixes #7924: Pointcloud import anomalies 2022-12-21 13:05:16 +01:00
wmayer
cfc97b80b1 Mod: use new API of InventorBuilder 2022-12-12 20:50:32 +01:00
Uwe
af58f804d4 [Points] enable precompiled headers 2022-12-08 05:04:58 +01:00
Uwe
378184f8ea [Points] re-add a header 2022-12-07 23:19:38 +01:00
Uwe
987314b9d8 [Points] improve PreCompiled.h handling 2022-12-07 18:22:00 +01:00
luz paz
fa98553775 Fix various typos and grammatical issues 2022-11-30 12:45:29 +01:00
wmayer
da7006b889 Points: [skip ci] fix build failure 2022-11-29 18:50:24 +01:00
wmayer
b325ab93dc Base: refactoring of InventorBuilder 2022-11-29 13:28:00 +01:00
Uwe
95f647b9ed [Points] remove unused includes (#7900)
- also some sorting
2022-11-29 04:44:35 +01:00
wmayer
c988f1d472 Base: start of refactoring of InventorBuilder 2022-11-27 16:45:16 +01:00
Chris Hennes
2f7be9e782 cMake: Add support for compiling against Qt6 (#7647)
Removes the BUILD_QT5 flag and adds a new FREECAD_QT_VERSION option,
which can be set to either "Auto" (default), 5, or 6. Auto detects which
version of Qt is installed on the system and chooses it. If both version
are installed, Qt5 is used.

Note that this DOES NOT implement compiling against Qt6, it only adds
the necessary cMake infrastructure to begin work on the source code
changes that will be required.
2022-10-31 09:24:09 -05:00
Kuzemko Alexsandr
63174d487f [App] Fix of untranslated first document's name (#7156)
* Change no need function newDocument("Unnamed") call to variant without parameter. "Unnamed" set in App newDocument function instead.
* Refactor New Document command to run without parameter.
* Translate new document's userName. Internal name = "Unnamed".
* Crowdin Add to updatets.py App.ts. Create new file App.ts
* Fix error where document name is set with one function parameter. In this situation set internal and user name to string variable. For default function call (without parameter) set internal name to Unnamed, userName = translate ("Unnamed")
2022-10-20 21:35:09 -05:00
marioalexis
4bf23b89b7 Points: Replace C cast 2022-09-18 11:06:51 -05:00
wmayer
2462f4c7a0 App: move from float to double for accuracy parameter, add a virtual method to determine a default accuracy 2022-09-15 09:52:14 +02:00
wmayer
2ae40e006c Points: modernize C++: replace 'typedef' with 'using' 2022-08-29 22:57:24 +02:00
berniev
6953310116 Mod: Single arg ctors must be explicit 2022-08-24 16:55:20 +02:00
Jonas Bähr
a1776d3e74 Fix build on MacOS-X 10.14: missing Xerces include dir
This undoes most of the Xerces related part of the commits listed below.
The issue resolved here is that the Xerces include dir *is* set in the
CMakeLists.txt of src/Base, but it got removed from various App and Gui
dirs in src/Mod. If those now include a header from src/Base, which
itself includes xercesc, the build fails using Apple clang version 11.0.0
(clang-1100.0.33.17) on Mojave, configured using cmake 3.22.1, with
errors like the following:

In file included from .../src/Mod/Part/App/FeaturePartBoolean.cpp:34:
In file included from .../src/App/Application.h:33:
.../src/Base/Parameter.h:54:10: fatal error: 'xercesc/util/XercesDefs.hpp' file not found
 #include <xercesc/util/XercesDefs.hpp>
          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 error generated.

Finally, a full list of the commits that introduced this spurious include
dir optimization for reference:
- Drawing: commit 96ad045b91
- Image: commit dde71a21d5
- Import: commit c9d28b542f
- Inspection: commit d41f55f382
- Mesh: commit 19072b0538
- Part: commit fe213a48f0
- PartDesign: commit b037d8e240
- Path: commit f23fa31f42
- Points: commit bec723ba17
- Raytracing: commit 08d4ac63a3
- ReverseEnginering: commit 5ca787cb0e
- Robot: commit bad4809a1c
- Sketcher: commit 3c96daf105
- Spreadsheet: commit 66e8a2bef3
- Start: commit c9dee5e70a
- Surface: commit 6b04215be6
- TechDraw: commit 5e6699e48d
- Test: commit ea5b45b92c
- Web: commit ee6d631531
2022-08-24 07:40:04 +02:00
wmayer
2062f9ce87 clang: fix warnings [-Winconsistent-missing-override] 2022-08-09 17:36:25 +02:00
berniev
ddafb98813 Mod: Use override etc 2 2022-08-09 12:52:26 +02:00
berniev
b796a0d376 Mod: use empty 2022-08-06 19:30:13 +02:00
berniev
2d4c5a4cfb Mod: use emplace_back 2022-08-05 10:36:16 +02:00
wmayer
88e32eba9b App: changes in ComplexGeoData:
* rename some methods
* distinguish between Point and Vector
* support of arrays of Point or Vector
2022-08-03 16:18:14 +02:00
Uwe
88a06f8f10 Mod: remove some unnecessary nullptr checks 2022-07-18 12:58:12 +02:00
Uwe
1823439195 [Robot etc.] remove superfluous nullptr checks 2022-07-18 02:54:09 +02:00
wmayer
2b04b01edc cppcoreguidelines-special-member-functions
* disable move constructor and move assignment for several core classes
2022-06-25 17:46:48 +02:00
wmayer
7de296b60e cppcoreguidelines-pro-type-union-access
According to https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md#Ru-pun using union for type-punning is undefined behaviour.
  See also https://en.wikipedia.org/wiki/Type_punning#Use_of_union. Replace it with std::memcpy.
2022-06-25 17:17:04 +02:00
wmayer
5234d9bc67 App: add pure virtual methods to PropertyGeometry to delegate it to the geometry of sub-classes
Following the law of Demeter add some wrapper methods to PropertyGeometry and implement them in sub-classes. As a side-effect this makes some const_cast obsolete
2022-06-24 16:15:02 +02:00
wmayer
c955372ecf cppcoreguidelines-pro-type-union-access
According to https://github.com/isocpp/CppCoreGuidelines/blob/master/CppCoreGuidelines.md using union for type-punning is undefined behaviour.
 Replace it with std::memcpy
2022-06-24 14:29:50 +02:00
Uwe
28698a41e3 [Point] remove unnecessary Boolean comparisons 2022-06-19 17:10:55 +02:00
wmayer
216ed31d8a Points: fix round-off errors in pcd export 2022-05-17 11:48:58 +02:00
Zheng, Lei
3ef438eaf0 Fix mixed line endings 2022-04-26 12:52:55 -05:00
Chris Hennes
bac451cc53 Points: PR6497 move return statement to new line 2022-03-29 12:38:24 -05:00
wmayer
924d779fc7 Points: include header with export macros 2022-03-24 20:46:47 +01:00