Commit Graph

51 Commits

Author SHA1 Message Date
Tobias Frost
7a5a3d1ffc spelling fixes (#18688)
* Fixes spelling of "Allow to" to "Allow one to"

and those variants:
Allows to -> Allows one to
allow to -> allow one to
allows to -> allows one to

* Fix "Let's -> Lets"

(and lower case variant.)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update src/3rdParty/salomesmesh/inc/MED_Wrapper.hxx

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

* Update src/Base/PyObjectBase.cpp
Update src/App/ExtensionContainer.h
Update src/App/PropertyContainer.h

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

* Use gerund in user-facing texts.

* Use gerund for two more user-facing strings.

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

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

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

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

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

* Update src/Mod/Fem/App/FemMeshShapeNetgenObject.cpp

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

---------

Co-authored-by: Tobias Frost <tobi@debian.org>
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-01-13 11:22:20 -06:00
Ladislav Michl
f1fdd2e2a9 Base: Replace if else with switch statement 2024-01-21 16:14:12 +01:00
Ladislav Michl
95b37fa806 Base: Do not use else before return 2024-01-21 16:14:12 +01:00
pre-commit-ci[bot]
dd1db1e23e [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2024-01-13 09:59:54 -05:00
edi271
6b68344af8 [TD] extend App.Vector API 2024-01-13 09:59:54 -05:00
edi271
9a9803c9f9 [base] Extend Vector by isParallel function 2024-01-13 09:59:54 -05:00
hasecilu
04dc68218b Add ':' to TODOs to activate highlight
Some linters have a special highlightning on "TODO:" comments.
2023-12-19 17:01:17 -06:00
wmayer
7c00932fa0 fix readability-isolate-declarations 2023-11-16 01:22:08 +01:00
wmayer
5c306f6e2a fix readability-*:
* readability-uppercase-literal-suffix
* readability-named-parameter
2023-11-16 01:22:08 +01:00
wmayer
e85c383bff Base: apply clang format 2023-11-13 12:01:26 -05:00
wmayer
010dca8303 Base: C++ core guidelines: init variables 2023-08-24 18:48:52 +02:00
wwmayer
560752cd80 Base: fixes #8902: Segfault from Part WB functionality in python scripting (#8927) 2023-03-17 22:50:30 +01: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
wmayer
f37574e809 Base: raise TypeError if Vector is multiplied with unsupported type 2022-06-04 13:21:04 +02:00
wmayer
b39c6f62b4 Base: replace several reinterpret_cast 2022-05-11 20:01:40 +02:00
wmayer
9160f06e1c Base: rename BaseExceptionFreeCADError to PyExc_FC_GeneralError 2022-03-17 14:45:48 +01:00
wmayer
e4435cdcba Base/App: fix warnings from code analysers:
* convert old-style-casts to explicit C++ casts where possible
* make some implicit conversions explicit
2022-03-06 23:49:30 +01:00
wmayer
4d87039635 Base: modernize C++11
* remove redundant void-arg
* use nullptr
* replace deprecated headers
2022-01-25 20:21:30 +01:00
wmayer
44ffc4653f Base: [skip ci] use PyNumber_Check instead of PyFloat_Check/PyLong_Check to check for numbers 2021-09-30 14:22:56 +02:00
luz paz
142c2c2c4d Base: remove Py2 code 2021-04-26 09:23:58 +02:00
luz paz
d5f6c096b8 Base: Fix header uniformity, whitespace, and doxygen
[skip ci]
2020-11-22 18:12:16 +01:00
Eric Trombly
5ecbc89f30 change isOnLine to isOnLineSegment 2020-04-06 06:34:53 -05:00
Eric Trombly
5f648aa2c1 remove sleep calls, change some for loops to list comp, move isPointOnLine to base vector 2020-04-06 06:34:53 -05:00
Zheng, Lei
43e0d96160 Base: remove VectorPy right multiplication to matrix/placement/rotation 2019-10-07 17:24:30 +02:00
Zheng, Lei
83284a3cdd Base: add Python number protocol support to Placement/Rotation 2019-09-28 15:32:00 +02:00
Zheng, Lei
783947ecd4 Base: improve base python object number protocol 2019-09-28 15:30:23 +02:00
wmayer
83f61b4372 implement true divide handler of the number protocol for Quantity 2018-10-27 15:27:27 +02:00
wmayer
f231871cb0 replace epsilon to check for null vector 2018-09-11 11:33:38 +02:00
Mark Ganson TheMarkster
41102edf67 fix bug in draft path array
put lnodes.normalize() inside try/except block
replace hard-coded 1e-6 with Vector3d::epsilon() in VectorPy::normalize()
2018-09-11 11:11:39 +02:00
wmayer
840c9e8b3c prepare for PyCXX 7.0 2018-04-18 19:20:50 +02:00
wmayer
78c9a34f50 fix compiler warning 2018-01-08 19:55:07 +01:00
wmayer
9e2fa2d91a support some more handlers in VectorPy and throw better exceptions for unsupported operators 2018-01-01 15:45:21 +01:00
wmayer
012cffefe8 implement slicing for VectorPy class 2017-08-21 15:16:03 +02:00
wmayer
e7c7c07cda implement object serialization for Vector class 2017-06-22 21:52:53 +02:00
Yorik van Havre
0e9e49cbcc py3: Base: files R-Z ported to python3
issue 0000995
2017-05-21 12:35:41 +02:00
Kurt Kremitzki
5c619ee285 Handle right and left hand scalar-vector multiplication 2016-12-28 13:20:03 +01:00
wmayer
f408f3180b fix -Wextra in FreeCADBase 2016-09-21 15:02:02 +02:00
wmayer
aea769af3d use a stricter tolerance to check for equal points
add method IsEqual to Vector3 class to support user-defined tolerance
2016-08-15 14:09:26 +02:00
wmayer
1e2e24b652 + rename methods in Vector3 class
+ add convenience methods Cross and Dot to Vector3 class
+ fix bug in DistanceToLineSegment in Vector3 class
2016-07-30 15:14:47 +02:00
wmayer
732eb7fee3 support any sequence type in init method of Vector class 2016-07-27 09:23:20 +02:00
Sebastian Hoogen
5e51a6cdf7 fixes #0001422: Subclass Exception
inherit Base.FreeCADError form RuntimeError
inherit Part.OCCError from Base.FreeCADError
inherit OCCDomainError from Part.OCCError
inherit OCCRangeError from Part.OCCError
inherit OCCConstructionError from OCCDomainError
inherit OCCDimensionError from OCCDomainError
Added PY_CATCH_OCC macro
replace PyExc_Exception
use FreeCADError in makeWireString
catch exception in BSplineCurve.increasedegree
2014-09-17 11:15:56 +02:00
wmayer
89b5d7e6f1 + extend number protocol 2014-02-14 13:53:47 +01:00
wmayer
e916d65a5c + extend number protocol 2014-02-14 13:45:56 +01:00
wmayer
98bab1ebbe + extend number protocol 2014-02-14 12:46:30 +01:00
Yorik van Havre
a81c16c391 Exposed vector negative to python 2013-07-30 12:17:06 -03:00
wmayer
a882476c25 Add distanceToPoint to VectorPy 2013-07-17 16:41:09 +02:00
wmayer
b63f9d7a2b 0001152: The output of __repr__() of Vector and Rotatio would create Objects with different Values do to inapropriate rounding 2013-06-17 13:21:25 +02:00
wmayer
f22fc55363 Return a NotImplemented exception when comparing Matrix or Vector with other types 2012-03-13 08:49:01 +01:00
wmayer
44147e71ab 0000623: Matrix and Vector API extension 2012-03-11 16:22:17 +01:00
wmayer
d102002bdf Make new method in Vector3 accesible from Python 2012-02-24 19:43:44 +01:00