Better selection system for constraints in Sketcher

A forum for research and development of the user interface of FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
jnxd
Posts: 951
Joined: Mon Mar 30, 2015 2:30 pm
Contact:

Re: Better selection system for constraints in Sketcher

Post by jnxd »

bejant wrote: Sometimes the cursor indicator H or V for Horizontal and Vertical Constraints (not distance) didn't appear until I hovered the cursor over and edge so that it was pre-selected. The behavior is intermittent and I haven't figured out a way to reproduce it yet.
I smell race conditions or something similar here. When what you said happens, can you hover around on empty space indefinitely without the mode-specific cursor appearing?
Unless there is a way for the user to let Sketcher know whether the Length pop-up should appear after one point is selected or if that should wait until the second point is selected, we can't have both Scenarios (but I suppose a key press could serve that purpose, if you decide to implement it).
Key press is the exact solution I was thinking of, perhaps most naturally Shift. No guarantees of implementation though.
Maybe the user would want to change modes more often, depending on whatever Sketch is open.
What do you (and anyone else who cares to ring in) think about a toggle button in the Sketcher Constraints toolbar instead?
I have no issues with it. But I need a solid location where it should be, lest I have to change it over and over again. It would (probably) have been a different story had all the GUI been in python, but...
Or maybe clicking a Constraint Button first, while no geometry is selected, enables Continuous Mode? This way the user could select say, the Coincident Constraint, do a Box Selection in the 3D view of some points / vertices, and upon release of LMB the Coincident Constraint is applied and Continuous Mode remains enabled. Just putting up some ideas here as I'm fiddling around with Sketcher...
As it stands implementation of rubberband selection cannot work while we are in such modes. There are some issues to deal with before making sure that they do when we have an opportunity. I am also reluctant to do anything because the code is already so complex (we're looking at a 7000 line file).
My latest (or last) project: B-spline Construction Project.
User avatar
bejant
Veteran
Posts: 6075
Joined: Thu Jul 11, 2013 3:06 pm

Re: Better selection system for constraints in Sketcher

Post by bejant »

jnxd wrote:When what you said happens, can you hover around on empty space indefinitely without the mode-specific cursor appearing?
Yes. It wasn't until I hovered over and edge to pre-select it that the cursor also changed. But so far today I can't reproduce it.
jnxd wrote:
bejant wrote: Maybe the user would want to change modes more often, depending on whatever Sketch is open.
What do you (and anyone else who cares to ring in) think about a toggle button in the Sketcher Constraints toolbar instead?
I have no issues with it. But I need a solid location where it should be, lest I have to change it over and over again. It would (probably) have been a different story had all the GUI been in python, but...
My vote would be the first spot in the Sketcher Constraints toolbar (before the Coincident Constraint). At first I thought it should be at the end of the toolbar, but if it is at the beginning it would still be visible to remind the user of the mode, even when the end of the toobar is truncated (e.g.: because of large icons or small FreeCAD window).
jnxd wrote:As it stands implementation of rubberband selection cannot work while we are in such modes. There are some issues to deal with before making sure that they do when we have an opportunity. I am also reluctant to do anything because the code is already so complex (we're looking at a 7000 line file).
Fair enough; I mentioned it because I think it will be handy and used often. Thanks for considering my suggestions!

Edit = corrected mistakes.
Last edited by bejant on Mon Feb 13, 2017 2:49 am, edited 1 time in total.
User avatar
jnxd
Posts: 951
Joined: Mon Mar 30, 2015 2:30 pm
Contact:

Re: Better selection system for constraints in Sketcher

Post by jnxd »

Just felt I should do a brief round-up of what is going on in terms of the continuous constraint mode.

As it stands, I have converted all but two constraint commands to this mode. Constraints can be applied to all elements except external geometries. The remaining items, roughly in decreasing order of priority, are as follows:
  • Make the new mode relevant for external geometries
  • Make the entire mode optional, possibly also put the option in the toolbar
  • Sort out icons for each of the modes (talking with agryson about this)
The above three things I would imagine are absolutely necessary before 0.17 is released. When is that anyway?
Continuing to the "nice to have" things.
  • Box selection while in these modes
  • Slightly different selection modes: when a key is pressed, change behavior. For e.g. horizontal/vertical distance constraint directly applies from single point to root, rather than first point to second point.
  • An indicator beyond a changed cursor, for touch-screen users.
Am I missing somethings above? I'd like your inputs about how this little extension is working. So far the response has been mixed, and people who are actually okay with it are just getting used to it. I hope the number of people getting used to it grows, which would truly make this experiment a success.
My latest (or last) project: B-spline Construction Project.
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Better selection system for constraints in Sketcher

Post by NormandC »

jnxd wrote:before 0.17 is released. When is that anyway?
As it's always been with FreeCAD, there is no date set. "It's done when it's done" is the FreeCAD motto.

But the reality: it may not be anytime soon, unless other developers give a hand to ickby to stabilize the PartDesign workbench.
User avatar
jnxd
Posts: 951
Joined: Mon Mar 30, 2015 2:30 pm
Contact:

Re: Better selection system for constraints in Sketcher

Post by jnxd »

NormandC wrote: But the reality: it may not be anytime soon, unless other developers give a hand to ickby to stabilize the PartDesign workbench.
Are there any set of requirements written somewhere?
My latest (or last) project: B-spline Construction Project.
User avatar
kkremitzki
Veteran
Posts: 2511
Joined: Thu Mar 03, 2016 9:52 pm
Location: Illinois

Re: Better selection system for constraints in Sketcher

Post by kkremitzki »

jnxd wrote:
NormandC wrote: But the reality: it may not be anytime soon, unless other developers give a hand to ickby to stabilize the PartDesign workbench.
Are there any set of requirements written somewhere?
This may get you started: https://freecadweb.org/tracker/roadmap_page.php
It may not be the most up-to-date or complete listing, but that's where the path to 0.17 should be charted out.
Like my FreeCAD work? I'd appreciate any level of support via Patreon, Liberapay, or PayPal! Read more about what I do at my blog.
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Better selection system for constraints in Sketcher

Post by NormandC »

kkremitzki wrote:It may not be the most up-to-date or complete listing
You can say that again. Only two reports are listed under PartDesign. There should be a whole lot more.

I'm guessing the roadmap only lists issues which have "0.17" in the Target Version field?
User avatar
kkremitzki
Veteran
Posts: 2511
Joined: Thu Mar 03, 2016 9:52 pm
Location: Illinois

Re: Better selection system for constraints in Sketcher

Post by kkremitzki »

NormandC wrote:
kkremitzki wrote:It may not be the most up-to-date or complete listing
You can say that again. Only two reports are listed under PartDesign. There should be a whole lot more.

I'm guessing the roadmap only lists issues which have "0.17" in the Target Version field?
Yeah, the Target Version is what I think causes inclusion there.
Like my FreeCAD work? I'd appreciate any level of support via Patreon, Liberapay, or PayPal! Read more about what I do at my blog.
User avatar
NormandC
Veteran
Posts: 18587
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Better selection system for constraints in Sketcher

Post by NormandC »

I think that at least any PartDesign issue that mentions a hard crash should get a 0.17 target version.
User avatar
bejant
Veteran
Posts: 6075
Joined: Thu Jul 11, 2013 3:06 pm

Re: Better selection system for constraints in Sketcher

Post by bejant »

jnxd wrote:Just felt I should do a brief round-up of what is going on in terms of the continuous constraint mode.
< snip >
Am I missing somethings above?
No, I think you've summed it up pretty well. :)
Post Reply