Commit Graph

20595 Commits

Author SHA1 Message Date
vocx-fc
91c75b03f7 Draft: move Draft_FlipDimension to gui_dimension_ops module 2020-04-16 11:40:58 +02:00
vocx-fc
28e2e20a00 Draft: move Draft_Heal to gui_heal module 2020-04-16 11:40:58 +02:00
vocx-fc
df3a06399b Draft: move Draft_ToggleGrid to gui_grid module 2020-04-16 11:40:58 +02:00
vocx-fc
78c276e2a2 Draft: add base class for Snap commands 2020-04-16 11:40:58 +02:00
vocx-fc
a1f6a7f6e0 Draft: move Draft_ShowSnapBar to gui_snaps module 2020-04-16 11:40:58 +02:00
vocx-fc
eca1c75056 Draft: add correct docstring to old Array tools
Previously they mentioned incorrectly the Shape2DView tool.
2020-04-16 11:40:58 +02:00
vocx-fc
631f74d8fc Draft: move SelectGroup command to gui_groups module 2020-04-16 11:40:58 +02:00
vocx-fc
a0f9df523a Draft: move AddToGroup command to gui_groups module 2020-04-16 11:40:58 +02:00
vocx-fc
02189fa973 Draft: new utility toolbar with some useful commands
These commands are useful but are "hiden"
inside the "Utilities" menu, so not many poeple know about them.
By placing them in a toolbar, they will be more discoverable.
2020-04-16 11:40:58 +02:00
vocx-fc
5acb94984f Draft: move DisplayMode command to gui_togglemodes module 2020-04-16 11:40:58 +02:00
vocx-fc
e3154fccb2 Draft: move mode commands to gui_togglemodes module
`Draft_ToggleConstructionMode` and `Draft_ToggleContinueMode`.
They call a base class `BaseMode` which also uses the base
`gui_base.GuiCommandSimplest` class.

Also add a new icon for continue mode.
2020-04-16 11:40:58 +02:00
vocx-fc
1b8e9d5cb8 Draft: move line GuiCommands to gui_lineops module
The commands `FinishLine`, `CloseLine`, and `UndoLine`
are moved from the huge `DraftTools.py` to `gui_lineops.py`
to reduce the complexity of the former file.

These GuiCommands aren't actually used presently
in the Draft Workbench. They were used in the past
particularly from the context menu when editing a Line object.
2020-04-16 11:40:58 +02:00
vocx-fc
1970b6c3c9 Draft: GuiCommandSimplest to serve as base of simple Gui Commands
This class defines the `command_name` of the command,
so that it is output to the report view, and is also recorded
in the log file.

It also stores the current document so it can be used inside the
command.

The class implements with `IsActive` method so that the command
is only active when an active document exists.

Also `GuiCommandNeedsSelection`, which subclasses the former
class. It reimplements `IsActive` in order to be available
only when there is a selection.
2020-04-16 11:40:58 +02:00
vocx-fc
b3abe7efe9 Draft: update InitGui with context commands
The `ContextMenu` method defines commands that will be listed
when right clicking and opening the context menu in the 3D view
or the tree view.

This sets up the line GUI commands when either a line, wire,
polyline, spline, or bezier curve is active.

However, this currently doesn't work at all for unknown reasons.
Maybe some other functionality in the internal C++ code
needs to be changed first.
2020-04-16 11:40:58 +02:00
carlopav
db9134630a [Draft] Cleanup splitted annotatation objects
- corrected super() methods to be Py2 compatible
- further cleanup of the code.
further cleanup


changed again to avoid super method


updated super() functions


updated to correct the parent classess targeted by super()
2020-04-16 11:37:10 +02:00
carlopav
00c0de6871 [Draft] Removed annotation styles objects
Removed Annotation styles current implementation.
As pointed out by yorik, in https://forum.freecadweb.org/viewtopic.php?f=23&t=44051&p=385710#p385179, this feature will be added using document Meta property.
2020-04-16 11:37:10 +02:00
carlopav
78f740807c [Draft] Dimension styles improvements
Dimension style property is auto-set on dimension creation.
Further improvementes in DimensionStyleContainer.
.
2020-04-16 11:37:10 +02:00
carlopav
a4f7bc43f6 [Draft] Cleanup of Annotation style branch
Further cleanup and guarded imports of Gui in modules.

.
2020-04-16 11:37:10 +02:00
carlopav
cb4295fd8a [Draft] Splitted object Text and Label from Draft.py
And based them on Draft Annotation object
2020-04-16 11:37:10 +02:00
carlopav
19928b7347 [Draft] Updated cmake with splitted annotation objects
.


.
2020-04-16 11:37:10 +02:00
carlopav
5b4815f807 [Draft] Dimension Style cleanup 2020-04-16 11:37:10 +02:00
carlopav
749f614313 [Draft] Group object for dimension styles 2020-04-16 11:37:10 +02:00
carlopav
9c4c16c7bb [Draft] Split angular dimension
and made it derived from 
DimensionBase <- Draft Annotation
2020-04-16 11:37:10 +02:00
carlopav
9f1405df0e [Draft] Annotation refactor and Cleanup
.


.
2020-04-16 11:37:10 +02:00
carlopav
637c45733e [Draft] Split Dimension object and reorganize of annotation objects
part 1
2020-04-16 11:37:10 +02:00
carlopav
0bc6e4cddc [Draft] New Icons for Annotation Style 2020-04-16 11:37:10 +02:00
carlopav
5bbf3ad6cf [Draft] Dimension style object
still have to split viewprovider from object.
[Draft] Dimension Style code cleanup

thx @vocx-fc for reviewing
further cleanup


[Draft] Dimension Style improvements

Added a property to the dimension object to link the dimension style.
Improved the update of dimensions when style changes. This can be done in 2 different ways: by setting AutoUpdate property to True or by activating Update function from the viewprovider context menu.
2020-04-16 11:37:10 +02:00
vocx-fc
097d828fb5 Draft: add init_draft_statusbar to CMakeLists 2020-04-16 11:37:10 +02:00
carlopav
655852bda6 [Draft] Annotation scale, support for imperial custom scale input
Added support for different scale list
2020-04-16 11:37:10 +02:00
carlopav
9e7fb35761 [Draft] Rearrange annotation properties groups
ref. https://forum.freecadweb.org/viewtopic.php?f=23&t=43795&p=373731#p373731
bugfix
2020-04-16 11:37:10 +02:00
carlopav
7d8847a2a2 [Draft] Annotation Scale bugfix
Now property ScaleMultiplier is checked for existence before the use.
2020-04-16 11:37:10 +02:00
carlopav
f90921ef03 [Draft] Improved Autogroup to handle Draft Annotations
Draft Dimension, Label and Text are now correctly auto-added to Part container
2020-04-16 11:37:10 +02:00
carlopav
ba71f3de75 [Draft] First implementation of annotation scale
The changes are minimal, mainly is just cleanup of existing code and documentation.
[Draft] Annotation scale for ViewProviderDraftText

Adding support for scale factor according to changes in dimensions.
[Draft] Annotation scale for ViewProviderDraftLabel

completed annotations scale
[Draft] Annotation scale for ViewProviderAngularDimension
2020-04-16 11:37:10 +02:00
carlopav
9fcb4f94a0 [Draft] Annotation scale support and statusbar widget
Initial commit
Preliminary support for Draft Dimensions


[Draft] Statusbar Widget code cleanup
2020-04-16 11:37:10 +02:00
wandererfan
b0b0b77d65 [TD]fix KB lockout in dialogs
- valueChanged signal is emitted for every keystroke
  causing multiple recomputes for every change of
  parameter.
2020-04-15 15:43:00 -04:00
sliptonic
94a704972d Merge pull request #3354 from etrombly/master
[Path] fix some typos in recent lazyloader implementation
2020-04-15 12:55:43 -05:00
Eric Trombly
08fc5556d5 fix some typos in recent lazyloader implementation 2020-04-15 12:32:48 -05:00
Yorik van Havre
674e56817c Arch: Fixed bug in IFC export of furniture 2020-04-15 18:01:11 +02:00
sliptonic
9427b5d0aa Merge pull request #3330 from etrombly/lazyloader
[Path] Use lazyloader for deferred python imports
2020-04-15 10:22:28 -05:00
donovaly
de614285c4 fix a typo 2020-04-15 10:10:14 -04:00
donovaly
e68d1fd989 give all preferences dialogs a clear name
The numbering was somewhat artificial.
2020-04-15 10:10:14 -04:00
donovaly
f4e937d3e0 This commits splits the "General" dialog to "General" and "Colors". 2020-04-15 10:10:14 -04:00
donovaly
363031fc73 [TD] split too long preferences dialogs
- as once discussed 2 of the dialogs are too long for smaller screens.

This commits splits the "Dimensions" dialog to "Dimensions" and "Annotation".
2020-04-15 10:10:14 -04:00
Przemo Firszt
a68f3a9f8a Remove conditionals for older fedora versions from freecad.spec
Signed-off-by: Przemo Firszt <przemo@firszt.eu>
2020-04-15 13:43:01 +02:00
Przemo Firszt
c0a73cf7f4 Switch freecad.spec from OCE to opencascade (OCCT)
Signed-off-by: Przemo Firszt <przemo@firszt.eu>
2020-04-15 13:43:01 +02:00
Bernd Hahnebach
0ade3f5efe FEM: group meshing, fix retriving group elements in rare cases 2020-04-15 10:50:02 +02:00
Bernd Hahnebach
cac66f4638 FEM: self weight object, set to not shown in property editor 2020-04-15 10:49:00 +02:00
wmayer
5cfe5eacca Tools: [skip ci] move import of requests module into try/except block 2020-04-15 10:39:46 +02:00
wandererfan
2ef3950240 [TD]Fix Detail dragger for ProjGroup 2020-04-14 17:42:11 -04:00
Abdullah Tahiri
e7012a458c Sketcher: Fix trim
==================

https://forum.freecadweb.org/viewtopic.php?p=387303#p387303

1. Trim had a bug that the type of the constraint on the second point was equal to the first one regardless of the situation.

2. Trim did not have support for checking whether points were close to the edge and relied on preexisting constraints.
2020-04-14 19:00:51 +02:00