From cd7143c5b73aaf4b13fcf6f10db53ea33bba4d4d Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 19 Jun 2014 09:12:48 +0200 Subject: [PATCH] Gerber X2 patch (Support for the "file function" attribute) from Thiadmer Riemersma, committed in rev 4948: minor fix for better compatibility with older versions of Pcbnew --- pcbnew/pcb_plot_params.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pcbnew/pcb_plot_params.cpp b/pcbnew/pcb_plot_params.cpp index bc9ce8bbb6..20a51562a0 100644 --- a/pcbnew/pcb_plot_params.cpp +++ b/pcbnew/pcb_plot_params.cpp @@ -130,8 +130,11 @@ void PCB_PLOT_PARAMS::Format( OUTPUTFORMATTER* aFormatter, long(m_layerSelection) ); aFormatter->Print( aNestLevel+1, "(%s %s)\n", getTokenName( T_usegerberextensions ), m_useGerberExtensions ? trueStr : falseStr ); - aFormatter->Print( aNestLevel+1, "(%s %s)\n", getTokenName( T_usegerberattributes ), - m_useGerberAttributes ? trueStr : falseStr ); + + if( m_useGerberAttributes ) // save this option only if active, + // to avoid incompatibility with older Pcbnew version + aFormatter->Print( aNestLevel+1, "(%s %s)\n", getTokenName( T_usegerberattributes ), trueStr ); + aFormatter->Print( aNestLevel+1, "(%s %s)\n", getTokenName( T_excludeedgelayer ), m_excludeEdgeLayer ? trueStr : falseStr ); aFormatter->Print( aNestLevel+1, "(%s %f)\n", getTokenName( T_linewidth ),