Sketcher new feature : Insert on line

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!
Post Reply
User avatar
paddle
Veteran
Posts: 1392
Joined: Mon Feb 03, 2020 4:47 pm

Sketcher new feature : Insert on line

Post by paddle »

Hey guys,
I implemented the idea of Shalmeneser discussed here : https://forum.freecadweb.org/viewtopic.php?f=19&t=66136
Shalmeneser wrote: Wed Feb 09, 2022 7:56 pm Something less specific but more useful.
2) inside border
phpBB [video]


Also I suggest that Split, Insert, Extend and trim are all put in the same dropdown. This would reduce tool bar size and they are very thematic together.

What do you think?
I know it's not as usefull as the missing offset and circular patter but those need more thoughts and answers :)
toni_lv
Posts: 11
Joined: Tue Nov 03, 2020 8:10 pm
Location: Spain

Re: Sketcher new feature : Insert on line

Post by toni_lv »

Very interesting tool, could be very useful to shape joints between metal or wooden sheets with more connections types as in this old macro (https://www.youtube.com/watch?v=N5_IIr6b4IU).
Maybe adding a dovetail joint (https://en.wikipedia.org/wiki/Dovetail_joint]) would also be interesting to have inside this same tool.
Congratulations for your work Sketcher is improving a lot.
openBrain
Veteran
Posts: 9034
Joined: Fri Nov 09, 2018 5:38 pm
Contact:

Re: Sketcher new feature : Insert on line

Post by openBrain »

Looks pretty cool, even if I'm not sure I would need it.

Didn't see the PR, so no remark about that (for once :razz:).

About this feature specifically :
* You should use endpoint/endpoint perpendicular constraints rather than curve/curve ones. This would make the sketch more readable
* What happens when arc center distance to line is set to 0 ? You should not use a distance of 0, but a geometrical constraint

More general remarks :
* When you test your features, you should always disable "Auto remove redundant" because having it enable may hide problems
* "Tool setting" seems to me something that users are demanding. I think you should first polish the code of it and submit a dedicated PR. Could be good that user can choose to have it disabled, or present in the Task panel (as now), or popping up as a floating widget
User avatar
paddle
Veteran
Posts: 1392
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher new feature : Insert on line

Post by paddle »

toni_lv wrote: Tue Feb 15, 2022 9:59 pm Very interesting tool, could be very useful to shape joints between metal or wooden sheets with more connections types as in this old macro (https://www.youtube.com/watch?v=N5_IIr6b4IU).
Maybe adding a dovetail joint (https://en.wikipedia.org/wiki/Dovetail_joint]) would also be interesting to have inside this same tool.
Congratulations for your work Sketcher is improving a lot.
Thanks! Dovetail join you mean a box with angles instead of perpendicular box? And have the tool alternate between box, dovetail, arc1, arc2? I think this might be a little bit too specific no?
openBrain wrote: Wed Feb 16, 2022 7:01 am Looks pretty cool, even if I'm not sure I would need it.

Didn't see the PR, so no remark about that (for once :razz:).

About this feature specifically :
* You should use endpoint/endpoint perpendicular constraints rather than curve/curve ones. This would make the sketch more readable
* What happens when arc center distance to line is set to 0 ? You should not use a distance of 0, but a geometrical constraint

More general remarks :
* When you test your features, you should always disable "Auto remove redundant" because having it enable may hide problems
* "Tool setting" seems to me something that users are demanding. I think you should first polish the code of it and submit a dedicated PR. Could be good that user can choose to have it disabled, or present in the Task panel (as now), or popping up as a floating widget
I built it on top of toolsettings so it will need to wait until the rest is merged.

- I've changed to that.
- if distance is 0 it's replaced by pointOnObject to one of the lines.

- Good idea about disabling auto remove redundant.
- Abdullah has reviewed the code for 'tool settings' and has submited an architecture idea for it (based on a widget factory, see https://github.com/FreeCAD/FreeCAD/pull ... 1040288030)
This will take some time to implement as I'm not sure how to do it. But yes the idea is to start by making a first PR for tool settings + one tool (chamfer). Then from there submit more PR to support more tools.
User avatar
Shalmeneser
Veteran
Posts: 9474
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: Sketcher new feature : Insert on line

Post by Shalmeneser »

I don't understand the 3rd shift mode :
1) rectangle (mouse side)
2) circle (mouse side)
3) circle (non-mouse side)

Could be : (always mouse side)
1) rectangle
2) circle with center on line (half-circle)
3) circle with center not on line
4) half-slot

Key-modificator should be the same than Polyline.
User avatar
paddle
Veteran
Posts: 1392
Joined: Mon Feb 03, 2020 4:47 pm

Re: Sketcher new feature : Insert on line

Post by paddle »

Shalmeneser wrote: Wed Feb 16, 2022 3:08 pm I don't understand the 3rd shift mode :
1) rectangle (mouse side)
2) circle (mouse side)
3) circle (non-mouse side)

Could be : (always mouse side)
1) rectangle
2) circle with center on line (half-circle)
3) circle with center not on line
4) half-slot

Key-modificator should be the same than Polyline.
Mouse position is the center of the arc, which can be on both side. Otherwise you can do only arcs less than 180.
Half slot is an idea. Though what is the usecase? Isn't it a bit overkill? Though if it's only an additional switch mode it would be such a bother.
Key is same on my branch, I changed it to shift because of tool settings. After discussion it appeared to be the best candidate.
toni_lv
Posts: 11
Joined: Tue Nov 03, 2020 8:10 pm
Location: Spain

Re: Sketcher new feature : Insert on line

Post by toni_lv »

paddle wrote: Wed Feb 16, 2022 9:26 am
Thanks! Dovetail join you mean a box with angles instead of perpendicular box? And have the tool alternate between box, dovetail, arc1, arc2? I think this might be a little bit too specific no?
Yes, could be many commands inside Sketcher
Post Reply