Macro: Version 3: helper tools to improve TechDraw documents

Discussions about the development of the TechDraw workbench
mendy
Posts: 243
Joined: Mon May 21, 2018 2:16 pm

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby mendy » Tue Mar 02, 2021 1:28 pm

Many thanks for your contribution. Can verify it fixes text issue. Now off to explore new features. Thanks again.
ngocminhdao88 wrote: Tue Mar 02, 2021 10:28 am Ps: i don't see an option to delete cosmetic objects. Using del key removes the whole view / page.
You use the eraser tool for cosmetic lines. Edit (1+2): Disregard mouse slip at end of gif that points to diagonal line.
Attachments
tdt3.jpg
tdt3.jpg (62.95 KiB) Viewed 1020 times
Erase.gif
Erase.gif (62.14 KiB) Viewed 1020 times
chrisb
Posts: 35223
Joined: Tue Mar 17, 2015 9:14 am

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby chrisb » Tue Mar 02, 2021 2:20 pm

Thanks for this macro! It is really a step forward for TechDraw!
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
edi
Posts: 293
Joined: Fri Jan 17, 2020 1:32 pm

Re: Macro: Version 3.1: helper tools to improve TechDraw documents

Postby edi » Fri Mar 05, 2021 4:19 pm

Attached find version 3.1 of TechDrawTools macro.
TechDrawTools031.FCMacro
(35.32 KiB) Downloaded 63 times
One new tool to create hole tables (suggestion of ngocminhdao88) has been added:
TechDraw06.png
TechDraw06.png (32.62 KiB) Viewed 890 times
Workflow:
- select a vertex, defining the coordinate origin
- select many circles (holes)
- click the button

The tool performs the following:
- create an annotation (A1, A2, ...) near each selected hole (see picture)
- create a Spreadsheet
- import the Spreadsheet into TechDraw (see picture)

Optional you can add information manually to the spreadsheet, and connect it afterwards to your TechDraw document.
It's also possible to edit the annotation texts afterwards.
chrisb
Posts: 35223
Joined: Tue Mar 17, 2015 9:14 am

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby chrisb » Fri Mar 05, 2021 5:39 pm

Can anyone help integrating this valuable macro into the AddonManager?
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
herbk
Posts: 2164
Joined: Mon Nov 03, 2014 3:45 pm
Location: Windsbach, Bavarya (Germany)

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby herbk » Fri Mar 05, 2021 8:03 pm

chrisb wrote: Fri Mar 05, 2021 5:39 pm Can anyone help integrating this valuable macro into the AddonManager?
Wouldn't it be better to integrate it into TechDraw?
Gruß Herbert
chrisb
Posts: 35223
Joined: Tue Mar 17, 2015 9:14 am

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby chrisb » Fri Mar 05, 2021 8:31 pm

herbk wrote: Fri Mar 05, 2021 8:03 pm Wouldn't it be better to integrate it into TechDraw?
Definitely! But as an intermediate step the AddonManager would be good.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
edi
Posts: 293
Joined: Fri Jan 17, 2020 1:32 pm

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby edi » Sat Mar 06, 2021 7:24 am

I will initialize a PR to https://github.com/FreeCAD/FreeCAD-macros. Just have to do some small corrections.
ngocminhdao88
Posts: 18
Joined: Wed Nov 11, 2020 10:43 am

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby ngocminhdao88 » Sat Mar 06, 2021 8:07 am

Hi edi,

somehow i could not use the function "Position section view" from your macro. I can align the section view to its source manually by modifying the base x and y properties (see attachment).

Please add a function to align views horizontally and vertically. This then can be use to align front, top, right, bottom, etc views, not just limited to only section views.

Again, your macro is awesome :)
Attachments
taper-buchse.FCStd
(94.82 KiB) Downloaded 20 times
edi
Posts: 293
Joined: Fri Jan 17, 2020 1:32 pm

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby edi » Sat Mar 06, 2021 8:43 am

@ngocminhdao88: If I open your attached file taper-buchse.FCStd there is a very long model tree in the combo-view, having many items with red !.
I can't see anything in the 3D-View, and there is no Techdraw Page in the model tree.

To use the macro TechDrawTools you need an opened TechDraw Page, because the macros task is to extend a Techdraw drawing.

Techdraw views are connected automatic to there origin if they are top, bottom, left or right views. This can be seen as a ProjGroup in the model tree. But if you create a section view, it is unfortunately not connected to its origin. That is the reason, why I created the 'Position section tool'.
chrisb
Posts: 35223
Joined: Tue Mar 17, 2015 9:14 am

Re: Macro: Version 3: helper tools to improve TechDraw documents

Postby chrisb » Sat Mar 06, 2021 10:12 am

What would be necessary to integrate these functions into TechDraw master? Is it possible to combine C++ and Python in one workbench?
aapo wrote: pinged by pinger macro
chennes wrote: pinged by pinger macro
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.