Commit Graph

36 Commits

Author SHA1 Message Date
wmayer
e40b2c7470 disable tip handling in PD view providers when start or finish editing 2018-02-10 00:46:30 +01:00
wmayer
f139966868 make green for tip a bit darker 2018-02-01 19:30:25 +01:00
Abdullah Tahiri
3ea4debaf3 PartDesign: Highlight body tip
==============================

It generates a small green icon on the treeview for those features being the tip of the body.
2018-02-01 19:15:48 +01:00
Abdullah Tahiri
2ad1653a3f PartDesign: OnDelete basefeature fixing and visualization
=========================================================

fixes #3084
fixes #3061 (at least what it is understood in the analysis as being a bug, the visualization left).

Basically when deleting a feature, if it is the base feature (feature with which it will merge or cutout), the dependent objects'
base feature is made to be the base feature of the object being deleted. This code pre-existed at body level, but was not being called (see below).

Additionally, if the visible object is not the one being deleted, we leave that one visible. If the visible object is the one
being deleted, we make the previous object visible.

Deletion from the tree of a feature is handled by Document.removeObject, which has no clue about what a body is. Therefore, Bodies, although an
'activable' container, know nothing about what happens at Document level with the features they contain.

The Deletion command StdCmdDelete::activated, however does notify the viewprovider corresponding to the feature (not body) of the imminent deletion
(before actually doing it). Consequently, the only way of notifying a body of the imminent deletion of one of its features so as to do the clean up
required (moving basefeature references, tip management) is from the viewprovider of the feature being deleted.
2018-01-22 22:03:18 +01:00
luzpaz
8200c97ed2 Fix Techdraw UI typo found via crowdin + misc. typos
Ref: https://crowdin.com/translate/freecad/27911/en-eu#6503377
2017-11-26 15:48:20 +01:00
Stefan Tröger
903a71c8d4 PartDesign: Boolean must show the operation result, not the children. fixes #0003184 2017-09-21 10:48:38 +02:00
DeepSOIC
096eb67b47 PartPesign: Py: expose some methods of ViewProvider
* setBodyMode(bool)
* makeTemporaryVisible(bool)
2017-03-04 19:16:39 -03:00
DeepSOIC
5e5b3f8b61 PartDesign: add ViewProviderPython
+ bind PartDesign::Feature to PartDesign::ViewProvider, and adjust
viewprovider of PartDesign::FeaturePython accordingly.
2017-03-04 19:16:39 -03:00
Stefan Tröger
526d895a5d PartDesign: Port body to be a origin group 2017-01-04 16:01:58 +01:00
wmayer
af314cd04f avoid to create a circular dependency when modifying an existing pad or pocket operation 2016-12-28 17:05:20 +01:00
Sergo
40a8f1cd66 PartDesign: fix showing base object on newly opened file, cleanup 2016-09-30 11:09:01 -03:00
Stefan Tröger
97a51686c7 PartDesign: Adopt primitive preview
The preview was developed when the "one feature only" visibility rule was not yet introduced. This commit maks it work again.
2016-04-12 18:12:23 +02:00
Stefan Tröger
48b2bb86ab PartDesign: body is responsible for visuals
-Hide all visual properties of features when they are part of a body
-Propagate all body visual changes to features
-Separate display mode from body mode to enable setting display mode for both "tip" and "through" modes
-Use default visuals for body shape and only make "through" a new display mask mode for the children
2016-04-12 18:12:23 +02:00
Stefan Tröger
73ab046ad6 Ensure only a single PartDesign feature is visible 2016-04-12 18:12:22 +02:00
Alexander Golubev
b41a7881ab PartDesign/ViewProvider: minor enhancements 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
5239f3447c PartDesign/Gui: start to unify view providers code
- Moved all common code for part design features view providers to a base
   class.
 - Move shared code for Sketch based features to newly created
   ViewProviderSketchBased class
 - Add ViewProviderSketchBased to initialization
 - Make Pad and Pocket ViewProviders to use the shared code
 - Minor fixes to TaskFeatureParameters and some derived classes
2016-04-12 18:12:15 +02:00
Stefan Tröger
b0817ff086 allow non-sketch based additive and subtractive features 2016-04-12 18:12:06 +02:00
blobfish
9b9d79d2fe Part Design: adding const char PDBODYKEY and using. No functional change. 2016-04-12 18:12:04 +02:00
jriegel
d7c932d714 Changing active object handling in PartDesign 2016-04-12 18:12:03 +02:00
jrheinlaender
3d4c853def Fix bug in workbench 2016-04-12 18:11:56 +02:00
jrheinlaender
780f27a529 Fixed bug that didn't clean up the Body when deleting an object from it 2016-04-12 18:11:54 +02:00
jrheinlaender
2732f44b42 Miscellaneous fixes 2016-04-12 18:11:51 +02:00
jrheinlaender
5215a6da0b miscellaneous fixes 2016-04-12 18:11:50 +02:00
jrheinlaender
4addc00d97 Drop into insert mode when user double-clicks on a PartDesign feature in the Tree 2016-04-12 18:11:50 +02:00
jrheinlaender
5ebdc82b5d Moved unsetEdit() to ViewProvider to avoid code duplication in all feature ViewProviders 2016-04-12 18:11:50 +02:00
jrheinlaender
5ac8aeaf2c Moved some methods from PartDesign::Body to Part::BodyBase so the SketchObjects will be removed cleanly from the Body when deleted 2016-04-12 18:11:49 +02:00
jrheinlaender
0cd8fc816b Bug fixes for Body feature insert/remove functionality 2016-04-12 18:11:48 +02:00
jrheinlaender
8390bbb999 Work on inserting, removing, hiding and showing features in the body 2016-04-12 18:11:48 +02:00
wmayer
0072f7b942 + fix crash when trying to edit broken revolve object 2014-07-12 16:13:13 +02:00
wmayer
070f9ad47a Open transaction when start editing with context-menu 2012-11-28 13:24:46 +01:00
wmayer
851e999eac 0000545: Undo revolve causes crash illegal storage, fix disappearing shape after undo/redo 2012-09-21 13:05:37 +02:00
wmayer
72ae257ac4 Filter out AddShape property in PartDesign view provider 2012-02-23 11:06:26 +01:00
jriegel
72bfc3c74b + Add fillet dialog
+ fix undo/redo bug in edit PartDesign features 
+ partially clean up module dependency in ViewProvider base class

git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5108 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-11-09 23:23:10 +00:00
wmayer
c7985e5c06 + rework edit modes
git-svn-id: https://free-cad.svn.sourceforge.net/svnroot/free-cad/trunk@5102 e8eeb9e2-ec13-0410-a4a9-efa5cf37419d
2011-11-08 21:15:49 +00: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