KiCad PCB EDA Suite
|
#include <pcb_plotter.h>
Public Member Functions | |
PCB_PLOTTER (BOARD *aBoard, REPORTER *aReporter, PCB_PLOT_PARAMS &aParams) | |
bool | Plot (const wxString &aOutputPath, const LSEQ &aLayersToPlot, const LSEQ &aCommonLayers, bool aUseGerberFileExtensions) |
bool | copperLayerShouldBeSkipped (PCB_LAYER_ID aLayerToPlot) |
All copper layers that are disabled are actually selected This is due to wonkyness in automatically selecting copper layers for plotting when adding more than two layers to a board. | |
Static Public Member Functions | |
static void | BuildPlotFileName (wxFileName *aFilename, const wxString &aOutputDir, const wxString &aSuffix, const wxString &aExtension) |
Complete a plot filename. | |
static void | PlotJobToPlotOpts (PCB_PLOT_PARAMS &aPlotOpts, JOB_EXPORT_PCB_PLOT *aJob) |
Translate a JOB to PCB_PLOT_PARAMS. | |
Protected Attributes | |
BOARD * | m_board |
PCB_PLOT_PARAMS | m_plotOpts |
REPORTER * | m_reporter |
Private Member Functions | |
LSEQ | getPlotSequence (PCB_LAYER_ID aLayerToPlot, LSEQ aPlotWithAllLayersSeq) |
Generates a final LSEQ for plotting by removing duplicates. | |
Definition at line 33 of file pcb_plotter.h.
PCB_PLOTTER::PCB_PLOTTER | ( | BOARD * | aBoard, |
REPORTER * | aReporter, | ||
PCB_PLOT_PARAMS & | aParams | ||
) |
Definition at line 39 of file pcb_plotter.cpp.
|
static |
Complete a plot filename.
It forces the output directory, adds a suffix to the name, and sets the specified extension. The suffix is usually the layer name and replaces illegal file name character in the suffix with an underscore character.
aFilename | is the file name to initialize that contains the base filename. |
aOutputDir | is the path. |
aSuffix | is the suffix to add to the base filename. |
aExtension | is the file extension. |
Definition at line 223 of file pcb_plotter.cpp.
Referenced by BuildPlotFileName(), and Plot().
bool PCB_PLOTTER::copperLayerShouldBeSkipped | ( | PCB_LAYER_ID | aLayerToPlot | ) |
All copper layers that are disabled are actually selected This is due to wonkyness in automatically selecting copper layers for plotting when adding more than two layers to a board.
If plot options become accessible to the layers setup dialog please move this functionality there! This skips a copper layer if it is actually disabled on the board.
Definition at line 217 of file pcb_plotter.cpp.
References LSET::AllCuMask(), BOARD::GetEnabledLayers(), and m_board.
Referenced by Plot().
|
private |
Generates a final LSEQ for plotting by removing duplicates.
Definition at line 255 of file pcb_plotter.cpp.
References find.
Referenced by Plot().
bool PCB_PLOTTER::Plot | ( | const wxString & | aOutputPath, |
const LSEQ & | aLayersToPlot, | ||
const LSEQ & | aCommonLayers, | ||
bool | aUseGerberFileExtensions | ||
) |
Definition at line 45 of file pcb_plotter.cpp.
References _, BuildPlotFileName(), copperLayerShouldBeSkipped(), PLOTTER::EndPlot(), ExpandTextVars(), FILEEXT::GerberJobFileExtension, PCB_PLOT_PARAMS::GetCreateGerberJobFile(), GetDefaultPlotExtension(), BOARD::GetFileName(), PCB_PLOT_PARAMS::GetFormat(), GetGerberProtelExtension(), BOARD::GetLayerName(), getPlotSequence(), TITLE_BLOCK::GetTitle(), BOARD::GetTitleBlock(), m_board, PCB_PLOT_PARAMS::m_PDFMetadata, PCB_PLOT_PARAMS::m_PDFSingle, m_plotOpts, m_reporter, PlotBoardLayers(), PlotInteractiveLayer(), PLOTTER::RenderSettings(), REPORTER::Report(), REPORTER::ReportTail(), BOARD::ResolveTextVar(), RPT_SEVERITY_ACTION, RPT_SEVERITY_ERROR, RPT_SEVERITY_INFO, PLOTTER::SetAuthor(), PLOTTER::SetSubject(), PLOTTER::SetTitle(), setupPlotterNewPDFPage(), and StartPlotBoard().
Referenced by PCBNEW_JOBS_HANDLER::JobExportDxf(), PCBNEW_JOBS_HANDLER::JobExportPdf(), PCBNEW_JOBS_HANDLER::JobExportSvg(), and DIALOG_PLOT::Plot().
|
static |
Translate a JOB to PCB_PLOT_PARAMS.
Definition at line 277 of file pcb_plotter.cpp.
References JOB_EXPORT_PCB_PLOT::DXF, JOB_EXPORT_PCB_PLOT::FULL_DRILL_SHAPE, JOB_EXPORT_PCB_PLOT::GERBER, JOB_EXPORT_PCB_PLOT::HPGL, JOB_EXPORT_PCB_DXF::INCHES, JOB_EXPORT_PCB_PLOT::m_blackAndWhite, JOB_EXPORT_PCB_GERBERS::m_createJobsFile, JOB_EXPORT_PCB_PLOT::m_crossoutDNPFPsOnFabLayers, JOB_EXPORT_PCB_GERBER::m_disableApertureMacros, JOB_EXPORT_PCB_PLOT::m_drillShapeOption, JOB_EXPORT_PCB_DXF::m_dxfUnits, JOB_EXPORT_PCB_PLOT::m_hideDNPFPsOnFabLayers, JOB_EXPORT_PCB_GERBER::m_includeNetlistAttributes, JOB_EXPORT_PCB_PLOT::m_mirror, JOB_EXPORT_PCB_PLOT::m_negative, JOB_EXPORT_PCB_PDF::m_pdfBackFPPropertyPopups, PCB_PLOT_PARAMS::m_PDFBackFPPropertyPopups, JOB_EXPORT_PCB_PDF::m_pdfFrontFPPropertyPopups, PCB_PLOT_PARAMS::m_PDFFrontFPPropertyPopups, JOB_EXPORT_PCB_PDF::m_pdfMetadata, PCB_PLOT_PARAMS::m_PDFMetadata, JOB_EXPORT_PCB_PDF::m_pdfSingle, PCB_PLOT_PARAMS::m_PDFSingle, JOB_EXPORT_PCB_PLOT::m_plotDrawingSheet, JOB_EXPORT_PCB_PLOT::m_plotFormat, JOB_EXPORT_PCB_DXF::m_plotGraphicItemsUsingContours, JOB_EXPORT_PCB_PLOT::m_plotInvisibleText, JOB_EXPORT_PCB_PLOT::m_plotPadNumbers, JOB_EXPORT_PCB_DXF::m_polygonMode, JOB_EXPORT_PCB_GERBER::m_precision, JOB_EXPORT_PCB_SVG::m_precision, JOB_EXPORT_PCB_PLOT::m_printMaskLayer, JOB_EXPORT_PCB_PLOT::m_printMaskLayersToIncludeOnAllLayers, JOB_EXPORT_PCB_PLOT::m_sketchDNPFPsOnFabLayers, JOB_EXPORT_PCB_PLOT::m_sketchPadsOnFabLayers, JOB_EXPORT_PCB_GERBER::m_subtractSolderMaskFromSilk, JOB_EXPORT_PCB_PLOT::m_useDrillOrigin, JOB_EXPORT_PCB_GERBER::m_useProtelFileExtension, JOB_EXPORT_PCB_GERBER::m_useX2Format, JOB_EXPORT_PCB_PLOT::NO_DRILL_SHAPE, JOB_EXPORT_PCB_PLOT::PDF, JOB_EXPORT_PCB_PLOT::POST, PCB_PLOT_PARAMS::SetBlackAndWhite(), PCB_PLOT_PARAMS::SetCreateGerberJobFile(), PCB_PLOT_PARAMS::SetCrossoutDNPFPsOnFabLayers(), PCB_PLOT_PARAMS::SetDisableGerberMacros(), PCB_PLOT_PARAMS::SetDrillMarksType(), PCB_PLOT_PARAMS::SetDXFPlotPolygonMode(), PCB_PLOT_PARAMS::SetDXFPlotUnits(), PCB_PLOT_PARAMS::SetFormat(), PCB_PLOT_PARAMS::SetGerberPrecision(), PCB_PLOT_PARAMS::SetHideDNPFPsOnFabLayers(), PCB_PLOT_PARAMS::SetIncludeGerberNetlistInfo(), PCB_PLOT_PARAMS::SetLayerSelection(), PCB_PLOT_PARAMS::SetMirror(), PCB_PLOT_PARAMS::SetNegative(), PCB_PLOT_PARAMS::SetPlotFrameRef(), PCB_PLOT_PARAMS::SetPlotInvisibleText(), PCB_PLOT_PARAMS::SetPlotMode(), PCB_PLOT_PARAMS::SetPlotOnAllLayersSelection(), PCB_PLOT_PARAMS::SetPlotPadNumbers(), PCB_PLOT_PARAMS::SetSketchDNPFPsOnFabLayers(), PCB_PLOT_PARAMS::SetSketchPadsOnFabLayers(), PCB_PLOT_PARAMS::SetSubtractMaskFromSilk(), PCB_PLOT_PARAMS::SetSvgPrecision(), PCB_PLOT_PARAMS::SetUseAuxOrigin(), PCB_PLOT_PARAMS::SetUseGerberProtelExtensions(), PCB_PLOT_PARAMS::SetUseGerberX2format(), JOB_EXPORT_PCB_PLOT::SMALL_DRILL_SHAPE, and JOB_EXPORT_PCB_PLOT::SVG.
Referenced by DIALOG_PLOT::DIALOG_PLOT(), PCBNEW_JOBS_HANDLER::JobExportDxf(), PCBNEW_JOBS_HANDLER::JobExportPdf(), and PCBNEW_JOBS_HANDLER::JobExportSvg().
|
protected |
Definition at line 72 of file pcb_plotter.h.
Referenced by copperLayerShouldBeSkipped(), and Plot().
|
protected |
Definition at line 73 of file pcb_plotter.h.
Referenced by Plot().
|
protected |
Definition at line 74 of file pcb_plotter.h.
Referenced by Plot().