[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
chrisb
Veteran
Posts: 53785
Joined: Tue Mar 17, 2015 9:14 am

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

Post by chrisb »

I wouldn't make these things too complicated. While you are at it, or when making a feature proposal, you know exactly how to set filters and how to activate this or that feature. But after a couple of months it may turn out that things are harder to remember as expected and that a clear straightforward concept is what the vast majority uses.
I am not against supporting a minority of (power) users, but we may indeed revisit this stuff in half a year or so.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
M4x
Veteran
Posts: 1449
Joined: Sat Mar 11, 2017 9:23 am
Location: Germany

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

Post by M4x »

Uwe, I feel with you regarding your 15" screen. ;) However, from your screenshot I'd have thought that your screen is much smaller. What resolution are you using?

Besides from that, 15" is already too big for me if we're talking about laptop screens. Maybe you could get something around 12" and in addition to that an external monitor with a travel bag :mrgreen:
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

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

Post by abdullah »

chrisb wrote: Tue Oct 05, 2021 4:59 pm I wouldn't make these things too complicated. While you are at it, or when making a feature proposal, you know exactly how to set filters and how to activate this or that feature. But after a couple of months it may turn out that things are harder to remember as expected and that a clear straightforward concept is what the vast majority uses.
I am not against supporting a minority of (power) users, but we may indeed revisit this stuff in half a year or so.
I am in the process of trying to figure out what to offer and how to offer it.

What is now in master works, but:
- The tabcontrol eats more space than I would like to, making the constraint list smaller than possible.
- The tabcontrol is very restricted in terms of expanding functionality. It needs to made up a new category every two parameters.

I am thinking of removing it. Leaving two to three meaningful buttons + plus one "settings" button opening a pop-up dialog for all the fine tunnings (checkboxes for controlling the list access, ...).

I agree with you. What is offered needs to be simple and intuitive. Then as much flexible as we can get it.
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

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

Post by abdullah »

M4x wrote: Wed Oct 06, 2021 7:06 am Besides from that, 15" is already too big for me if we're talking about laptop screens. Maybe you could get something around 12" and in addition to that an external monitor with a travel bag :mrgreen:
Let it be a 27 inches monitor and a wheeled travel bag :lol:
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

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

Post by abdullah »

This is the rough version of the new selection filter:
Peek 06-10-2021 13-32.gif
Peek 06-10-2021 13-32.gif (212.26 KiB) Viewed 4034 times
It works, but actually getting all out of it is a little bit convoluted. This is what I am set to avoid for this particular feature.
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

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

Post by abdullah »

I have pushed the selection filter to master. I will know think about the possibility to improve the UI to make it more accessible.
User avatar
adrianinsaval
Veteran
Posts: 5534
Joined: Thu Apr 05, 2018 5:15 pm

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

Post by adrianinsaval »

Wouldn't it be more conveniente if it auto filtered the constraints associated to the selected geometry? (could be renamed to Selection/Associated with selection)
Is there an use case were you wouldn't want that? At least it could do that if no constraints are selected.
abdullah
Veteran
Posts: 4935
Joined: Sun May 04, 2014 3:16 pm
Contact:

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

Post by abdullah »

adrianinsaval wrote: Wed Oct 06, 2021 1:45 pm Wouldn't it be more conveniente if it auto filtered the constraints associated to the selected geometry? (could be renamed to Selection/Associated with selection)
Is there an use case were you wouldn't want that? At least it could do that if no constraints are selected.
This commit provides uniform behaviour with the other filters. The filter may be selected before or after the selection is made. It is intended as a generic filter option, rather than tailor cut to a specific usage.

It works on any selection of constraints. This selection may be the result of a macro, the result of clicking on the detected redundant/conflicting/malformed of the solver messages or the associated constraints as shown (I do not remember by heart of all the sketcher functionalities).

If you are proposing that the actual command that now selects the associated constraints also changes the visibility. I would not like to change the current command, because user macros may be depending on it and would break backwards compatibility. However, it is possible to create a new command that would do select and show only those selected constraints.

I do not understand the last sentence. The current command select constraints associated with an element needs an element as input, if constraints are selected it would do nothing...
User avatar
adrianinsaval
Veteran
Posts: 5534
Joined: Thu Apr 05, 2018 5:15 pm

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

Post by adrianinsaval »

the command should be left as is, what I had in mind is to skip using that command when the selection filter is activated, so as a result of selecting a circle in 3d view it's associated constraint will be filtered in the list. The filter would be selected constraints + constraints associated to selected geometries
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 »

M4x wrote: Wed Oct 06, 2021 7:06 am Uwe, I feel with you regarding your 15" screen. ;) However, from your screenshot I'd have thought that your screen is much smaller. What resolution are you using?
It is a Dell Latitude 7490. They call the screen even 14''. The resolution is 1920 x 1080 px and cannot be changed.

from the feature side of view I am happy as I wrote.

(I see in the Sketcher constraint side panels a minor UI size issues. When I find time I will try to improve this and then make a PR. However the next days I won't have time for FC for developing - but have to use it intensively in real-life thus can and will test ;) )
Locked