[Feature request #4067] Sketcher - Auto Remove Redundants - disabling - Feature request

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
HoWil
Posts: 844
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

[Feature request #4067] Sketcher - Auto Remove Redundants - disabling - Feature request

Postby HoWil » Fri Jul 19, 2019 7:23 pm

Good evening,

Imagine you draw a sketch in sketcher. The shown one is just an simplified example sometimes there are x10 of constraints.
If one adds to many constraints than they get removed automatically as happened in the shown example when adding the horizontal constraints "50mm".

But sometimes its nice to temporarily add more constraints and deselect the unused ones afterwards. Originally, I expected that if I deselect "Auto Remove Redundants" I would be able to add the "50mm" constraint and simply get a warning that there are redundant constraints. But that did not work out. Is this a bug or do I simply not get the working principle right?

So here comes my feature-request:
Much more helpful for the user would be a message informing that there are redundant constraints while asking if the new one or the old and redundant one should be kept. The other one could be switched to "reference mode".

Thanks in advance,
BR,
HoWil
Screenshot from 2019-07-19 18-20-24.png
Screenshot from 2019-07-19 18-20-24.png (153.14 KiB) Viewed 548 times
Last edited by HoWil on Wed Jul 24, 2019 12:48 pm, edited 1 time in total.
HoWil
Posts: 844
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby HoWil » Fri Jul 19, 2019 7:25 pm

Here is also the model to start/play with and my version info:

OS: Ubuntu 18.10 (ubuntu:GNOME/ubuntu)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.
Build type: Release
Python version: 3.6.8
Qt version: 5.11.1
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
Attachments
FC_sketcher_redundant_constraints_0p19.FCStd
(7.39 KiB) Downloaded 15 times
chrisb
Posts: 19731
Joined: Tue Mar 17, 2015 9:14 am

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby chrisb » Fri Jul 19, 2019 8:58 pm

HoWil wrote:
Fri Jul 19, 2019 7:23 pm
Is this a bug or do I simply not get the working principle right?
I would not call it a bug, but you are right, there is room for improvement. The behaviour you describe is implemented only for dimensional constraints. If you add a redundant geometric constraint it is just added and reported. You can continue, but the sketch is not updated anymore according to the constraints
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby bejant » Sat Jul 20, 2019 1:17 am

HoWil wrote:
Fri Jul 19, 2019 7:23 pm
Much more helpful for the user would be a message informing that there are redundant constraints while asking if the new one or the old and redundant one should be kept.
+1

HoWil wrote:
Fri Jul 19, 2019 7:23 pm
The other one could be switched to "reference mode".
Do you want this to be done automatically by Sketcher or do you want the user to be asked first?
Or maybe you envision something else?
HoWil
Posts: 844
Joined: Sun Jun 14, 2015 7:31 pm
Location: Austria

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby HoWil » Sat Jul 20, 2019 10:20 am

A dialogue could looke like:
----------------------------
Would you like to add the constraint "50mm" with the index xy. This would set constraint "30mm" with the index yz to "reference mode".
Please select 'No' to add the new constraint constraint "50mm" to "reference mode".

Yes No Cancel
----------------------------
abdullah wrote: Ping
Abdullah, what do you think?
Thanks in advance,
BR,
HoWil
chrisb
Posts: 19731
Joined: Tue Mar 17, 2015 9:14 am

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby chrisb » Sat Jul 20, 2019 9:15 pm

It may not always be easy to find a single dimension constraint which creates the redundancy. What should happen in such a case?
chrisb
Posts: 19731
Joined: Tue Mar 17, 2015 9:14 am

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby chrisb » Sat Jul 20, 2019 10:15 pm

Here is such an example: I tried to add a horizontal constraint of 0mm to the selected points:
Attachments
Bildschirmfoto 2019-07-21 um 00.13.53.png
Bildschirmfoto 2019-07-21 um 00.13.53.png (37.8 KiB) Viewed 469 times
abdullah
Posts: 3174
Joined: Sun May 04, 2014 3:16 pm

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby abdullah » Sun Jul 21, 2019 7:52 am

HoWil wrote:
Fri Jul 19, 2019 7:23 pm
Imagine you draw a sketch in sketcher. The shown one is just an simplified example sometimes there are x10 of constraints.
If one adds to many constraints than they get removed automatically as happened in the shown example when adding the horizontal constraints "50mm".
This should only happen with the Auto-Remove feature enabled.

The pop-up is not about the auto-remove mode, but FC cannot add it.
HoWil wrote:
Fri Jul 19, 2019 7:23 pm
But sometimes its nice to temporarily add more constraints and deselect the unused ones afterwards. Originally, I expected that if I deselect "Auto Remove Redundants" I would be able to add the "50mm" constraint and simply get a warning that there are redundant constraints. But that did not work out. Is this a bug or do I simply not get the working principle right?
The way to temporarily remove constraints is the new icon to deactivate/reactivate constraints. For dimensionals, the reference mode may be an alternative.
HoWil wrote:
Fri Jul 19, 2019 7:23 pm
So here comes my feature-request:
Much more helpful for the user would be a message informing that there are redundant constraints while asking if the new one or the old and redundant one should be kept. The other one could be switched to "reference mode".

Thanks in advance,
BR,
HoWil
Screenshot from 2019-07-19 18-20-24.png
As Chrisb indicates, there is generally no one-to-one relationship between a new inserted constraint and an old pre-existing one. Different sketcher constraints introduce a different number of constraints.

Aside, I am not confident that it is always the case that a user wants to enforce the new constraint. User do make mistakes from time to time. In case of a mistake the user wants that pop-up to be alerted of his misconception and trigger some extra sugar burning in its neurons.
chrisb
Posts: 19731
Joined: Tue Mar 17, 2015 9:14 am

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby chrisb » Sun Jul 21, 2019 9:29 am

abdullah wrote:
Sun Jul 21, 2019 7:52 am
User do make mistakes from time to time.
Whenever I have seen this message I cannot remember wanting the new constraint, usually I simply had missed that it was already there, in rare cases I had missed that it could be derived.
The only way to handle this consistently would be an option to change the new dimension immediately to a reference constraint, like for external geometry. So the popup could be changed to a question "delete or keep as reference?".
abdullah
Posts: 3174
Joined: Sun May 04, 2014 3:16 pm

Re: Sketcher - Auto Remove Redundants - disabling - Feature request

Postby abdullah » Sun Jul 21, 2019 10:24 am

chrisb wrote:
Sun Jul 21, 2019 9:29 am
abdullah wrote:
Sun Jul 21, 2019 7:52 am
User do make mistakes from time to time.
Whenever I have seen this message I cannot remember wanting the new constraint, usually I simply had missed that it was already there, in rare cases I had missed that it could be derived.
This is generally the case for me too.
chrisb wrote:
Sun Jul 21, 2019 9:29 am
The only way to handle this consistently would be an option to change the new dimension immediately to a reference constraint, like for external geometry. So the popup could be changed to a question "delete or keep as reference?".
IMO this is actually the kind of things that add value. It would make a nice feature request.