Pcbnew: add plot on all layers feature.
ADDED: Any addition board layers can be plotted on all selected board layer when plotting. CHANGED: The new plot to all layers feature made the plot edge cuts option obsolete. Users must now select the edge cuts layer from the list of plot to all layer selections to include edge cuts on all layers when plotting. Fixes https://gitlab.com/kicad/code/kicad/-/issues/2449
This commit is contained in:
parent
bd18e340f4
commit
0bdbfe1446
|
@ -14,6 +14,7 @@ hpglpennumber
|
|||
hpglpenoverlay
|
||||
hpglpenspeed
|
||||
layerselection
|
||||
plot_on_all_layers_selection
|
||||
linewidth
|
||||
mirror
|
||||
mode
|
||||
|
|
|
@ -21,6 +21,9 @@
|
|||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <wx/bmpbuttn.h>
|
||||
#include <wx/clntdata.h>
|
||||
#include <wx/rearrangectrl.h>
|
||||
|
||||
#include <kiface_base.h>
|
||||
#include <plotters/plotter.h>
|
||||
|
@ -49,18 +52,102 @@
|
|||
#include <wx/dirdlg.h>
|
||||
|
||||
|
||||
LSET DIALOG_PLOT::m_lastLayerSet;
|
||||
LSEQ DIALOG_PLOT::m_lastPlotOnAllLayersOrder;
|
||||
|
||||
|
||||
/**
|
||||
* A helper wxWidgets control client data object to store layer IDs.
|
||||
*/
|
||||
class PCB_LAYER_ID_CLIENT_DATA : public wxClientData
|
||||
{
|
||||
public:
|
||||
PCB_LAYER_ID_CLIENT_DATA() : m_id( UNDEFINED_LAYER ) { }
|
||||
PCB_LAYER_ID_CLIENT_DATA( PCB_LAYER_ID aId ) : m_id( aId ) { }
|
||||
|
||||
void SetData( PCB_LAYER_ID aId ) { m_id = aId; }
|
||||
|
||||
PCB_LAYER_ID GetData() const { return m_id; }
|
||||
|
||||
private:
|
||||
PCB_LAYER_ID m_id;
|
||||
};
|
||||
|
||||
|
||||
DIALOG_PLOT::DIALOG_PLOT( PCB_EDIT_FRAME* aParent ) :
|
||||
DIALOG_PLOT_BASE( aParent ), m_parent( aParent ),
|
||||
DIALOG_PLOT_BASE( aParent ),
|
||||
m_parent( aParent ),
|
||||
m_defaultPenSize( aParent, m_hpglPenLabel, m_hpglPenCtrl, m_hpglPenUnits ),
|
||||
m_trackWidthCorrection( aParent, m_widthAdjustLabel, m_widthAdjustCtrl, m_widthAdjustUnits )
|
||||
{
|
||||
BOARD* board = m_parent->GetBoard();
|
||||
|
||||
SetName( DLG_WINDOW_NAME );
|
||||
m_plotOpts = aParent->GetPlotSettings();
|
||||
m_DRCWarningTemplate = m_DRCExclusionsWarning->GetLabel();
|
||||
|
||||
m_messagesPanel->SetFileName( Prj().GetProjectPath() + wxT( "report.txt" ) );
|
||||
|
||||
int order = 0;
|
||||
LSET plotOnAllLayersSelection = m_plotOpts.GetPlotOnAllLayersSelection();
|
||||
wxArrayInt plotAllLayersOrder;
|
||||
wxArrayString plotAllLayersChoices;
|
||||
|
||||
for( LSEQ seq = board->GetEnabledLayers().SeqStackupBottom2Top(); seq; ++seq )
|
||||
{
|
||||
PCB_LAYER_ID id = *seq;
|
||||
|
||||
plotAllLayersChoices.Add( board->GetLayerName( id ) );
|
||||
|
||||
size_t size = plotOnAllLayersSelection.size();
|
||||
|
||||
if( ( static_cast<size_t>( id ) <= size ) && plotOnAllLayersSelection.test( id ) )
|
||||
plotAllLayersOrder.push_back( order );
|
||||
else
|
||||
plotAllLayersOrder.push_back( ~order );
|
||||
|
||||
order += 1;
|
||||
}
|
||||
|
||||
wxStaticBoxSizer* sbSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY,
|
||||
_("Plot on All Layers") ),
|
||||
wxVERTICAL );
|
||||
|
||||
m_plotAllLayersList = new wxRearrangeList( sbSizer->GetStaticBox(), wxID_ANY,
|
||||
wxDefaultPosition, wxDefaultSize,
|
||||
plotAllLayersOrder, plotAllLayersChoices, 0 );
|
||||
|
||||
int index = 0;
|
||||
|
||||
for( LSEQ seq = board->GetEnabledLayers().SeqStackupBottom2Top(); seq; ++seq )
|
||||
{
|
||||
m_plotAllLayersList->SetClientObject( index, new PCB_LAYER_ID_CLIENT_DATA( *seq ) );
|
||||
index += 1;
|
||||
}
|
||||
|
||||
sbSizer->Add( m_plotAllLayersList, 1, wxALL | wxEXPAND, 5 );
|
||||
|
||||
wxBoxSizer* bButtonSizer;
|
||||
bButtonSizer = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_bpMoveUp = new wxBitmapButton( sbSizer->GetStaticBox(), wxID_ANY, wxNullBitmap,
|
||||
wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW | 0 );
|
||||
m_bpMoveUp->SetToolTip( _( "Move current selection up" ) );
|
||||
m_bpMoveUp->SetBitmap( KiBitmap( BITMAPS::small_up ) );
|
||||
|
||||
bButtonSizer->Add( m_bpMoveUp, 0, wxALIGN_CENTER_VERTICAL | wxRIGHT, 5 );
|
||||
bButtonSizer->AddStretchSpacer();
|
||||
|
||||
m_bpMoveDown = new wxBitmapButton( sbSizer->GetStaticBox(), wxID_ANY, wxNullBitmap,
|
||||
wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW | 0 );
|
||||
m_bpMoveDown->SetToolTip( _( "Move current selection down" ) );
|
||||
m_bpMoveDown->SetBitmap( KiBitmap( BITMAPS::small_down ) );
|
||||
|
||||
bButtonSizer->Add( m_bpMoveDown, 0, wxALIGN_CENTER_VERTICAL | wxRIGHT, 5 );
|
||||
|
||||
sbSizer->Add( bButtonSizer, 0, wxALL | wxEXPAND, 5 );
|
||||
bmiddleSizer->Insert( 1, sbSizer, 1, wxALL | wxEXPAND, 3 );
|
||||
|
||||
init_Dialog();
|
||||
|
||||
SetupStandardButtons( { { wxID_OK, _( "Plot" ) },
|
||||
|
@ -69,6 +156,16 @@ DIALOG_PLOT::DIALOG_PLOT( PCB_EDIT_FRAME* aParent ) :
|
|||
|
||||
GetSizer()->Fit( this );
|
||||
GetSizer()->SetSizeHints( this );
|
||||
|
||||
m_bpMoveUp->Bind( wxEVT_COMMAND_BUTTON_CLICKED, &DIALOG_PLOT::onPlotAllListMoveUp, this );
|
||||
m_bpMoveDown->Bind( wxEVT_COMMAND_BUTTON_CLICKED, &DIALOG_PLOT::onPlotAllListMoveDown, this );
|
||||
}
|
||||
|
||||
|
||||
DIALOG_PLOT::~DIALOG_PLOT()
|
||||
{
|
||||
m_bpMoveDown->Unbind( wxEVT_COMMAND_BUTTON_CLICKED, &DIALOG_PLOT::onPlotAllListMoveDown, this );
|
||||
m_bpMoveUp->Unbind( wxEVT_COMMAND_BUTTON_CLICKED, &DIALOG_PLOT::onPlotAllListMoveUp, this );
|
||||
}
|
||||
|
||||
|
||||
|
@ -130,7 +227,7 @@ void DIALOG_PLOT::init_Dialog()
|
|||
// Could devote a PlotOrder() function in place of UIOrder().
|
||||
m_layerList = board->GetEnabledLayers().UIOrder();
|
||||
|
||||
// Populate the check list box by all enabled layers names
|
||||
// Populate the check list box by all enabled layers names.
|
||||
for( LSEQ seq = m_layerList; seq; ++seq )
|
||||
{
|
||||
PCB_LAYER_ID layer = *seq;
|
||||
|
@ -164,9 +261,6 @@ void DIALOG_PLOT::init_Dialog()
|
|||
// SVG precision and units for coordinates
|
||||
m_svgPrecsision->SetValue( m_plotOpts.GetSvgPrecision() );
|
||||
|
||||
// Option for excluding contents of "Edges Pcb" layer
|
||||
m_includeEdgeLayerOpt->SetValue( !m_plotOpts.GetExcludeEdgeLayer() );
|
||||
|
||||
// Option to exclude pads from silkscreen layers
|
||||
m_sketchPadsOnFabLayers->SetValue( m_plotOpts.GetSketchPadsOnFabLayers() );
|
||||
|
||||
|
@ -447,7 +541,6 @@ void DIALOG_PLOT::SetPlotFormat( wxCommandEvent& event )
|
|||
m_useAuxOriginCheckBox->Enable( false );
|
||||
m_useAuxOriginCheckBox->SetValue( false );
|
||||
m_defaultPenSize.Enable( false );
|
||||
m_includeEdgeLayerOpt->Enable( true );
|
||||
m_scaleOpt->Enable( false );
|
||||
m_scaleOpt->SetSelection( 1 );
|
||||
m_fineAdjustXCtrl->Enable( false );
|
||||
|
@ -475,7 +568,6 @@ void DIALOG_PLOT::SetPlotFormat( wxCommandEvent& event )
|
|||
m_useAuxOriginCheckBox->Enable( false );
|
||||
m_useAuxOriginCheckBox->SetValue( false );
|
||||
m_defaultPenSize.Enable( false );
|
||||
m_includeEdgeLayerOpt->Enable( true );
|
||||
m_scaleOpt->Enable( true );
|
||||
m_fineAdjustXCtrl->Enable( true );
|
||||
m_fineAdjustYCtrl->Enable( true );
|
||||
|
@ -499,7 +591,6 @@ void DIALOG_PLOT::SetPlotFormat( wxCommandEvent& event )
|
|||
m_plotMirrorOpt->SetValue( false );
|
||||
m_useAuxOriginCheckBox->Enable( true );
|
||||
m_defaultPenSize.Enable( false );
|
||||
m_includeEdgeLayerOpt->Enable( true );
|
||||
m_scaleOpt->Enable( false );
|
||||
m_scaleOpt->SetSelection( 1 );
|
||||
m_fineAdjustXCtrl->Enable( false );
|
||||
|
@ -524,7 +615,6 @@ void DIALOG_PLOT::SetPlotFormat( wxCommandEvent& event )
|
|||
m_useAuxOriginCheckBox->Enable( false );
|
||||
m_useAuxOriginCheckBox->SetValue( false );
|
||||
m_defaultPenSize.Enable( true );
|
||||
m_includeEdgeLayerOpt->Enable( true );
|
||||
m_scaleOpt->Enable( true );
|
||||
m_fineAdjustXCtrl->Enable( false );
|
||||
m_fineAdjustYCtrl->Enable( false );
|
||||
|
@ -548,7 +638,6 @@ void DIALOG_PLOT::SetPlotFormat( wxCommandEvent& event )
|
|||
m_plotMirrorOpt->SetValue( false );
|
||||
m_useAuxOriginCheckBox->Enable( true );
|
||||
m_defaultPenSize.Enable( false );
|
||||
m_includeEdgeLayerOpt->Enable( true );
|
||||
m_scaleOpt->Enable( false );
|
||||
m_scaleOpt->SetSelection( 1 );
|
||||
m_fineAdjustXCtrl->Enable( false );
|
||||
|
@ -625,7 +714,6 @@ void DIALOG_PLOT::applyPlotSettings()
|
|||
int sel;
|
||||
PCB_PLOT_PARAMS tempOptions;
|
||||
|
||||
tempOptions.SetExcludeEdgeLayer( !m_includeEdgeLayerOpt->GetValue() );
|
||||
tempOptions.SetSubtractMaskFromSilk( m_subtractMaskFromSilk->GetValue() );
|
||||
tempOptions.SetPlotFrameRef( m_plotSheetRef->GetValue() );
|
||||
tempOptions.SetSketchPadsOnFabLayers( m_sketchPadsOnFabLayers->GetValue() );
|
||||
|
@ -744,6 +832,26 @@ void DIALOG_PLOT::applyPlotSettings()
|
|||
// Get a list of copper layers that aren't being used by inverting enabled layers.
|
||||
LSET disabledCopperLayers = LSET::AllCuMask() & ~m_parent->GetBoard()->GetEnabledLayers();
|
||||
|
||||
LSET plotOnAllLayers;
|
||||
|
||||
// Add selected layers from plot on all layers list in order set by user.
|
||||
wxArrayInt plotOnAllLayersSelections;
|
||||
|
||||
m_plotAllLayersList->GetCheckedItems( plotOnAllLayersSelections );
|
||||
|
||||
size_t count = plotOnAllLayersSelections.GetCount();
|
||||
|
||||
for( size_t i = 0; i < count; i++ )
|
||||
{
|
||||
int index = plotOnAllLayersSelections.Item( i );
|
||||
wxClientData* tmp = m_plotAllLayersList->GetClientObject( index );
|
||||
PCB_LAYER_ID_CLIENT_DATA* layerId = dynamic_cast<PCB_LAYER_ID_CLIENT_DATA*>( tmp );
|
||||
|
||||
plotOnAllLayers.set( layerId->GetData() );
|
||||
}
|
||||
|
||||
tempOptions.SetPlotOnAllLayersSelection( plotOnAllLayers );
|
||||
|
||||
// Enable all of the disabled copper layers.
|
||||
// If someone enables more copper layers they will be selected by default.
|
||||
selectedLayers = selectedLayers | disabledCopperLayers;
|
||||
|
@ -853,8 +961,7 @@ void DIALOG_PLOT::Plot( wxCommandEvent& event )
|
|||
wxString file_ext( GetDefaultPlotExtension( m_plotOpts.GetFormat() ) );
|
||||
|
||||
// Test for a reasonable scale value
|
||||
// XXX could this actually happen? isn't it constrained in the apply
|
||||
// function?
|
||||
// XXX could this actually happen? isn't it constrained in the apply function?
|
||||
if( m_plotOpts.GetScale() < PLOT_MIN_SCALE )
|
||||
DisplayInfoMessage( this, _( "Warning: Scale option set to a very small value" ) );
|
||||
|
||||
|
@ -875,8 +982,29 @@ void DIALOG_PLOT::Plot( wxCommandEvent& event )
|
|||
// Base layer always gets plotted first.
|
||||
plotSequence.push_back( *seq );
|
||||
|
||||
if( ( *seq != Edge_Cuts ) && !m_plotOpts.GetExcludeEdgeLayer() )
|
||||
plotSequence.push_back( Edge_Cuts );
|
||||
// Add selected layers from plot on all layers list in order set by user.
|
||||
wxArrayInt plotOnAllLayers;
|
||||
|
||||
if( m_plotAllLayersList->GetCheckedItems( plotOnAllLayers ) )
|
||||
{
|
||||
size_t count = plotOnAllLayers.GetCount();
|
||||
|
||||
for( size_t i = 0; i < count; i++ )
|
||||
{
|
||||
int index = plotOnAllLayers.Item( i );
|
||||
wxClientData* tmp = m_plotAllLayersList->GetClientObject( index );
|
||||
PCB_LAYER_ID_CLIENT_DATA* layerId = dynamic_cast<PCB_LAYER_ID_CLIENT_DATA*>( tmp );
|
||||
|
||||
wxCHECK2( layerId, continue );
|
||||
|
||||
// Don't plot the same layer more than once;
|
||||
if( find( plotSequence.begin(), plotSequence.end(), layerId->GetData() ) !=
|
||||
plotSequence.end() )
|
||||
continue;
|
||||
|
||||
plotSequence.push_back( layerId->GetData() );
|
||||
}
|
||||
}
|
||||
|
||||
PCB_LAYER_ID layer = *seq;
|
||||
|
||||
|
@ -954,7 +1082,7 @@ void DIALOG_PLOT::onRunDRC( wxCommandEvent& event )
|
|||
// (low probability, but can happen)
|
||||
drcTool->DestroyDRCDialog();
|
||||
|
||||
// Open a new drc dialod, with the right parent frame, and in Modal Mode
|
||||
// Open a new drc dialog, with the right parent frame, and in Modal Mode
|
||||
drcTool->ShowDRCDialog( this );
|
||||
|
||||
// Update DRC warnings on return to this dialog
|
||||
|
@ -975,3 +1103,18 @@ void DIALOG_PLOT::onBoardSetup( wxHyperlinkEvent& aEvent )
|
|||
reInitDialog();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_PLOT::onPlotAllListMoveUp( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( m_plotAllLayersList->CanMoveCurrentUp() )
|
||||
m_plotAllLayersList->MoveCurrentUp();
|
||||
}
|
||||
|
||||
|
||||
void DIALOG_PLOT::onPlotAllListMoveDown( wxCommandEvent& aEvent )
|
||||
{
|
||||
if( m_plotAllLayersList->CanMoveCurrentDown() )
|
||||
m_plotAllLayersList->MoveCurrentDown();
|
||||
}
|
||||
|
||||
|
|
|
@ -33,6 +33,10 @@
|
|||
// the plot dialog window name, used by wxWidgets
|
||||
#define DLG_WINDOW_NAME wxT( "plot_dialog-window" )
|
||||
|
||||
class wxRearrangeList;
|
||||
class wxBitmapButton;
|
||||
|
||||
|
||||
/**
|
||||
* A dialog to set the plot options and create plot files in various formats.
|
||||
*/
|
||||
|
@ -41,6 +45,8 @@ class DIALOG_PLOT : public DIALOG_PLOT_BASE
|
|||
public:
|
||||
DIALOG_PLOT( PCB_EDIT_FRAME* parent );
|
||||
|
||||
virtual ~DIALOG_PLOT();
|
||||
|
||||
private:
|
||||
// Event called functions
|
||||
void Plot( wxCommandEvent& event ) override;
|
||||
|
@ -55,6 +61,9 @@ private:
|
|||
void onRunDRC( wxCommandEvent& event ) override;
|
||||
void onBoardSetup( wxHyperlinkEvent& aEvent ) override;
|
||||
|
||||
void onPlotAllListMoveUp( wxCommandEvent& aEvent );
|
||||
void onPlotAllListMoveDown( wxCommandEvent& aEvent );
|
||||
|
||||
// other functions
|
||||
void init_Dialog(); // main initialization
|
||||
void reInitDialog(); // initialization after calling drill dialog
|
||||
|
@ -85,4 +94,14 @@ private:
|
|||
wxString m_DRCWarningTemplate;
|
||||
|
||||
PCB_PLOT_PARAMS m_plotOpts;
|
||||
|
||||
wxRearrangeList* m_plotAllLayersList;
|
||||
wxBitmapButton* m_bpMoveUp;
|
||||
wxBitmapButton* m_bpMoveDown;
|
||||
|
||||
/// The plot layer set that last time the dialog was opened.
|
||||
static LSET m_lastLayerSet;
|
||||
|
||||
/// The plot on all layers ordering the last time the dialog was opened.
|
||||
static LSEQ m_lastPlotOnAllLayersOrder;
|
||||
};
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Oct 26 2018)
|
||||
// C++ code generated with wxFormBuilder (version 3.10.0-4761b0c5)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO *NOT* EDIT THIS FILE!
|
||||
|
@ -48,7 +48,6 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
|
||||
m_MainSizer->Add( bupperSizer, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
||||
|
||||
wxBoxSizer* bmiddleSizer;
|
||||
bmiddleSizer = new wxBoxSizer( wxHORIZONTAL );
|
||||
|
||||
m_LayersSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Include Layers") ), wxHORIZONTAL );
|
||||
|
@ -57,7 +56,7 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
m_layerCheckListBox = new wxCheckListBox( m_LayersSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_layerCheckListBoxChoices, 0 );
|
||||
m_layerCheckListBox->SetMinSize( wxSize( 150,-1 ) );
|
||||
|
||||
m_LayersSizer->Add( m_layerCheckListBox, 1, wxEXPAND|wxBOTTOM|wxRIGHT, 5 );
|
||||
m_LayersSizer->Add( m_layerCheckListBox, 1, wxALL|wxEXPAND, 5 );
|
||||
|
||||
|
||||
bmiddleSizer->Add( m_LayersSizer, 1, wxALL|wxEXPAND, 3 );
|
||||
|
@ -90,11 +89,6 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
|
||||
gbSizer1->Add( m_plotInvisibleText, wxGBPosition( 3, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_includeEdgeLayerOpt = new wxCheckBox( sbOptionsSizer->GetStaticBox(), wxID_ANY, _("Plot Edge.Cuts on all layers"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_includeEdgeLayerOpt->SetToolTip( _("Plot the contents of the PCB edge layer on all layers") );
|
||||
|
||||
gbSizer1->Add( m_includeEdgeLayerOpt, wxGBPosition( 4, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_sketchPadsOnFabLayers = new wxCheckBox( sbOptionsSizer->GetStaticBox(), ID_ALLOW_PRINT_PAD_ON_SILKSCREEN, _("Sketch pads on fabrication layers"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_sketchPadsOnFabLayers->SetToolTip( _("Include pad outlines on F.Fab and B.Fab layers when plotting") );
|
||||
|
||||
|
@ -103,7 +97,7 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
m_plotNoViaOnMaskOpt = new wxCheckBox( sbOptionsSizer->GetStaticBox(), wxID_ANY, _("Do not tent vias"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_plotNoViaOnMaskOpt->SetToolTip( _("Remove soldermask on vias") );
|
||||
|
||||
gbSizer1->Add( m_plotNoViaOnMaskOpt, wxGBPosition( 6, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
gbSizer1->Add( m_plotNoViaOnMaskOpt, wxGBPosition( 5, 1 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 30 );
|
||||
|
||||
m_useAuxOriginCheckBox = new wxCheckBox( sbOptionsSizer->GetStaticBox(), wxID_ANY, _("Use drill/place file origin"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_useAuxOriginCheckBox->SetToolTip( _("Use the drill/place file origin as the coordinate origin for plotted files") );
|
||||
|
@ -141,13 +135,13 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
gbSizer1->Add( m_plotModeOpt, wxGBPosition( 2, 2 ), wxGBSpan( 1, 1 ), wxEXPAND|wxLEFT, 5 );
|
||||
|
||||
m_plotMirrorOpt = new wxCheckBox( sbOptionsSizer->GetStaticBox(), ID_MIROR_OPT, _("Mirrored plot"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
gbSizer1->Add( m_plotMirrorOpt, wxGBPosition( 4, 1 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 30 );
|
||||
gbSizer1->Add( m_plotMirrorOpt, wxGBPosition( 4, 0 ), wxGBSpan( 1, 1 ), wxALIGN_CENTER_VERTICAL, 5 );
|
||||
|
||||
m_plotPSNegativeOpt = new wxCheckBox( sbOptionsSizer->GetStaticBox(), wxID_ANY, _("Negative plot"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
gbSizer1->Add( m_plotPSNegativeOpt, wxGBPosition( 5, 1 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 30 );
|
||||
gbSizer1->Add( m_plotPSNegativeOpt, wxGBPosition( 4, 1 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxLEFT, 30 );
|
||||
|
||||
m_zoneFillCheck = new wxCheckBox( sbOptionsSizer->GetStaticBox(), wxID_ANY, _("Check zone fills before plotting"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
gbSizer1->Add( m_zoneFillCheck, wxGBPosition( 6, 1 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT, 30 );
|
||||
gbSizer1->Add( m_zoneFillCheck, wxGBPosition( 6, 0 ), wxGBSpan( 1, 2 ), wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 );
|
||||
|
||||
|
||||
gbSizer1->AddGrowableCol( 0 );
|
||||
|
@ -183,7 +177,7 @@ DIALOG_PLOT_BASE::DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id, const wxStr
|
|||
m_boardSetup = new wxHyperlinkCtrl( this, wxID_ANY, _("Board setup"), wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHL_DEFAULT_STYLE );
|
||||
m_boardSetup->SetToolTip( _("File > Board Setup...") );
|
||||
|
||||
bSizerSecondLine->Add( m_boardSetup, 0, wxTOP|wxRIGHT|wxLEFT, 2 );
|
||||
bSizerSecondLine->Add( m_boardSetup, 0, wxLEFT|wxRIGHT|wxTOP, 2 );
|
||||
|
||||
|
||||
bSizerWarningText->Add( bSizerSecondLine, 1, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<wxFormBuilder_Project>
|
||||
<FileVersion major="1" minor="15" />
|
||||
<FileVersion major="1" minor="16" />
|
||||
<object class="Project" expanded="1">
|
||||
<property name="class_decoration"></property>
|
||||
<property name="code_generation">C++</property>
|
||||
|
@ -14,6 +14,7 @@
|
|||
<property name="file">dialog_plot_base</property>
|
||||
<property name="first_id">1000</property>
|
||||
<property name="help_provider">none</property>
|
||||
<property name="image_path_wrapper_function_name"></property>
|
||||
<property name="indent_with_spaces"></property>
|
||||
<property name="internationalize">1</property>
|
||||
<property name="name">Dialog_Plot_base</property>
|
||||
|
@ -25,6 +26,7 @@
|
|||
<property name="skip_php_events">1</property>
|
||||
<property name="skip_python_events">1</property>
|
||||
<property name="ui_table">UI</property>
|
||||
<property name="use_array_enum">0</property>
|
||||
<property name="use_enum">1</property>
|
||||
<property name="use_microsoft_bom">0</property>
|
||||
<object class="Dialog" expanded="1">
|
||||
|
@ -50,6 +52,7 @@
|
|||
<property name="subclass">DIALOG_SHIM; dialog_shim.h</property>
|
||||
<property name="title">Plot</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="two_step_creation">0</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
|
@ -343,6 +346,7 @@
|
|||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="auth_needed">0</property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="bitmap"></property>
|
||||
|
@ -413,7 +417,7 @@
|
|||
<property name="minimum_size"></property>
|
||||
<property name="name">bmiddleSizer</property>
|
||||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="permission">none</property>
|
||||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">3</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
|
@ -428,7 +432,7 @@
|
|||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxBOTTOM|wxRIGHT</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxCheckListBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -505,7 +509,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticBoxSizer" expanded="0">
|
||||
<object class="wxStaticBoxSizer" expanded="1">
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">General Options</property>
|
||||
<property name="minimum_size"></property>
|
||||
|
@ -513,11 +517,11 @@
|
|||
<property name="orient">wxVERTICAL</property>
|
||||
<property name="parent">1</property>
|
||||
<property name="permission">none</property>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxGridBagSizer" expanded="0">
|
||||
<object class="wxGridBagSizer" expanded="1">
|
||||
<property name="empty_cell_size"></property>
|
||||
<property name="flexible_direction">wxHORIZONTAL</property>
|
||||
<property name="growablecols">0,2</property>
|
||||
|
@ -796,73 +800,6 @@
|
|||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">4</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Plot Edge.Cuts on all layers</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_includeEdgeLayerOpt</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">Plot the contents of the PCB edge layer on all layers</property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
|
@ -931,11 +868,11 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">5</property>
|
||||
<property name="border">30</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">6</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="row">5</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1459,10 +1396,10 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">30</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">1</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL</property>
|
||||
<property name="row">4</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
|
@ -1530,7 +1467,7 @@
|
|||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxLEFT</property>
|
||||
<property name="row">5</property>
|
||||
<property name="row">4</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1593,10 +1530,10 @@
|
|||
</object>
|
||||
</object>
|
||||
<object class="gbsizeritem" expanded="0">
|
||||
<property name="border">30</property>
|
||||
<property name="border">5</property>
|
||||
<property name="colspan">2</property>
|
||||
<property name="column">1</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT|wxLEFT</property>
|
||||
<property name="column">0</property>
|
||||
<property name="flag">wxALIGN_CENTER_VERTICAL|wxRIGHT</property>
|
||||
<property name="row">6</property>
|
||||
<property name="rowspan">1</property>
|
||||
<object class="wxCheckBox" expanded="0">
|
||||
|
@ -1882,7 +1819,7 @@
|
|||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">2</property>
|
||||
<property name="flag">wxTOP|wxRIGHT|wxLEFT</property>
|
||||
<property name="flag">wxLEFT|wxRIGHT|wxTOP</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxHyperlinkCtrl" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
|
@ -1954,7 +1891,7 @@
|
|||
<property name="border">5</property>
|
||||
<property name="flag">wxALL|wxEXPAND</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticBoxSizer" expanded="0">
|
||||
<object class="wxStaticBoxSizer" expanded="1">
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Gerber Options</property>
|
||||
<property name="minimum_size"></property>
|
||||
|
@ -1962,11 +1899,11 @@
|
|||
<property name="orient">wxHORIZONTAL</property>
|
||||
<property name="parent">1</property>
|
||||
<property name="permission">protected</property>
|
||||
<object class="sizeritem" expanded="0">
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT</property>
|
||||
<property name="proportion">1</property>
|
||||
<object class="wxGridBagSizer" expanded="0">
|
||||
<object class="wxGridBagSizer" expanded="1">
|
||||
<property name="empty_cell_size"></property>
|
||||
<property name="flexible_direction">wxHORIZONTAL</property>
|
||||
<property name="growablecols">2</property>
|
||||
|
@ -3808,6 +3745,7 @@
|
|||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="auth_needed">0</property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="bitmap"></property>
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Oct 26 2018)
|
||||
// C++ code generated with wxFormBuilder (version 3.10.0-4761b0c5)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO *NOT* EDIT THIS FILE!
|
||||
|
@ -66,6 +66,7 @@ class DIALOG_PLOT_BASE : public DIALOG_SHIM
|
|||
wxStaticText* m_staticTextDir;
|
||||
wxTextCtrl* m_outputDirectoryName;
|
||||
wxBitmapButton* m_browseButton;
|
||||
wxBoxSizer* bmiddleSizer;
|
||||
wxStaticBoxSizer* m_LayersSizer;
|
||||
wxCheckListBox* m_layerCheckListBox;
|
||||
wxBoxSizer* m_PlotOptionsSizer;
|
||||
|
@ -73,7 +74,6 @@ class DIALOG_PLOT_BASE : public DIALOG_SHIM
|
|||
wxCheckBox* m_plotModuleValueOpt;
|
||||
wxCheckBox* m_plotModuleRefOpt;
|
||||
wxCheckBox* m_plotInvisibleText;
|
||||
wxCheckBox* m_includeEdgeLayerOpt;
|
||||
wxCheckBox* m_sketchPadsOnFabLayers;
|
||||
wxCheckBox* m_plotNoViaOnMaskOpt;
|
||||
wxCheckBox* m_useAuxOriginCheckBox;
|
||||
|
@ -131,7 +131,7 @@ class DIALOG_PLOT_BASE : public DIALOG_SHIM
|
|||
wxButton* m_sdbSizer1Cancel;
|
||||
wxMenu* m_popMenu;
|
||||
|
||||
// Virtual event handlers, overide them in your derived class
|
||||
// Virtual event handlers, override them in your derived class
|
||||
virtual void OnInitDialog( wxInitDialogEvent& event ) { event.Skip(); }
|
||||
virtual void OnRightClick( wxMouseEvent& event ) { event.Skip(); }
|
||||
virtual void SetPlotFormat( wxCommandEvent& event ) { event.Skip(); }
|
||||
|
@ -149,6 +149,7 @@ class DIALOG_PLOT_BASE : public DIALOG_SHIM
|
|||
public:
|
||||
|
||||
DIALOG_PLOT_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Plot"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
||||
|
||||
~DIALOG_PLOT_BASE();
|
||||
|
||||
void DIALOG_PLOT_BASEOnContextMenu( wxMouseEvent &event )
|
||||
|
|
|
@ -101,7 +101,6 @@ PCB_PLOT_PARAMS::PCB_PLOT_PARAMS()
|
|||
|
||||
// we used 0.1mils for SVG step before, but nm precision is more accurate, so we use nm
|
||||
m_svgPrecision = SVG_PRECISION_DEFAULT;
|
||||
m_excludeEdgeLayer = true;
|
||||
m_plotFrameRef = false;
|
||||
m_plotViaOnMaskLayer = false;
|
||||
m_plotMode = FILLED;
|
||||
|
@ -177,6 +176,9 @@ void PCB_PLOT_PARAMS::Format( OUTPUTFORMATTER* aFormatter,
|
|||
aFormatter->Print( aNestLevel+1, "(layerselection 0x%s)\n",
|
||||
m_layerSelection.FmtHex().c_str() );
|
||||
|
||||
aFormatter->Print( aNestLevel+1, "(plot_on_all_layers_selection 0x%s)\n",
|
||||
m_plotOnAllLayersSelection.FmtHex().c_str() );
|
||||
|
||||
aFormatter->Print( aNestLevel+1, "(disableapertmacros %s)\n",
|
||||
printBool( m_gerberDisableApertMacros ) );
|
||||
|
||||
|
@ -203,7 +205,6 @@ void PCB_PLOT_PARAMS::Format( OUTPUTFORMATTER* aFormatter,
|
|||
// SVG options
|
||||
aFormatter->Print( aNestLevel+1, "(svgprecision %d)\n", m_svgPrecision );
|
||||
|
||||
aFormatter->Print( aNestLevel+1, "(excludeedgelayer %s)\n", printBool( m_excludeEdgeLayer ) );
|
||||
aFormatter->Print( aNestLevel+1, "(plotframeref %s)\n", printBool( m_plotFrameRef ) );
|
||||
aFormatter->Print( aNestLevel+1, "(viasonmask %s)\n", printBool( m_plotViaOnMaskLayer ) );
|
||||
aFormatter->Print( aNestLevel+1, "(mode %d)\n", GetPlotMode() == SKETCH ? 2 : 1 );
|
||||
|
@ -255,6 +256,9 @@ bool PCB_PLOT_PARAMS::IsSameAs( const PCB_PLOT_PARAMS &aPcbPlotParams ) const
|
|||
if( m_layerSelection != aPcbPlotParams.m_layerSelection )
|
||||
return false;
|
||||
|
||||
if( m_plotOnAllLayersSelection != aPcbPlotParams.m_plotOnAllLayersSelection )
|
||||
return false;
|
||||
|
||||
if( m_useGerberProtelExtensions != aPcbPlotParams.m_useGerberProtelExtensions )
|
||||
return false;
|
||||
|
||||
|
@ -279,9 +283,6 @@ bool PCB_PLOT_PARAMS::IsSameAs( const PCB_PLOT_PARAMS &aPcbPlotParams ) const
|
|||
if( m_dashedLineGapRatio != aPcbPlotParams.m_dashedLineGapRatio )
|
||||
return false;
|
||||
|
||||
if( m_excludeEdgeLayer != aPcbPlotParams.m_excludeEdgeLayer )
|
||||
return false;
|
||||
|
||||
if( m_plotFrameRef != aPcbPlotParams.m_plotFrameRef )
|
||||
return false;
|
||||
|
||||
|
@ -440,6 +441,26 @@ void PCB_PLOT_PARAMS_PARSER::Parse( PCB_PLOT_PARAMS* aPcbPlotParams )
|
|||
break;
|
||||
}
|
||||
|
||||
case T_plot_on_all_layers_selection:
|
||||
{
|
||||
token = NeedSYMBOLorNUMBER();
|
||||
|
||||
const std::string& cur = CurStr();
|
||||
|
||||
if( cur.find_first_of( "0x" ) == 0 )
|
||||
{
|
||||
// skip the leading 2 0x bytes.
|
||||
aPcbPlotParams->m_plotOnAllLayersSelection.ParseHex( cur.c_str() + 2,
|
||||
cur.size() - 2 );
|
||||
}
|
||||
else
|
||||
{
|
||||
Expecting( "hex plot_on_all_layers_selection" );
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
case T_disableapertmacros:
|
||||
aPcbPlotParams->m_gerberDisableApertMacros = parseBool();
|
||||
break;
|
||||
|
@ -486,7 +507,9 @@ void PCB_PLOT_PARAMS_PARSER::Parse( PCB_PLOT_PARAMS* aPcbPlotParams )
|
|||
break;
|
||||
|
||||
case T_excludeedgelayer:
|
||||
aPcbPlotParams->m_excludeEdgeLayer = parseBool();
|
||||
if( !parseBool() )
|
||||
aPcbPlotParams->m_plotOnAllLayersSelection.set( Edge_Cuts );
|
||||
|
||||
break;
|
||||
|
||||
case T_plotframeref:
|
||||
|
|
|
@ -122,9 +122,6 @@ public:
|
|||
void SetPlotFrameRef( bool aFlag ) { m_plotFrameRef = aFlag; }
|
||||
bool GetPlotFrameRef() const { return m_plotFrameRef; }
|
||||
|
||||
void SetExcludeEdgeLayer( bool aFlag ) { m_excludeEdgeLayer = aFlag; }
|
||||
bool GetExcludeEdgeLayer() const { return m_excludeEdgeLayer; }
|
||||
|
||||
void SetFormat( PLOT_FORMAT aFormat ) { m_format = aFormat; }
|
||||
PLOT_FORMAT GetFormat() const { return m_format; }
|
||||
|
||||
|
@ -160,28 +157,35 @@ public:
|
|||
*/
|
||||
static int GetGerberDefaultPrecision() { return 6; }
|
||||
|
||||
void SetSubtractMaskFromSilk( bool aSubtract ) { m_subtractMaskFromSilk = aSubtract; };
|
||||
void SetSubtractMaskFromSilk( bool aSubtract ) { m_subtractMaskFromSilk = aSubtract; }
|
||||
bool GetSubtractMaskFromSilk() const { return m_subtractMaskFromSilk; }
|
||||
|
||||
void SetLayerSelection( LSET aSelection ) { m_layerSelection = aSelection; };
|
||||
LSET GetLayerSelection() const { return m_layerSelection; };
|
||||
void SetLayerSelection( LSET aSelection ) { m_layerSelection = aSelection; }
|
||||
LSET GetLayerSelection() const { return m_layerSelection; }
|
||||
|
||||
void SetUseAuxOrigin( bool aAux ) { m_useAuxOrigin = aAux; };
|
||||
bool GetUseAuxOrigin() const { return m_useAuxOrigin; };
|
||||
void SetPlotOnAllLayersSelection( LSET aSelection )
|
||||
{
|
||||
m_plotOnAllLayersSelection = aSelection;
|
||||
}
|
||||
|
||||
void SetScaleSelection( int aSelection ) { m_scaleSelection = aSelection; };
|
||||
int GetScaleSelection() const { return m_scaleSelection; };
|
||||
LSET GetPlotOnAllLayersSelection() const { return m_plotOnAllLayersSelection; }
|
||||
|
||||
void SetA4Output( int aForce ) { m_A4Output = aForce; };
|
||||
bool GetA4Output() const { return m_A4Output; };
|
||||
void SetUseAuxOrigin( bool aAux ) { m_useAuxOrigin = aAux; }
|
||||
bool GetUseAuxOrigin() const { return m_useAuxOrigin; }
|
||||
|
||||
void SetScaleSelection( int aSelection ) { m_scaleSelection = aSelection; }
|
||||
int GetScaleSelection() const { return m_scaleSelection; }
|
||||
|
||||
void SetA4Output( int aForce ) { m_A4Output = aForce; }
|
||||
bool GetA4Output() const { return m_A4Output; }
|
||||
|
||||
// For historical reasons, this parameter is stored in mils
|
||||
// (but is in mm in hpgl files...)
|
||||
double GetHPGLPenDiameter() const { return m_HPGLPenDiam; };
|
||||
double GetHPGLPenDiameter() const { return m_HPGLPenDiam; }
|
||||
bool SetHPGLPenDiameter( double aValue );
|
||||
|
||||
// This parameter is always in cm, due to hpgl file format constraint
|
||||
int GetHPGLPenSpeed() const { return m_HPGLPenSpeed; };
|
||||
int GetHPGLPenSpeed() const { return m_HPGLPenSpeed; }
|
||||
bool SetHPGLPenSpeed( int aValue );
|
||||
|
||||
void SetHPGLPenNum( int aVal ) { m_HPGLPenNum = aVal; }
|
||||
|
@ -246,12 +250,12 @@ private:
|
|||
/// True to plot/print frame references
|
||||
bool m_plotFrameRef;
|
||||
|
||||
/// If false always plot (merge) the pcb edge layer on other layers
|
||||
bool m_excludeEdgeLayer;
|
||||
|
||||
/// Set of layers to plot
|
||||
LSET m_layerSelection;
|
||||
|
||||
/// Set of layers that get plotted on each of the layers to plot.
|
||||
LSET m_plotOnAllLayersSelection;
|
||||
|
||||
/** When plotting gerber files, use a conventional set of Protel extensions
|
||||
* instead of .gbr, that is now the official gerber file extension
|
||||
* this is a deprecated feature
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 1992-2018 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 1992-2022 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -25,13 +25,14 @@
|
|||
|
||||
#include <pcb_plot_params_lexer.h>
|
||||
|
||||
|
||||
class wxString;
|
||||
class PCB_PLOT_PARAMS;
|
||||
class LINE_READER;
|
||||
|
||||
|
||||
/**
|
||||
* PCB_PLOT_PARAMS_PARSER
|
||||
* is the parser class for PCB_PLOT_PARAMS.
|
||||
* The parser for PCB_PLOT_PARAMS.
|
||||
*/
|
||||
class PCB_PLOT_PARAMS_PARSER : public PCB_PLOT_PARAMS_LEXER
|
||||
{
|
||||
|
@ -47,25 +48,25 @@ private:
|
|||
bool parseBool();
|
||||
|
||||
/**
|
||||
* Function parseInt
|
||||
* parses an integer and constrains it between two values.
|
||||
* Parse an integer and constrains it between two values.
|
||||
*
|
||||
* @param aMin is the smallest return value.
|
||||
* @param aMax is the largest return value.
|
||||
* @return int - the parsed integer.
|
||||
* @return the parsed integer.
|
||||
*/
|
||||
int parseInt( int aMin, int aMax );
|
||||
|
||||
/**
|
||||
* Function parseDouble
|
||||
* parses a double
|
||||
* @return double - the parsed double.
|
||||
* Parse a double precision floating point number.
|
||||
*
|
||||
* @return the parsed double.
|
||||
*/
|
||||
double parseDouble();
|
||||
|
||||
/**
|
||||
* Function skipCurrent
|
||||
* Skip the current token level, i.e
|
||||
* search for the RIGHT parenthesis which closes the current description
|
||||
* Skip the current token level.
|
||||
*
|
||||
* Search for the RIGHT parenthesis which closes the current description.
|
||||
*/
|
||||
void skipCurrent();
|
||||
};
|
||||
|
|
|
@ -118,7 +118,8 @@ class SHAPE_LINE_CHAIN;
|
|||
//#define SEXPR_BOARD_FILE_VERSION 20220131 // Textboxes
|
||||
//#define SEXPR_BOARD_FILE_VERSION 20220211 // End support for V5 zone fill strategy
|
||||
//#define SEXPR_BOARD_FILE_VERSION 20220225 // Remove TEDIT
|
||||
#define SEXPR_BOARD_FILE_VERSION 20220308 // Knockout text and Locked graphic text property saved
|
||||
//#define SEXPR_BOARD_FILE_VERSION 20220308 // Knockout text and Locked graphic text property saved
|
||||
#define SEXPR_BOARD_FILE_VERSION 20220331 // Plot on all layers selection setting.
|
||||
|
||||
#define BOARD_FILE_HOST_VERSION 20200825 ///< Earlier files than this include the host tag
|
||||
#define LEGACY_ARC_FORMATTING 20210925 ///< These were the last to use old arc formatting
|
||||
|
|
Loading…
Reference in New Issue