Macro Dxf To Shape

From FreeCAD Documentation
Jump to: navigation, search
Documentation not finished, not translate thanks


Macro Dxf To Shape.png Macro Dxf To Shape

Description
Macro utility for create unique wire with many wires macro .

Macro version : 01.00
Date last modification : 2020-02-13
FreeCAD version : 0.18, 0.19
Download : ToolBar Icon
Author
Mario52
Download
ToolBar Icon
Links
Macro Version
01.00
Date last modification
2020-02-13
FreeCAD Version(s)
0.18, 0.19
Default shortcut
None
See also
None


Description

Macro utility for create unique wire with many wires, the type wire created is selected to MakeWire, Bspline, BsplineCurve, BsplineCurve + Arc, Polygon, Bezier curve.

Temporary code for external macro link. Do not use this code. This code is used exclusively by Addon_Installer.


##This code is copied instead of the original macro code

##to guide the user to the offline download page

##Use it if the code of the macro is larger than 64 KB and cannot be included in the wiki

##or if the RAW code url is extra wiki location

import PySide

from PySide import QtGui ,QtCore

diag = QtGui.QMessageBox(QtGui.QMessageBox.Information,u"Information",
    "This macro must by downloaded with this link" + "\n"
    " " + "\n"
    "https://gist.githubusercontent.com/mario52a/0596ad522b151806d5970586a5051e4b/raw/5b5de68acf868aa8c20c0ed79376f30802ec576d/Macro_DXF_to_Shape.FCMacro" + "\n"
    " " + "\n"
    "Quit this window for access in the download page" )

diag.setWindowFlags(PySide.QtCore.Qt.WindowStaysOnTopHint)

diag.setWindowModality(QtCore.Qt.ApplicationModal)

diag.exec_()

import webbrowser 

webbrowser.open("https://gist.githubusercontent.com/mario52a/0596ad522b151806d5970586a5051e4b/raw/5b5de68acf868aa8c20c0ed79376f30802ec576d/Macro_DXF_to_Shape.FCMacro")
<class="rawcodeurl"><a href="https://gist.githubusercontent.com/mario52a/0596ad522b151806d5970586a5051e4b/raw/5b5de68acf868aa8c20c0ed79376f30802ec576d/Macro_DXF_to_Shape.FCMacro">raw code</a>


Usage

Principe :

  • downgrade the compound line for work with single line
  • first line discretize the line (precision on choice)
  • the linetest is created on choice MakeWire, Bspline, BsplineCourve, Polygon, BezCurve (display the orientation

Begin - End (Reversed Forward)

  • test is good .. then Save DataT coordinates in file (and Del Test If you want)
  • second line same first line and accord end to begin ....
  • test is good .. then Save DataT coordinates in file (and Del Test If you want)
  • ...... tests finished
  • Read DataT saved in on unique wire with the type line selected

you can also test one sweep, force reverse, close wire, create points, cloud ...

you can also Save the file in disk

( Save DataT, Read DataT, Reset DataT Are the Temporary working file)


Macro_Dxf_To_Shape


Script

The icon for you toolBar Macro Dxf To Shape.png copy in same directory to the macro

How to Customize Toolbars, How to install macros

The script to github Macro_DXF_to_Shape.FCMacro

Example

Here convert Wire (multi lines) in BsplineCurve

Macro Dxf To Shape Convert Wire To BSplineCurve.gif

here with selected face

Macro Dxf To Shape Convert Wire To BSplineCurve02.gif

Links

Mes macros sur Github

Version

  • 13/02/2020 ver 00.00 :
  • 21/11/2016 ver 00.00 :