Commit Graph

319 Commits

Author SHA1 Message Date
Stefan Tröger
526d895a5d PartDesign: Port body to be a origin group 2017-01-04 16:01:58 +01:00
Stefan Tröger
67d76b309c Port Attacher codde to the extension framework
AttachableObjects are desired in multiple occasions, and the current AttachableObject is not flexible enough to handle all cases. Hence the code is portet to an extension, which gives the needed flexibility.
2016-12-07 06:41:40 +01:00
wmayer
acec8d0385 fixes #0002782: Build error message 2016-11-19 14:27:55 +01:00
wmayer
7f3190889b issue #0002760: The result of an 'Undo' is shown too late. 2016-11-06 21:06:28 +01:00
Stefan Tröger
3e1ba47d61 Extensions: Handle new dynamic_cast's 2016-10-08 12:48:34 +02:00
Stefan Tröger
ab6151e71a Extension: Fix test case 2016-10-08 12:48:34 +02:00
Stefan Tröger
6fa964c53f Extensions: Introduce classes and port App groups 2016-10-08 12:48:34 +02:00
wmayer
dd7c91ddcf fix -Wextra in PartDesign 2016-09-22 18:34:56 +02:00
wmayer
c2dd2e2b99 fix Coverity issues 2016-08-21 18:46:40 +02:00
Wolfgang E. Sanyer
d1d2f1f811 This commit adds getShape and setShape to TopoShape 2016-08-06 23:42:55 +02:00
wmayer
f85c76f6d9 replace tabs with spaces 2016-07-15 10:44:19 +02:00
Sergo
ca3deae602 refuse to create partdesign objects if no active body in document 2016-07-15 10:35:52 +02:00
DeepSOIC
92ccefa1d2 Attacher: use getModeName() instead of eMapModeStrings[]
getModeName() does range checking. eMapModeStrings[] will crash if out
of range.
2016-05-07 11:24:41 +02:00
DeepSOIC
39249581eb Attacher: change suggestion routine interface
When another bit of information was needed to be extracted from mode
suggestion routine, it felt like listMapModes had too many arguments.
So, the arguments have been collapsed into a struct. This triggered a
few namespace-related changes, which lead to massive search-and-replace
changes all over FreeCAD.

So the only functional change carried out is the addition of reference
types readout to info returned by suggestor.
2016-05-07 11:24:41 +02:00
wmayer
f439a88c69 + remove 'using namespace Part' inside header file 2016-04-13 16:20:31 +02:00
wmayer
ab43e18b00 + remove 'using namespace Attacher' inside header file 2016-04-13 15:57:49 +02:00
Stefan Tröger
c40d25c87f PartDesign: Fix body command 2016-04-12 18:12:23 +02:00
Stefan Tröger
3e79c09d10 Fix rebase error 2016-04-12 18:12:23 +02:00
Stefan Tröger
815a8e4d30 Remove ShapeBinder2D
As profile based features can work with faces and wires now ShapeBinder can do everything that needed ShapeBinder2D before.
2016-04-12 18:12:23 +02:00
Stefan Tröger
12e793bde8 PartDesign: Adopt pattern to face based features 2016-04-12 18:12:22 +02:00
Stefan Tröger
ae9dac71d7 PartDesign: Modeling features work with faces
-Rename Sketchbased to ProfileBased to show new behavior
-Adopt ProfileBased to make the relevant helper functions work with faces too
-Adopt features for unified use of helper functions
-Adopt commands to allow face selection
2016-04-12 18:12:22 +02:00
Stefan Tröger
732834c6d8 Handle external references for revolution et all
The reference selection, used in multiple part design features, treated body external references not corectly.
2016-04-12 18:12:22 +02:00
Alexander Golubev
27667cf5e6 Fix warnings introduced in new PartDesign
Mostly unused wariables and compare of signed & unsigned
2016-04-12 18:12:21 +02:00
Stefan Tröger
f058ae12e9 fix sketch classification for other body
hasObject does search recursive only in groups, but a body is not a group. Hence for sketches within a body this will always return false. Annother logic must be used to detect sketches in bodies.
2016-04-12 18:12:21 +02:00
Stefan Tröger
571e5d55d2 fix sketch selection in part design
validateSketch was faulty: as every sketch is valid (non is removed) it could happen that the returned number was >0 but the iterator firstValidSketch was NULL nontheless. The routine needed to be udated to make snese and the usage in prepareSketchbased together with it.
2016-04-12 18:12:21 +02:00
Stefan Tröger
ad5785654e add only a single reference copy 2016-04-12 18:12:21 +02:00
Stefan Tröger
d878028c60 Fix sketch on face of other body or part
The shapebinder object reduces the number of faces to 1, hence the subshape to select is always Face1 and not the original face name
2016-04-12 18:12:21 +02:00
Stefan Tröger
3b43f2cdc5 fix body booleans 2016-04-12 18:12:20 +02:00
Stefan Tröger
f2ad7bde4b PartDesign/Gui: minor fix sWhatsThis of text 2016-04-12 18:12:20 +02:00
Stefan Tröger
08287504fa Fix crossreference handling 2016-04-12 18:12:20 +02:00
Stefan Tröger
a8781fdacc handle independent copies more gracefully 2016-04-12 18:12:20 +02:00
Stefan Tröger
afc666e587 change point of reference feedback for datums
On datum creation it is better to ask the user on OK than on tool activation, as he might hit cancel (and then the created references are till there) or even more important, he could add additional external references within the dialog. The disadvantae is that if the user sets "cross reference" ge gets asked again every time he opens and leaves the dialog.
2016-04-12 18:12:20 +02:00
Stefan Tröger
4e1a9c05cb ask user if he creates inter part/body references 2016-04-12 18:12:20 +02:00
Stefan Tröger
00b230fdf8 Setup ShapeBinder Viewprovider and command 2016-04-12 18:12:19 +02:00
Stefan Tröger
b610dcc97c fix dependent copy references
to make them work with sketches an additional Part2DObject reference needed to be created
2016-04-12 18:12:19 +02:00
Alexander Golubev
3ed51ac4bd PartDesign: add Origin to the Body and unstrap the module from the Parts 2016-04-12 18:12:18 +02:00
Alexander Golubev
d72a919384 OriginGroup: add new abstraction layer between the Part and the GeoFeatureGroup 2016-04-12 18:12:18 +02:00
Alexander Golubev
305151be34 App/Origin: big refactoring
- Rebase App::Origin on App::DocumentObject
 - Keep all control over the Origin structure inside the Origin and it's
   ViewProvider
 - Add OriginFeature class as common base for App::Plane and App::Line
 - Rebase App::Plane and App::Line on top of newly created class and
   move to the file.
 - Change Origin's ViewProvider API associated with temporary display
 - Lots of associated changes to files
 - Several minor fixes
 - Lots of new bugs
2016-04-12 18:12:18 +02:00
Alexander Golubev
067530c168 PartDesign/Gui: Make partDesign's add sketch command Workflow-aware 2016-04-12 18:12:17 +02:00
Alexander Golubev
771c2b2fce PartDesign/Gui: rename some fonctions in ReferenceSelection.cpp
e.g. getPythonStr -> buildLinkListPythonStr etc
2016-04-12 18:12:17 +02:00
Alexander Golubev
9347f66a9e PartDesign/Gui: Move various utility stuff from Workbench to a separate file
Also do some header cleanup.
2016-04-12 18:12:17 +02:00
Alexander Golubev
3fff7c6ef2 PartDesign/Gui: move body commands to a separate file 2016-04-12 18:12:16 +02:00
Alexander Golubev
f6b0ed3a47 PartDesign: Body rework - add BaseFeature property and make Tip always point to solid 2016-04-12 18:12:16 +02:00
Alexander Golubev
af385f1c57 PartDesign/Feature: add an optional parameter to getBaseObject() to prevent it from throwing exceptions
In most cases getBaseObject() is used with an exception handler which
only detects if it failed but not the reason. This modification allows
to use it without excess exception handlers.
Also add the same parameter to SketchBased::getVerifiedSketch().
2016-04-12 18:12:15 +02:00
Alexander Golubev
64783a4ee5 PartDesignGui: move shared code for all dressUp features into common place.
Also this allows the old workflow for thickness and draft features.
2016-04-12 18:12:15 +02:00
Alexander Golubev
5e5c1ece40 PartDesign/Gui: enable sketches on datum planes inside bodies 2016-04-12 18:12:14 +02:00
Alexander Golubev
f9fe1e319f PartDesign/Gui: more old workflow support
* remove an error message if adding a sketchbased feature without a body
* add champfer or fillet old workflow support

Also rework finishFeature() so at least champfer and fillet may be
inserted into any place of any apropriate body(not only the active one) of the body.
2016-04-12 18:12:14 +02:00
Alexander Golubev
974a434e1f PartDesign/Gui: enhance the TaskFeaturePick with new cotegory of sketches: notInBody
Also add option tp show already used sketches and fix some spacing.
2016-04-12 18:12:14 +02:00
DeepSOIC
cd4dce2f1b PartDesign workflow without part/body
PartDesign: make datum features work outside of body/part
PartDesign old workflow: remove a few messageboxes about no part
PartDesign: old workflow: multitransform without body

Still has visibility issues, but generally works.
2016-04-12 18:12:14 +02:00
Stefan Tröger
b8ccce827e prevent part design features from accidently cross referencing 2016-04-12 18:12:14 +02:00