Macro Compound Plus

Description
Draft command set in a small macro for the 2D wire example: work with the DXF files. The macro detected : Line, Arc, Circle, Ellipse, BSplineCurve and reproduce the DXF wire in a Draft object. The text is converted in ShapeString.

Choice

 * Type I [1 + 1 = 1] : Create one compound unique of all objects selected without history.
 * Type II [1 + 1 = A (1 + 1)] : Create one compound of all objects selected with history of all objects. Same "Menu → Part → Make compound".

Option color
If it checked the colour to object to work are coloured (edge, vertex)
 * : Gives a colour to object. (Default Red 255, 0, 0)

Tools

 * LineEdit : display (Iindex of Font / Number of font) the path and name of the font.
 * : convert the text Draft_Text.svg in a shape string Draft_ShapeString.svg (The height of the text converted is respected but the visual result may not be respected, see the Combo view property for confirm). (A) is Automatic value height of text.
 * : If the spinbox is egual 0.0 the heigth of the VALUE of the text is respected, if other of 0.0 the change to  manual.


 * : This command convert the wire in one line with coordinates. (ex: one compound downgraded does not have coordinates, this function create a line with the coordinate as Draft line and reproduce the DXF wire in a Draft object are detected: Line, Arc, Circle, Ellipse, BSplineCurve.
 * : Gives a thickness of the wire. If the spinbox is egual 0.0 the heigth of the VALUE of the text is respected, if other of 0.0 the change to  manual.
 * : By default the BezierCurve detected is [[Image:Draft_BezCurve.svg|24px]], if it is checked the BezierCurve is Cubic [[Image:Draft_CubicBezCurve.svg|24px]] and the button change


 * : The objects created is FlatLines.
 * : The objects created is Wireframe.
 * : The objects created is Points.
 * : UpGrade
 * : DownGrade

For Compound I and Convert Edge
This section work only with the tools,  and
 * : Everything originals objects remains as it is.
 * : Hidden the originals objest(s).
 * : Delete the originals objest(s).

Force on a form : Line
If the object line, arc or circle is not reconized (as form in a volume 3D object), this section force the creation of Line, Arc or Circle.

no verification is done, this section tray to create a requested shape 2D (Draft) based on the data provided


 * : Tray to create a Line.
 * : Tray to create a Arc.
 * : Tray to create a Circle.
 * : Button Force

Command

 * ProgressBar
 * : Reset the macro
 * : Quit the macro, bye
 * : Display the wiki page in the FreeCAD browser

Script
The icon for you toolBar copy in same directory to the macro

How to Customize Toolbars, How to install macros

The script to github Macro_Compound_Plus.FCMacro

Macro_Compound_Plus.FCMacro

Links
My macros to Github

Version

 * 15/08/2020 ver 0.04 : adding section "Force the forme" if not detected, create Line, Arc and Circle on forced
 * 14/05/2020 ver 00.03 : upgrade pySide2 and Qt5 layout and (matPlotLib Font) and convert Circle, Arc, Ellipse, BezierCurve
 * 24/01/2018 ver 00.02 : sup "import PyQt4"
 * 21/11/2016 ver 00.01 :