From f265f77c943971000e2a298274d23772cf0d2411 Mon Sep 17 00:00:00 2001 From: Trygve Laugstøl Date: Thu, 17 Aug 2017 16:39:39 +0200 Subject: o Adding support for --extended-gerber-attributes and EXTENDED_GERBER_ATTRIBUTES. Changing the hardcoded value True to default False and enabling on option. --- py/kicad_gerber.py | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) (limited to 'py') diff --git a/py/kicad_gerber.py b/py/kicad_gerber.py index 173aae1..7da0a59 100755 --- a/py/kicad_gerber.py +++ b/py/kicad_gerber.py @@ -41,6 +41,11 @@ parser.add_argument('--protel-extensions', action='store_true', help='Use Protel filename extensions instead of .gbr') +parser.add_argument('--extended-gerber-attributes', + dest='extended_gerber_attributes', + action='store_true', + help='Use extended Gerber attributes') + parser.add_argument('--uppercase-extensions', action='store_true', help='Uppercase all extensions') @@ -173,17 +178,18 @@ if args.detect_files_only: # Set some important plot options: popt.SetPlotFrameRef(False) -popt.SetLineWidth(FromMM(0.35)) +popt.SetLineWidth(FromMM(0.1)) popt.SetAutoScale(False) popt.SetScale(1) popt.SetMirror(False) -popt.SetUseGerberAttributes(True) +popt.SetUseGerberAttributes(args.extended_gerber_attributes) popt.SetScale(1) -popt.SetUseAuxOrigin(True) +popt.SetUseAuxOrigin(False) # This by gerbers only (also the name is truly horrid!) popt.SetSubtractMaskFromSilk(False) +popt.SetDrillMarksType(PCB_PLOT_PARAMS.NO_DRILL_SHAPE) for plan in plot_plan: pctl.SetLayer(plan.layerNum) @@ -200,8 +206,6 @@ for plan in plot_plan: pctl.PlotLayer() pctl.ClosePlot() -popt.SetDrillMarksType(PCB_PLOT_PARAMS.FULL_DRILL_SHAPE) - drlwriter = EXCELLON_WRITER(board) drlwriter.SetMapFileFormat(PLOT_FORMAT_GERBER) -- cgit v1.2.3