[Resolved] PR #4942 new option to show/hide sketcher constraints

Post here if you have re-based and finalised code to integrate into master, which was discussed, agreed to and tested in other forums. You can also submit your PR directly on github.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Locked
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: PR #4942 new option to show/hide sketcher constraints

Post by uwestoehr »

abdullah wrote: Mon Sep 20, 2021 5:44 pm How do we shape it further?
Awesome!

I only miss a toggle button to change if the selected annotation type should be shown or hidden. In your screencast the filtered types will be shown all other not. There should be a way to say, "show everything but the filtered type" and there should also be a ways to hide everything.
Last edited by uwestoehr on Mon Sep 20, 2021 6:26 pm, edited 1 time in total.
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: PR #4942 new option to show/hide sketcher constraints

Post by wsteffe »

The video shows to set the visualization of only one type of constraint (or all types). I would like to have the possibility to select more than one type (in example coincidence and symmetry).

I have noticed that nothing is visualized when you set the visualization of the coincidence constraint. Is it a bug ?
chrisb
Veteran
Posts: 53919
Joined: Tue Mar 17, 2015 9:14 am

Re: PR #4942 new option to show/hide sketcher constraints

Post by chrisb »

wsteffe wrote: Mon Sep 20, 2021 6:06 pm The video shows to set the visualization of only one type of constraint (or all types). I would like to have the possibility to select more than one type (in example coincidence and symmetry).
That could be nice, but it would require a different widget. And that would probably require more space, which I wouldn't like to see at all.
I have noticed that nothing is visualized when you set the visualization of the coincidence constraint. Is it a bug ?
Coincidences are never shown in 3D view.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
chrisb
Veteran
Posts: 53919
Joined: Tue Mar 17, 2015 9:14 am

Re: PR #4942 new option to show/hide sketcher constraints

Post by chrisb »

Shalmeneser wrote: Mon Sep 20, 2021 4:43 pm I dream that when selecting one dimension, all lines with the same dimension get highligthed.
+1 (if you mean the transitive hull of equalities, and not repeated dimensions, which is another issue).
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
Shalmeneser
Veteran
Posts: 9474
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: PR #4942 new option to show/hide sketcher constraints

Post by Shalmeneser »

chrisb wrote: Mon Sep 20, 2021 8:56 pm +1 (if you mean the transitive hull of equalities, and not repeated dimensions, which is another issue).
transitive hull of equalities ???

(1) : Line with Sketcher_ConstrainEqual with the dimension selected (= direct equality)
(2) : any line logicaly equal (eg opposite sides of a rectangle) (= logical equality)
(3) : any line numericaly equal (= numerical equality)

I think (1) and (3) are easy to compute : just check constrains or values.

(2) is more difficult :
(* suppress (1) from other same dimension)
* find (3)
* modify the dimension
* solve the sketch
* find (3') with the new dimension
* (2) = intersection of (3) and (3')
* undo dimension modification

I need (1) and (2). 8-)
chrisb
Veteran
Posts: 53919
Joined: Tue Mar 17, 2015 9:14 am

Re: PR #4942 new option to show/hide sketcher constraints

Post by chrisb »

Shalmeneser wrote: Mon Sep 20, 2021 9:14 pm transitive hull of equalities ???
- Consider 4 lines A, B, C, D
- with constraints A eq B, B eq C, C eq D

Then the transitive hull contains all equalities which can be derived from this, i.e. in addition to the above:
A eq C, A eq D, B eq D.

I think a general - geometric/algebraic - derivation is beyond of what should be done. Doing this numerically as I understand your proposal seems to me to be only of limited value.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
GeneFC
Veteran
Posts: 5373
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: PR #4942 new option to show/hide sketcher constraints

Post by GeneFC »

This entire topic seems to be getting a bit off the rails. What started as a request to show/hide messy items like dimensions has headed off to a variety of modeling aids.

I think it would be useful to quickly hide or show large visible items like dimensions (seemingly called datums in this thread.) Everything else is gravy. :o

Gene
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: PR #4942 new option to show/hide sketcher constraints

Post by wsteffe »

chrisb wrote: Mon Sep 20, 2021 8:52 pm That could be nice, but it would require a different widget. And that would probably require more space, which I wouldn't like to see at all.
Not much more space. The Visualization Flag could be replaced by a couple of Flags: Hide and Unhide.
When Unhide is checked every time you enter a filter type that type is made visible without hiding any other already visible type.
chrisb wrote: Mon Sep 20, 2021 8:52 pm Coincidences are never shown in 3D view.
And how do you do to check that a couple of edges are connected ?
chrisb
Veteran
Posts: 53919
Joined: Tue Mar 17, 2015 9:14 am

Re: PR #4942 new option to show/hide sketcher constraints

Post by chrisb »

wsteffe wrote: Tue Sep 21, 2021 1:48 am And how do you do to check that a couple of edges are connected ?
I could be surprised that you didn't stumble sooner about this, but you probably work similar as I do: I come from the other side and create my sketches with coincidences right away. And usually it is not interesting which points are but rather which are not coincident. That is shown by Validate sketch.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
wsteffe
Posts: 461
Joined: Thu Aug 21, 2014 8:17 pm

Re: PR #4942 new option to show/hide sketcher constraints

Post by wsteffe »

chrisb wrote: Tue Sep 21, 2021 5:45 am That is shown by Validate sketch.
Yes I was missing this tool. Up to now I was just trying to move every edge which would not be fixed in case it were not connected at both ends.

But still I can not understand how to use the tool Validate sketch.
It can be started only outside of the sketch: the sketch must be selected but closed.
I have tried to search for missing coincidences in one sketch and a couple of missing coincidences was found.
But nothing is shown when I open the sketch, even if I press "Highlight open vertices".
Locked