Sketcher Offset

Info about new community or project announcements, implemented features, classes, modules or APIs. Might get technical!
PLEASE DO NOT POST HELP REQUESTS OR OTHER DISCUSSIONS HERE!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
User avatar
paddle
Veteran
Posts: 1413
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher Offset

Post by paddle »

shamanths13 wrote: Tue Mar 15, 2022 11:53 am
paddle wrote: Tue Mar 15, 2022 9:36 am ping
Awesome work dude! :D Can't wait to start using all the new features you are implementing! If Im understanding correctly, the scale, offset and circular pattern all create geometry which is unconstrained, irrespective of the constraints on the original selection right? Or are you selectively chosing which constraints to ignore or utilize? Is this the case? I am just curious!
Thanks!
Scale keeps all constraints by scaling the values if needed.
Rotate keep most but distance XY. Though if more than one copy is made then it uses equality.
Offset creates only coincidence. Because offset Geos don't have the same number of geo. There's no easy way to do it.
User avatar
paddle
Veteran
Posts: 1413
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher Offset

Post by paddle »

NewJoker wrote: Tue Mar 15, 2022 11:16 am
paddle wrote: Tue Mar 15, 2022 11:05 am Yes, look at around 5min15 in the offset video above I show the circular pattern/rotate.
All right, so rotation and polar pattern are within the same tool. Makes sense when it comes to the functionality but maybe they could be separated for clarity (there is a rectangular pattern in the Sketcher already and that's where users will look for polar pattern too). However, that's just a minor suggestion, the key here is that these tools are available and work perfectly, as shown in the video :)
The thing is that rotation and circular pattern are basically the same tool. The only difference is the number of copies. So yeah rotation is actually a particular case of circular pattern.
We could have 2 separate tools icons but that feels wrong to add more icons than necessary.
Or we can change the name and icon to circular pattern. Rotation is not used so often by itself. Only to rotate imported SVG or such.

Regarding the placement of the icon, I plan to modify the tool sets anyway. I wanted to see with Abdullah when we reach these tools for merging.

I was also thinking of recreating the rectangular array tool based on the new draw capabilities and snap to point.
Because currently it's hard to use precisely and we can't set the Y distance.
shamanths13
Posts: 80
Joined: Mon Feb 21, 2022 3:02 pm

Re: Sketcher Offset

Post by shamanths13 »

paddle wrote: Tue Mar 15, 2022 12:32 pm ping
I have a suggestion. Keep the rotation and pattern tools separate, but add rotation to a "Transform tool" like in part WB. This allows the ability to move the sketch along either x or y (or maybe even specify a custom translation axis)or rotate about a fixed point. I have a example case for instance where the transform tool to move a sketch and rotate can be used: I create a svg on Inkscape to pocket as a template and then import to sketcher,but I want to move it to align within sketcher or rotate, wrt other sketch elements. Its not easy to move it by say 50 mm on the x axis wrt other preexisting sketcher geometry by box selecting, and I cant just move the sketch because its not constrained.( I faced this problem recently when I tried to import a voronoi pattern I made in inkscape). What do you thing about this? For the pattern tool, have 1 icon, add a dropdown like in the draft workbench that gives us the option to choose either polar pattern or the normal array pattern or maybe in the future a pattern based on equations. You can further combine scale, translate and rotate under one icon called transform(like we already do) with a drop down menu which has these 3 options. So in the end we will have all the functionality clearly separated and accessible without adding too many icons and taking up real estate. What is your opinion on this?
Cheers!
User avatar
NewJoker
Veteran
Posts: 3077
Joined: Sun Oct 11, 2020 7:49 pm

Re: Sketcher Offset

Post by NewJoker »

paddle wrote: Tue Mar 15, 2022 12:32 pm The thing is that rotation and circular pattern are basically the same tool. The only difference is the number of copies. So yeah rotation is actually a particular case of circular pattern.
We could have 2 separate tools icons but that feels wrong to add more icons than necessary.
Or we can change the name and icon to circular pattern. Rotation is not used so often by itself. Only to rotate imported SVG or such.

Regarding the placement of the icon, I plan to modify the tool sets anyway. I wanted to see with Abdullah when we reach these tools for merging.

I was also thinking of recreating the rectangular array tool based on the new draw capabilities and snap to point.
Because currently it's hard to use precisely and we can't set the Y distance.
Then maybe the tool could be named "Rotation/polar pattern" or something like that. The current icon seems to fit both tools so I wouldn't change it. I'm sure that some users will look for the polar pattern while others will try to find the rotation itself. Of course, they can learn from the wiki that polar pattern with one instance is basically what they are looking for but we also have the Move tool in the Sketcher so it feels better to have Polar pattern in addition to Rectangular pattern and Rotation in addition to Move.

I don't know how common the pure rotation will be but I use it quite often when designing lattices. I've also seen one of the main creators of YouTube tutorials for FreeCAD attempting to perform the rotation in the Sketcher, with pretty much no success: https://www.youtube.com/watch?v=UBJrOdnS1nw

By the way, in addition to the Move tool there's also Copy one. So the user can either reposition the selected geometry or copy it to another location. Would it be possible to allow for the same behavior of the rotation tool (either rotate the selected geometry and delete the original or create a copy = pattern with 1 instance) or would this require the separation of polar pattern and rotation ?

And one last thing, the number of copies has a unit of mm in your tool. Can this unit be deleted to avoid the confusion ?
shamanths13
Posts: 80
Joined: Mon Feb 21, 2022 3:02 pm

Re: Sketcher Offset

Post by shamanths13 »

Basically, what im suggesting is in the toolbar have two icons:
  • Transform
  • Pattern
Transform has sub icons if we click on the drop down:
  • Translate
  • Scale
  • Rotate
Pattern has sub icons if we click on the drop down :
  • Rectangular Array
  • Polar/Circular Pattern
  • Custom Pattern based on Equations(in the future, say like following a spiral or something)
What do you guys thing?

Cheers!
User avatar
paddle
Veteran
Posts: 1413
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher Offset

Post by paddle »

NewJoker wrote: Tue Mar 15, 2022 12:59 pm By the way, in addition to the Move tool there's also Copy one. So the user can either reposition the selected geometry or copy it to another location. Would it be possible to allow for the same behavior of the rotation tool (either rotate the selected geometry and delete the original or create a copy = pattern with 1 instance) or would this require the separation of polar pattern and rotation ?

And one last thing, the number of copies has a unit of mm in your tool. Can this unit be deleted to avoid the confusion ?
Regarding move and copy tools, I plan on removing them. For several reasons :

- Move can be replaced by group dragging which feels much more natural.
- Copy tool can be replaced by ctrlC/X ctrlV
- It will be handled by the rectangular pattern tool the same way it is currently the case for rotate/circular pattern

Yes the mm unit in the number of copies is stupid it'll be fixed down the line :)
shamanths13 wrote: Tue Mar 15, 2022 12:53 pm Keep the rotation and pattern tools separate, but add rotation to a "Transform tool" like in part WB.

This allows the ability to move the sketch along either x or y (or maybe even specify a custom translation axis)or rotate about a fixed point. I have a example case for instance where the transform tool to move a sketch and rotate can be used: I create a svg on Inkscape to pocket as a template and then import to sketcher,but I want to move it to align within sketcher or rotate, wrt other sketch elements.

Its not easy to move it by say 50 mm on the x axis wrt other preexisting sketcher geometry by box selecting, and I cant just move the sketch because its not constrained.( I faced this problem recently when I tried to import a voronoi pattern I made in inkscape). What do you thing about this?

For the pattern tool, have 1 icon, add a dropdown like in the draft workbench that gives us the option to choose either polar pattern or the normal array pattern or maybe in the future a pattern based on equations. You can further combine scale, translate and rotate under one icon called transform(like we already do) with a drop down menu which has these 3 options. So in the end we will have all the functionality clearly separated and accessible without adding too many icons and taking up real estate. What is your opinion on this?
Cheers!
Having tool setting indeed opens up a lot of possibility to improve the toolsets. For instance things like current fillet tools 'normal fillet' and 'fillet preserving constraints' are heavy on the interface and can be easily replaced by a checkbox in toolsettings.

Same goes for rectangle tools. There could be a mode 'comboBox' (what you called dropdown) that let you choose the mode between 'rectangle' and 'rectangle by center' and possibly a checkbox that let you add round corners. This way 3 tools icon become 1. It doesn't change much so the question is : is it really useful/better from a UI standpoint?

For transform tools it's the same, we can group them under one tool that would have a combobox, or have them in one icon dropdown (as currently are copy clone and move). There would be 'Move/rectangular pattern' 'rotate/circular pattern' and 'offset'.
User avatar
paddle
Veteran
Posts: 1413
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher Offset

Post by paddle »

shamanths13 wrote: Tue Mar 15, 2022 1:15 pm Basically, what im suggesting is in the toolbar have two icons:
  • Transform
  • Pattern
Transform has sub icons if we click on the drop down:
  • Translate
  • Scale
  • Rotate
Pattern has sub icons if we click on the drop down :
  • Rectangular Array
  • Polar/Circular Pattern
  • Custom Pattern based on Equations(in the future, say like following a spiral or something)
What do you guys thing?

Cheers!
Oh I get it now. So you meant icon's dropdown as are currently move/copy/clone.

I see your meaning. However translate and rectangular array would be identical as well as rotate and circular pattern.
shamanths13
Posts: 80
Joined: Mon Feb 21, 2022 3:02 pm

Re: Sketcher Offset

Post by shamanths13 »

paddle wrote: Tue Mar 15, 2022 1:20 pm ping
The underlying logic is the same between translate and rectangular pattern and rotate and circular pattern, But say I am a newish user, and I want to rotate something, using the circular pattern to do so, or if I want to translate a sketch, using the rectangular pattern to do so seems cumbersome.
Cheers!
User avatar
paddle
Veteran
Posts: 1413
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher Offset

Post by paddle »

shamanths13 wrote: Tue Mar 15, 2022 1:25 pm
paddle wrote: Tue Mar 15, 2022 1:20 pm ping
The underlying logic is the same between translate and rectangular pattern and rotate and circular pattern, But say I am a newish user, and I want to rotate something, using the circular pattern to do so, or if I want to translate a sketch, using the rectangular pattern to do so seems cumbersome.
Cheers!
What about calling them with both names?
"Rotate/Circular pattern"
"Translate/Rectangular pattern".
User avatar
NewJoker
Veteran
Posts: 3077
Joined: Sun Oct 11, 2020 7:49 pm

Re: Sketcher Offset

Post by NewJoker »

paddle wrote: Tue Mar 15, 2022 1:17 pm - Move can be replaced by group dragging which feels much more natural.
- Copy tool can be replaced by ctrlC/X ctrlV
If you can implement something like that, the Move and Copy tools may indeed become unnecessary. Currently, this level of freedom in moving or copying multiple objects is not available in the Sketcher but it would be great to see this. It indeed feels more natural and reduces the number of necessary tools.
Post Reply