Commit Graph

614 Commits

Author SHA1 Message Date
Abdullah Tahiri
7cd3dd7dc4 Sketcher: Extend Constraints to have an activated boolean state 2019-06-22 08:26:31 +02:00
Abdullah Tahiri
87b46e3fb3 GCS: Refactor and additional debug information
==============================================

In maximum verbose debug mode, information is given about the groups of Sketcher Constraints that the solver is considering for redundancy or conflict.

This is before the popularity contest selects the constraint shown in the solver messages.

The main reason for showing this is to enable to diagnose problems with sketches in which the constraint indicated as the redundant one appears not to
be the right one. Intended for power users with "iteration level" debug mode.
2019-06-17 14:05:24 +02:00
Abdullah Tahiri
95788dde71 Sketcher: PCH 2019-05-02 07:12:27 +02:00
Abdullah Tahiri
e80af8b4f2 PCH for Sketcher/PartDesign 2019-05-01 09:05:55 +02:00
Abdullah Tahiri
d21cf68b8a GCS: Partial refactoring of diagnose() and debug improvements 2019-04-24 17:56:37 +02:00
Abdullah Tahiri
5f42b8216f Sketch: Verbose to console output malformed constraints that are ignored by the solver 2019-04-24 17:56:37 +02:00
Abdullah Tahiri
e104304a98 Sketcher: Make PointPos modifiable from Python 2019-04-24 17:56:37 +02:00
Abdullah Tahiri
af9492b790 GCS: use at for map reading 2019-04-24 17:56:37 +02:00
wmayer
725ffe5217 Fix several compiler warnings:
fix -Wunused-parameter
fix -Winconsistent-missing-override
fix -Wsometimes-uninitialized
2019-04-08 15:04:07 +02:00
Abdullah Tahiri
2fabda1605 Sketcher: Constraint improvements
=================================

Copy constructor made private, as copies are handled via copy() and clone() methods which generate pointers, not objects.
Private copy constructor, used for copy(),  made default implementation.
Destructor made default.
Copy and Clone made non-virtual, as the class does not have children.
Added override to persistance inherited virtual functions.
move operators explicitly disallowed to note that they are not intended in the current implementation.

Perfectly ok to have only private copy constructor for internal use
2019-04-08 14:35:47 +02:00
Abdullah Tahiri
3926ea18ca V547 CWE-571 2019-04-08 14:35:46 +02:00
Abdullah Tahiri
eebd4cecdb V560 CWE-570 2019-04-08 14:35:46 +02:00
wmayer
5f52bd7b46 PVS: V728 An excessive check can be simplified 2019-03-13 13:49:04 +01:00
wmayer
32c527c5a6 PVS: V547 Expression is always true/false 2019-03-12 18:33:26 +01:00
wmayer
8da09b30e7 fix restoring sketch 2019-03-02 16:23:40 +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
3845350c0a PVS: V773 A memory leak is possible 2019-02-17 18:40:06 +01:00
wmayer
f581d5c8cb PVS: V560 A part of conditional expression is always true 2019-02-17 13:56:48 +01:00
Abdullah Tahiri
88228d6d25 Fixes #3762 2019-02-15 19:08:44 +01:00
luz.paz
8a4af3b28c Crowdin: Sketcher/App/SketchObject.cpp elaborated term in string 2019-01-30 11:08:03 -02:00
luz.paz
3253de75e9 Fix for a previous commits
Crowdin:  Sketcher/App/SketcherAnalysis remove newlines
Crowdin:  Part/AttachmentEditor/TaskAttachmentEditor.py fix previous commiit
Crowdin:  Gui/NetworkRetriever.cpp correct previous commit
2019-01-30 11:08:03 -02:00
luz.paz
d858a8609d Crowdin: Sketcher/App/SketchObject.cpp uniformity fix 2019-01-30 11:08:03 -02:00
luz.paz
c65fce6128 Crowdin: Sketcher/App/SketchAnalysis.cpp remove superflous whitespace 2019-01-30 11:08:03 -02:00
Abdullah Tahiri
7d8e566264 Sketcher: fixes #3762 2019-01-12 17:26:19 +01:00
wmayer
be5796b2d0 add method restoreFinished and reimplement it in SketchObject 2018-12-29 15:27:32 +01:00
Mateusz Skowroński
71a8e2668d Fix GCC 8 warning: catching polymorphic type by value [-Wcatch-value=] 2018-12-23 11:05:02 -02:00
Abdullah Tahiri
c88a64e8e7 Make Open vertices detection routine accesible to Python 2018-12-03 12:11:11 +01:00
Abdullah Tahiri
18e680f283 Move Open vertices detection routine to SketchAnalysis 2018-12-03 12:11:11 +01:00
luz.paz
4dc201e086 Misc. typo, grammar, and whitespace fixes
[skip ci]
2018-11-27 15:02:58 -03:00
wmayer
36e3d5ef66 Fix scan coverity issues:
CID 184350:  Null pointer dereferences
2018-11-20 15:11:43 +01:00
Abdullah Tahiri
8db80c5c99 Property: dropping isorderrelevant boolean member in favour of bit in the status of the properties 2018-11-19 11:31:09 +01:00
Abdullah Tahiri
8176b7129c SketchObject: Activate relevant propertylist order 2018-11-19 11:31:08 +01:00
Abdullah Tahiri
6df9b895ff Sketcher: Fillet increase debugging verbose and disable by default 2018-11-18 12:03:05 +01:00
wmayer
56db19824e Replace Base::Exception with appropriate subclass 2018-11-14 19:27:52 +01:00
Abdullah Tahiri
07cf5b10d7 Sketcher: Trim support multiple intersections for circles
=========================================================

The problem with ellipses:
https://forum.freecadweb.org/viewtopic.php?f=3&t=31594&sid=37481b7a6c1ae2614c9840fc27a7773e&start=60#p267248

The problem with circles:
https://forum.freecadweb.org/viewtopic.php?f=3&t=31594&sid=37481b7a6c1ae2614c9840fc27a7773e&start=60#p267536
2018-11-09 22:30:04 +01:00
Abdullah Tahiri
084c483603 Sketcher: Ellipse trim, handle multiple intersection 2018-11-09 22:30:04 +01:00
Abdullah Tahiri
4245ae6863 Sketcher: Ellipse trimming with internal aligment geometry
==========================================================

Trimming was not considering a case where an ellipse is trimmed with respect to its own internal aligment geometry.

This resulted in Coincident Constraints with PointPos = Sketcher::none, which is invalid.
2018-11-09 22:30:03 +01:00
wmayer
f6a9cfaad3 fix -Wabsolute-value 2018-11-09 12:46:36 +01:00
wmayer
fbb8e86cbf remove trailing spaces 2018-11-05 11:55:14 +01:00
wmayer
c1f19d3854 remove trailing spaces 2018-11-05 10:53:01 +01:00
wmayer
dedf42102e remove leftover of boost.signals headers 2018-11-05 00:03:36 +01:00
Abdullah Tahiri
0a667889a0 Sketcher: Trim bug
==================

Trim tool fails to generate coincidence upon trimming an arc of ellipse at the end of the arc.

https://forum.freecadweb.org/viewtopic.php?f=3&t=31594&start=50#p266765
2018-11-04 14:43:24 -03:00
Abdullah Tahiri
d779e5b4b9 Sketcher: Fillet radius estimation improvement 2018-11-04 14:43:24 -03:00
Abdullah Tahiri
293e5732ad Sketcher: SketchObject Debug disabled by default 2018-11-04 14:43:24 -03:00
Abdullah Tahiri
abc7101118 Sketcher: Add DEBUG macro to SketchObject 2018-11-04 14:43:24 -03:00
Abdullah Tahiri
69d62787eb Sketcher: Intercurve fillet Improvement and delete constraint on point fix
==========================================================================

Intercurve fillet uses endpoint constraints for improved accuracy, but before this
commit was only considering a coincident constraint. Now it also considers an endpoint
tangency or perpendicular.

delConstraintOnPoint with coincidentonly=false, was not checking endpoint perpendiculars and
would therefore fail to delete them.

https://forum.freecadweb.org/viewtopic.php?f=3&t=31594&start=30#p265731
2018-11-04 14:43:24 -03:00
Abdullah Tahiri
fe78c1a037 Sketcher: Expose mass datum commands to python 2018-11-04 14:41:20 -03:00
Abdullah Tahiri
2c41e70c91 Sketcher: Mass operations on dimensionals
=========================================

This commit introduces two functions to operate on all datum constraints exclusively:

- Make all datum constraints driving or not driving, depending on the argument.
- Move all datum constraints at the end of the constraint list.

The practical use an ongoing effort towards improving the block constraint behaviour, that will be defered to 0.19
2018-11-04 14:41:20 -03:00
Abdullah Tahiri
6a1aed66e2 Sketcher: Refactor code relating to dimensional constraint checks 2018-11-04 14:41:20 -03:00
Abdullah Tahiri
8e2e5d7b6a Sketcher: Made constraints aware of whether they are dimensionals or not
========================================================================

Centralise the knowledge on whether a constraint is dimensional or not within the constraint
2018-11-04 14:41:20 -03:00