Commit Graph

25 Commits

Author SHA1 Message Date
Jonas Bähr
34b176c1db Remove C++ escaping from *Py.xml templates
Now all escaping required for the C++ code generation is done when the
.cpp/.h files are generated. Previously, only newlines were escaped
automatically. This was a) inconsistent and b) leaked c++ details into
the xml data.
In addition, the escaping is now done in one central place, harmonizing
the three previous implementations.

Pre-existing c++ escape sequences in the XML files have been replaced by
their literal equivalent so that the resulting python doc sting remains
unchanged.
2023-08-16 13:17:25 +02:00
luzpaz
79e150a81b Fix trailing whitespace, typos, headers
Fix trailing whitespace, typos, and header uniformity.
2023-01-23 00:34:37 +01:00
wmayer
f039789d0b Base: add overloaded method isIdentity() to Rotation and Placement that accepts a tolerance 2023-01-03 10:54:47 +01:00
wmayer
68f760d958 Base: [skip ci] improve whitespaces 2022-08-15 11:42:26 +02:00
marioalexis
f5c5de9d61 Base: Fix wrong function name in RotationPy documentation. 2022-06-20 02:12:16 +02:00
luz paz
a526451afd Fix various typos 2022-06-01 18:03:40 -04:00
marioalexis
d6981c228a Base: Improve docstrings in RotationPy.xml 2022-05-29 10:34:59 +02:00
wmayer
e424faa131 Base: harmonize Python API of Rotation class 2021-10-27 10:40:35 +02:00
wmayer
497c1895e8 Base: [skip ci] expose Rotation.fromEuler() to Python 2021-10-27 00:34:36 +02:00
Zheng, Lei
37d6752404 Base: add new API Rotation::get/setEulerAngles()
Exposed to Python as new constructor parameters and
Rotation.toEulerAngles()

This function uses the code from OCCT
gp_Quaternion::Get/SetEulerAngles() to support all 24 possible
generalized euler rotation sequences. Call Rotation.toEulerAngles()
without argument to obtain all possible sequence types.
2021-05-02 17:20:45 +08:00
wmayer
a276bf46ee expose Roation.slerp to Python 2019-10-11 01:14:35 +02:00
wmayer
6222cb310b add method RotationPy.toMatrix() 2019-10-07 19:27:54 +02:00
Zheng, Lei
cc94eb9966 Base: add RotationPy.RawAxis
Expose rotation raw axis
2019-10-07 17:24:31 +02:00
Zheng, Lei
ff3ec0c7fd Base: add Python number protocol support to Placement/Rotation 2019-09-28 15:32:00 +02:00
wmayer
3726006942 fix implementation of Rotation::isSame(const Rotation& q, double tol) and extend Python bindings 2019-09-10 14:17:07 +02:00
wmayer
df0a3ded78 rename Placement.isNull to Placement.isIdentity
implement Rotation.isNull and Rotation.isIdentity
2017-12-13 17:00:38 +01:00
DeepSOIC
62b0d35270 Base: new Rotation constructor - on vectors
The new constructor accepts wanted directions of x,y,z axes of rotated
frame, and a priority string that affects how the vectors are made
perpendicular to each other.

Example - construct placement for sketch on XZ plane:

v = App.Vector
App.Rotation(v(1,0,0),v(0,0,1),v())
2017-09-10 18:31:40 +02:00
wmayer
f3226a0867 + fix == operator of Rotation class, + add method isSame() 2016-05-18 18:08:40 +02:00
wmayer
c3c11a9b81 + implement rich compare protocol of Python interface for Placement & Rotation 2016-05-18 11:26:27 +02:00
Sebastian Hoogen
ba0f2a765c document the convention used for Euler angles (XY'Z'')
in the Placement dialog and the docstrings of the Rotation python class.
fixes #2007
2015-03-21 13:29:32 +01:00
wmayer
707bc8a6a5 + allow to modify placement via sub-attributes 2014-12-02 19:19:23 +01:00
wmayer
9ef32aab8e + fixes #0001536: Feature.Placement.Rotation.isNull() touches the Feature 2014-05-08 18:52:08 +02:00
wmayer
24ca68514b 0001018: Possible inconsistencies between Euler angles, quaternion and matrix 2013-03-03 13:27:27 +01:00
Sebastian Hoogen
38333cf048 add isNull() method to Rotation 2012-05-15 18:01:15 +02: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