Enhancements to starting Tasks dialog in Part Design

About the development of the Part Design module/workbench. PLEASE DO NOT POST HELP REQUESTS HERE!
User avatar
kkremitzki
Posts: 360
Joined: Thu Mar 03, 2016 9:52 pm
Location: Texas

Enhancements to starting Tasks dialog in Part Design

Postby kkremitzki » Wed Mar 08, 2017 4:07 pm

Hi, I'd like to get started making some improvements to Part Design, and I think the place I'd like to start is with the initial Task view, specifically the "Start Part: Create body / Create part" dialog.
Screenshot from 2017-03-08 09-54-04.png
Screenshot from 2017-03-08 09-54-04.png (85.53 KiB) Viewed 363 times


So the first problem is that it isn't immediately obvious to a new user what they should do here; if they haven't read the new part design threads, the first thing you might try is to click "Create part" since the dialog is titled "Start Part" and we are after all in the Part Design WB.

However, you can click "Create part" in this window as many times as you like without any visible effect. You will, however, get N empty parts as soon as you happen to click into the Model tab.

Second, let's assume I want to create a body inside a part. Now, this may be a regression, but if I click "Create part" and then "Create body", my task view flickers to the "Create sketch/create boolean" dialog, but instantly returns to the "Start Part" dialog.

So, the only functional option seems to be the first, "create body".

I'd like to propose an improvement based on the following two options for someone firing up the Part Design WB:
  • They want to create a new Body object, which may or may not be wrapped in a Part container for use in a different part of the software (e.g. a future Assembly object)
  • They want to create a new Part object to wrap existing objects, e.g. a Mesh, to prepare a Part for use in a different part of the software

Would it be a fair assumption to say that these are the workflows for someone opening a new file and starting Part Design?

If so, the dialog could be redesigned to have:
  • A button to create a new Body, with an accompanying checkbox: "create Body inside a Part", checked by default (or not? would like to hear thoughts on this.)
  • A button to create an empty Part, which doesn't silently create that Part with no effect as is now occurring, and an accompanying short blurb like "Create new Part object to contain pre-existing object(s)"

Thoughts?
triplus
Posts: 4995
Joined: Mon Dec 12, 2011 4:45 pm

Re: Enhancements to starting Tasks dialog in Part Design

Postby triplus » Wed Mar 08, 2017 4:46 pm

kkremitzki wrote:Thoughts?


I would say take your time and listen to the users. We had similar discussions in the past but not much came out of that. The only conclusion i can remember at that time was best to wait for more users to give feedback.
DeepSOIC
Posts: 4689
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: Enhancements to starting Tasks dialog in Part Design

Postby DeepSOIC » Wed Mar 08, 2017 5:41 pm

Thoughts.
Having visual clues that a part was created seems good. One easy way is to show origin features. Another visual clue can be that task panel would say "inside Part", or something... BTW, if part-o-magic is active, origin features are shown for new part.

I have the same problem with body, that when I create a body, task panel flickers, but doesn't end up saying the right thing.


kkremitzki wrote:A button to create a new Body, with an accompanying checkbox: "create Body inside a Part", checked by default (or not? would like to hear thoughts on this.)
I don't think that is needed. I think that sticking to rule "a new object always goes to active container" is the best way (again, I made part-o-magic to test this rule out).
User avatar
kkremitzki
Posts: 360
Joined: Thu Mar 03, 2016 9:52 pm
Location: Texas

Re: Enhancements to starting Tasks dialog in Part Design

Postby kkremitzki » Wed Mar 08, 2017 9:12 pm

DeepSOIC wrote:Thoughts.
Having visual clues that a part was created seems good. One easy way is to show origin features. Another visual clue can be that task panel would say "inside Part", or something... BTW, if part-o-magic is active, origin features are shown for new part.

I have the same problem with body, that when I create a body, task panel flickers, but doesn't end up saying the right thing.

This changeset fixes the behavior: https://github.com/FreeCAD/FreeCAD/comp ... mitzki:pd1
Is that fix ok? All 3 PartDesign tests in Test WB passed (and all the others, too.)
kkremitzki wrote:A button to create a new Body, with an accompanying checkbox: "create Body inside a Part", checked by default (or not? would like to hear thoughts on this.)
I don't think that is needed. I think that sticking to rule "a new object always goes to active container" is the best way (again, I made part-o-magic to test this rule out).

For the issue of being able to repeatedly click "Create part": would it be ok to disable/remove it in the Task window if active container is an empty Part? (i.e. "Create part" been clicked once.) It doesn't even create the new part within the old part which would be consistent with your rule, and I'm not sure that would be considered a valid workflow, anyway.

The task panel title could be changed as you said, but I'm not sure to what. "Fill part"? "Define part"? Once you have a Part, you can populate it with a Body, but aren't there other objects you could import? Should there be some option to do so, once the part has been created?

Also, I definitely like the behavior of showing and zooming to the origin features when creating a part, but when should that get toggled off? Once it contains an object with an origin?

Also, something I noticed that's weird: when you create a body and see the option to make a sketch or boolean, if you click into the empty document window, the task panel reverts back to "create body" or "create part". You have to click onto the model view, click on your body, and click back. That doesn't seem right!
DeepSOIC
Posts: 4689
Joined: Fri Aug 29, 2014 12:45 am
Location: Saint-Petersburg, Russia

Re: Enhancements to starting Tasks dialog in Part Design

Postby DeepSOIC » Wed Mar 08, 2017 10:20 pm

I looked at your fix. IMO body shouldn't be selected after creation at all. Again, this comes from my experience with part-o-magic. It burned me with other workbench tools, in particular Sketcher, which tries to attach a sketch to body (yet add itself to the body), which creates a circular dependency. Here's approximately how it went:
1. create Module.
Module is created, activated, and selected
2. create sketch (sketcher wb)
sketch attaches itself to whatever is selected, which happens to be body.
3. accept attachment -> circular dependency.

Of course, this doesn't apply to PartDesign, since it has its own way of creating sketches. But also there is some chance selection will be filtered out with code introduced at later time, to help eliminate accidental cross-container links.
User avatar
kkremitzki
Posts: 360
Joined: Thu Mar 03, 2016 9:52 pm
Location: Texas

Re: Enhancements to starting Tasks dialog in Part Design

Postby kkremitzki » Thu Mar 09, 2017 1:26 am

DeepSOIC wrote:I looked at your fix. IMO body shouldn't be selected after creation at all. Again, this comes from my experience with part-o-magic. It burned me with other workbench tools, in particular Sketcher, which tries to attach a sketch to body (yet add itself to the body), which creates a circular dependency. Here's approximately how it went:
1. create Module.
Module is created, activated, and selected
2. create sketch (sketcher wb)
sketch attaches itself to whatever is selected, which happens to be body.
3. accept attachment -> circular dependency.

Of course, this doesn't apply to PartDesign, since it has its own way of creating sketches. But also there is some chance selection will be filtered out with code introduced at later time, to help eliminate accidental cross-container links.

I see, so the real problem is the body task panel only shows when the body is selected. Fixing that would fix both issues I mentioned. What is the correct way to access the current active body? Gui.ActiveDocument.ActiveView.getActiveObject('pdbody')?

I guess to do this right, I need to not only think about the entry, but also exit conditions for this, right? I'm not sure of the best way to implement this...
User avatar
NormandC
Posts: 12279
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Enhancements to starting Tasks dialog in Part Design

Postby NormandC » Thu Mar 09, 2017 2:13 am

Relating to "Create Part", wouldn't it best be solved by automatically switching to the Model tab after clicking "Create Part"? Then the user would see that the Part has been created.
User avatar
NormandC
Posts: 12279
Joined: Sat Feb 06, 2010 9:52 pm
Location: Québec, Canada

Re: Enhancements to starting Tasks dialog in Part Design

Postby NormandC » Thu Mar 09, 2017 2:17 am

DeepSOIC wrote:BTW, if part-o-magic is active, origin features are shown for new part.

Great idea, and I wish it was the case for PartDesign bodies, or at least an option provided in the Preferences so they would be shown as default.

I thought I had created a feature request about it but it seems I didn't...
User avatar
kkremitzki
Posts: 360
Joined: Thu Mar 03, 2016 9:52 pm
Location: Texas

Re: Enhancements to starting Tasks dialog in Part Design

Postby kkremitzki » Thu Mar 09, 2017 2:29 am

NormandC wrote:Relating to "Create Part", wouldn't it best be solved by automatically switching to the Model tab after clicking "Create Part"? Then the user would see that the Part has been created.

I'm not sure that's enough. Right now it isn't clear for a new user which option to pick. I've seen several threads created about it. If they pick Body, they picked the right door and continue to be guided by the interface on how to proceed. If they picked Part, they picked wrong and are sent to the Model view where they do indeed see a part, but are now further away from having any idea of what to do.
ickby
Posts: 2462
Joined: Wed Oct 05, 2011 7:36 am

Re: Enhancements to starting Tasks dialog in Part Design

Postby ickby » Thu Mar 09, 2017 6:17 am

I think the part option can be removed from that task dialog. A.part is a general object that can group everything, hence it should be available in a global toolbar for every workbench. This would than also eliminate the confusion what to use, body or part, as part design would be clearly centered around body only. The reason for putting the part tool into part design was laziness and the fact that a one tool toolbar would look strange.