Commit Graph

7260 Commits

Author SHA1 Message Date
Alexander Golubev
e96af480ea PartDesign/TaskDressUpParameters: disable edit of dressup features with broken supports
Also remove unused headers and fix spacing.

A final fixup for issues addressed in:
cb05b01 PartDesign/TaskDressUpParameters: fix a crash when editing a broken object
2016-04-12 18:12:15 +02:00
Alexander Golubev
6134952a46 PartDesign/Gui: make DressUp view providers use the common code. 2016-04-12 18:12:15 +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
bba3733086 PartDesign/Gui: share code for revolution and groove view providers 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
Alexander Golubev
4e2655571e PartDesign/ViewProviderDatum: minor fix in a comment 2016-04-12 18:12:15 +02:00
Alexander Golubev
15b6eccc00 PartDesign/FeatureDressUp: implement a proper getBaseObject()
The function getBaseShape() is removed and replaced with getBaseObject()
because it doesn't make a lot of scense: getBaseShape() masked the
base's class implementation (rather than redefine a virtual) which was
better in words of code reuse.

Also BaseFeature and Base properties relations are defined now in a
little another way.
2016-04-12 18:12:15 +02:00
Alexander Golubev
e16534eeb2 PartDesign/TaskDressUpParameters: fix a crash when editing a broken object 2016-04-12 18:12:15 +02:00
Alexander Golubev
984b0dd715 PartDesign/Task{Pad,Pocket}Parameters: massive refactoring
Give a massive refactoring to Task dialogs for pocket and pad.
This commit features:
 * Make Task dialogs for pocket and pad look nice in side-by side diff and
   cross import features missing in each other.
 * As a result it fixes several minor bugs.
 * Gives a rework to the UpdateUI function.
 * This one also fixes offset option support and migrates it to use unit
   framework.
2016-04-12 18:12:15 +02:00
Alexander Golubev
c51d22eb8f PartDesign/ViewProviderPad: removed unfinished reimplementation of doubleClick()
This one resulted in non proper reject of pad dialog. Because the
command transaction haven't started.
2016-04-12 18:12:15 +02:00
Alexander Golubev
595f1e19f4 PartDesignGui: move signal connections in several parameter dialogs after ui initialization 2016-04-12 18:12:15 +02:00
Alexander Golubev
180985cec0 PartDesignGui: Make DressUp and SketchSupport propertie dialogs use common accept() structure 2016-04-12 18:12:15 +02:00
Alexander Golubev
d03c6c82a4 PartDesign/TaskThicknessParameters: fix copy-paste mistake in dialog 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
6778c548f4 PartDesign: move common code for TaskDlg{SketcherBased,DressUp}Parameters into new base class
Added a new class: TaskDlgFeatureBased which currently contains common
code for TaskDlgSketcherBasedParameters::reject() as well as the same
methode for TaskDlgDressUpParameters.
It's likely that other Feature task dialogs will inherit this class too.
2016-04-12 18:12:15 +02:00
Alexander Golubev
ebfd298baf PartDesign/FeatureDressUp: make Base and BaseFeature properties track the same feature
Also remove reseting of read-only flag on placement properties on
removing Base feature: it doesn't make any scense for dressup features.
2016-04-12 18:12:15 +02:00
Alexander Golubev
ccfc18946d PartDesign: fix a crash in the loft 2016-04-12 18:12:14 +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
b9983d5d2d PartDesign/Gui/TaskDlgSketchBasedParameters: emhance object hiding/unhiding on reject() 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
Alexander Golubev
340c52a939 Share code for finding a body containing a feature 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
DeepSOIC
92a7811618 Revolution: fix failure on sketch edges used as an axis
PartDesign Revolution used to fail, when an edge of a sketch was
selected as an axis of revolution. This is fixed by this commit.
Also, made it support selecting an edge from the sketch the revolution
itself is made from.
2016-04-12 18:12:14 +02:00
DeepSOIC
ae81e7d4c9 PartDesign: Make groove work via Revolution ui
Purpose: remove duplicate code.
Remaining: wrong title and icon in task dialog.
2016-04-12 18:12:14 +02:00
DeepSOIC
3d93c906d1 PartDesign: rework axis and plane comboboxes and make it work without part.
Rework combobox filling and link hadling for revolution and transformed features, in order to get rid of hard-coded item indexes and make the lists more dynamic.
2016-04-12 18:12:14 +02:00
DeepSOIC
c940ee8674 PartDesign: disable migration
Temporary. Later, a way to manually invoke it should be made.
2016-04-12 18:12:14 +02:00
DeepSOIC
801857e98f Fix rebase mistake, application startup related
Caused docking restore problems, and probably toolbar state restoration
too.
See post 116 of thread "Test Request: Part Design Workflow" (
http://forum.freecadweb.org/viewtopic.php?f=20&t=11205&start=110#p95619
)
2016-04-12 18:12:14 +02:00
Alexander Golubev
118f3d2ebb remove unneeded sketcher tools from part design
Previously similar patch was commited by Stefan Tröger <stefantroeger@gmx.net> but lost during rebase.
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
Stefan Tröger
1711dd4739 fix independent copy and cross reference 2016-04-12 18:12:14 +02:00
Stefan Tröger
a2dba9be6e first take on enhanced feature pick task 2016-04-12 18:12:14 +02:00
blobfish
28bb00d9e2 Core: Gui: DAGView: windows compile fix 2016-04-12 18:12:13 +02:00
Stefan Tröger
f62b8fa6a6 fix loft top face location 2016-04-12 18:12:13 +02:00
Stefan Tröger
ac5307cbd3 fix loft tool naming 2016-04-12 18:12:13 +02:00
Stefan Tröger
73e1982154 fix datum crash when origin is selected 2016-04-12 18:12:13 +02:00
Stefan Tröger
6245935d72 fix loft result orientation 2016-04-12 18:12:13 +02:00
Stefan Tröger
aa7098cf75 fix pipe tool result orientation 2016-04-12 18:12:13 +02:00
Stefan Tröger
5b44e38c89 remove linear and S-shape scaling from pipe
They worked and are nice feature, but the handling with properties must be worked out better. To avoid any incompatibility due to property changes the functionality is removed now.
2016-04-12 18:12:13 +02:00
Stefan Tröger
c2a73bbfe2 fix body and part tool texts 2016-04-12 18:12:13 +02:00
blobfish
b2d4f80b19 Core: Gui: DAGView: Various changes. See Following.
Font size hack for windows DPI workaround
    Adding optional layout direction
    Basic filter framework.
    Column logic beyond just parent.
    Factor out graph and graphLink to separate source files
    Factor out rectitem to separate source files
    Rename custom rect item
2016-04-12 18:12:13 +02:00
Stefan Tröger
81601959ab delete features when deleting body 2016-04-12 18:12:13 +02:00
Stefan Tröger
1ebe3e729c part deletion handling
-remove everxthing that belongs to a part on deletion
-disallow to delete the origin by the user and only remove it when Part is being deleted
2016-04-12 18:12:13 +02:00
Stefan Tröger
54dfe5cbff add part tool to task dialog for no selection 2016-04-12 18:12:13 +02:00
Stefan Tröger
4b2cecb59a fix pipe task dialog icon 2016-04-12 18:12:13 +02:00
Stefan Tröger
e7c5b5a4e7 add shaft wizard only when building fem 2016-04-12 18:12:13 +02:00
Stefan Tröger
23ebdda871 remove hole feature
A hole feature is something needed, however, the current implementation does not use the attacher code which would made it intuitive and compatibel to other workbench tools. A reimplementation is needed.
2016-04-12 18:12:13 +02:00
DeepSOIC
3e8b547354 Datum UI: fixes
* fix messagebox not popping when clicking OK but status is error
* accept preselection
* unify code for all datum commands
* edit selected datum if type matches, instead of creating new one
2016-04-12 18:12:13 +02:00
DeepSOIC
7cf0eaecae Sketcher: use Selection's getAsPropertyLinkSubList 2016-04-12 18:12:13 +02:00
DeepSOIC
4da2a4f21b Selection: add getAsPropertyLinkSubList method
Got tired of collecting selection into such properties over and over.
2016-04-12 18:12:13 +02:00