Commit Graph

985 Commits

Author SHA1 Message Date
Abdullah Tahiri
33620d212e Part: Geometry extension set with unique id (type+name) and list based getExtensions python 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
11793ba0b2 Part Geometry: get an extension from type or name, also from python 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
afbe1df322 Part:: Geometry container extend hasExtension to type and name 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
854452e2e1 Part: Geometry - methods to remove extensions by name and type 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
8b5e9b55c0 Part: Default geometry extensions make sure built-in types are initialised 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
dece5aa81d Part: Command to show list of extensions from Python 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
234d542c1a Part: Fix assignment after reserve of weak_ptr causes segfault 2019-07-14 12:37:33 +02:00
Abdullah Tahiri
beec449180 Part: Extend Geometry Extension to have a name 2019-07-14 12:37:31 +02:00
Abdullah Tahiri
5f46862caa Part: correct long parsing in GeometryIntExtensionPyImp 2019-07-14 12:37:31 +02:00
Abdullah Tahiri
41ad1fe0a1 Part: Geometry extension const correctness 2019-07-14 12:37:31 +02:00
Abdullah Tahiri
c670ef9793 Part: Move default geometry extension for int to internally use long 2019-07-14 12:37:31 +02:00
Abdullah Tahiri
69c3b7d4f8 Part: Default geometry extension template encapsulate value 2019-07-14 12:37:31 +02:00
Abdullah Tahiri
fb5e8b4df7 Part: GeometryDefaultExtensions template
========================================

Generalisation of code for a default geometry extension in the form of a template.

Default geometry extensions provide a standard interface for an extension having a single stored value (e.g. one int or one string).

Python implementation must be provided separatedly.
2019-07-14 12:37:31 +02:00
Abdullah Tahiri
9bb2210c92 Part: Geometry extensions set interface
=======================================

unique_ptr is a move only type. Therefore it may only take an rvalue.

It does not make sense a pass by value for move only types (Item 41).
2019-07-14 12:37:31 +02:00
Abdullah Tahiri
460bb59320 Geometry extensions: remove unnecessary smart pointer deletion
==============================================================

When the geometry object is destroyed, std::vector's destructor is called, which in turn calls the destructor of the smart pointers.

If a weak_ptr corresponding to one of those shared_ptr is locked (elsewhere, if FC were multithread),
the underlaying resource will not be freed until said locked weak_ptr goes out of scope. It will then.
2019-07-14 12:37:31 +02:00
Abdullah Tahiri
b5f5d1c32f Part: GeometryStringExtension to extend a geometry by a string 2019-07-14 12:37:30 +02:00
Abdullah Tahiri
9cb2863a2e Part: Expose GeometryIntExtension python type 2019-07-14 12:37:30 +02:00
Abdullah Tahiri
7828c34ffe Part: Standard geometry extension adding an integer value 2019-07-14 12:37:30 +02:00
Abdullah Tahiri
1e2c627f26 Part: Excise GeometryExtension from Geometry 2019-07-14 12:37:30 +02:00
Abdullah Tahiri
ef30cc2527 Part: Geometry Python interface to get/set an extension 2019-07-14 12:37:29 +02:00
Abdullah Tahiri
2c65c5681f Part:: Bug fix in geometry set extension 2019-07-14 12:37:29 +02:00
Abdullah Tahiri
718d79fa94 Part: Geometry Extension Python object 2019-07-14 12:37:29 +02:00
Abdullah Tahiri
aedfb6a6a3 Geometry Extension based on smart pointers 2019-07-14 12:37:28 +02:00
Abdullah Tahiri
f977f47de3 Geometry: Extensions - release any allocated dynamic memory 2019-07-14 12:37:28 +02:00
Abdullah Tahiri
2400d63d70 Part: Geometry Extensions 2019-07-14 12:37:28 +02:00
wmayer
787f5184e8 Parametric refinement feature 2019-07-08 14:37:00 +02:00
wmayer
1031644fab improve doc string of Part.sortEdges 2019-06-20 14:41:50 +02:00
wmayer
3590b65b33 issue #0003921: Crash when opening document with datum point intersecting line and plane 2019-06-16 19:31:06 +02:00
wmayer
fb94e46db9 improve exception handling Shape.distToShape 2019-06-13 21:49:13 +02:00
wmayer
1b26173580 use INCH instead of IN when setting units for STEP or IGES export 2019-06-13 12:40:01 +02:00
wmayer
b60a736c0d fixes 0004010: Box Selection + Part -> MakeCompound will crash FreeCAD 2019-06-12 11:20:48 +02:00
Abdullah Tahiri
aa9cd0d91c Partial Restore: ensure line segment length when x coordinate is exactly zero
fixes #4012
2019-06-08 16:52:49 +02:00
wmayer
13480d6d9c do some security checks to make sure Py::Module is valid 2019-06-03 17:57:52 +02:00
wmayer
f6ee90557d also support shapetype parameter in Part.makeRevolution() if first argument is an edge 2019-05-12 11:33:38 +02:00
Abdullah Tahiri
a56658489b Part: Make 3rd party libraries into PCH 2019-05-02 07:09:22 +02:00
wmayer
43bdef67d6 continue PCH on Part module 2019-05-01 16:10:38 +02:00
Abdullah Tahiri
3f42ee7664 Part: Missing PCH header 2019-04-30 15:35:25 +02:00
tomate44
fe56e51e08 add a python method to cut holes in a Part.Face, from a list of wires 2019-04-29 12:33:43 -03:00
wmayer
0ed5b77917 activate pCH on Part module 2019-04-28 15:33:25 +02:00
luz.paz
e7489c079c More misc. typos 2019-03-31 11:42:37 +02:00
joha2
881756079c MeshToSolid: progress indicator and slightly modified sewing tolerance dialog 2019-03-31 11:30:03 +02:00
luz.paz
e04ba4e4a1 Add some more user-facing typo fixes 2019-03-22 10:44:14 -03:00
wmayer
87bf7094a5 PVS: V601 The bool type is implicitly cast to the double type
PVS: V668 There is no sense in testing pointer against null, as the memory was allocated using the 'new' operator. The exception will be generated in the case of memory allocation error
2019-03-13 14:09:10 +01:00
wmayer
d3631968ab add method to Python interface to get reflect lines of a shape 2019-02-25 10:50:38 +01:00
wmayer
e55b718cd6 fixes 0003694: Part->Boolean->Cut should show error message if a non-solid (Shell, etc.) is selected 2019-02-21 16:55:59 +01:00
wmayer
997d1d7d51 fixes 0003846: unexpected result in building RuledSurface 2019-02-19 15:53:39 +01:00
wmayer
90c80f83fd PVS: V522 There might be dereferencing of a potential null pointer 'Py::Vector2d().getCxxObject()' 2019-02-18 00:00:10 +01:00
wmayer
1e343d339f PVS: V779 Unreachable code detected. It is possible that an error is present. 2019-02-17 20:12:56 +01:00
wmayer
f581d5c8cb PVS: V560 A part of conditional expression is always true 2019-02-17 13:56:48 +01:00
wmayer
0c3bfc4ff3 fix minor issues 2019-02-12 11:16:52 +01:00