KiCad PCB EDA Suite
Loading...
Searching...
No Matches
dialog_board_statistics.cpp
Go to the documentation of this file.
1/*
2 * This program source code file is part of KiCad, a free EDA CAD application.
3 *
4 * Copyright (C) 2019 Alexander Shuklin, [email protected]
5 * Copyright The KiCad Developers, see AUTHORS.txt for contributors.
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <https://www.gnu.org/licenses/>.
19 */
20
21
23#include <board_statistics.h>
24
25#include <algorithm>
26
27#include <wx/filedlg.h>
28
29#include <board.h>
30#include <kiplatform/ui.h>
31#include <confirm.h>
32#include <pad.h>
33#include <pcb_edit_frame.h>
34#include <macros.h>
35#include <string_utils.h>
37#include <widgets/ui_common.h>
38#include <widgets/wx_grid.h>
40#include <algorithm>
41
42
43
44
45#define COL_LABEL 0
46#define COL_AMOUNT 1
47
48// Defines for components view
49#define ROW_LABEL 0
50#define COL_FRONT_SIDE 1
51#define COL_BOTTOM_SIDE 2
52#define COL_TOTAL 3
53
54// Defines for board view
55#define ROW_BOARD_DIMS 0
56#define ROW_BOARD_AREA 1
57#define ROW_FRONT_COPPER_AREA 2
58#define ROW_BACK_COPPER_AREA 3
59#define ROW_MIN_CLEARANCE 4
60#define ROW_MIN_TRACK_WIDTH 5
61#define ROW_MIN_DRILL_DIAMETER 6
62#define ROW_BOARD_THICKNESS 7
63#define ROW_FOOTPRINT_COURTYARD_FRONT_AREA 8
64#define ROW_FRONT_COMPONENT_DENSITY 9
65#define ROW_FOOTPRINT_COURTYARD_BACK_AREA 10
66#define ROW_BACK_COMPONENT_DENSITY 11
67
68
73{
81
82 // Flags to remember last checkboxes state
86
87 // Variables to save last report file name and folder
88 bool saveReportInitialized; // true after the 3 next string are initialized
89 wxString saveReportFolder; // last report folder
90 wxString saveReportName; // last report filename
91 wxString m_project; // name of the project used to create the last report
92 // used to reinit last state after a project change
93};
94
95
97
99 DIALOG_BOARD_STATISTICS_BASE( aParentFrame ),
100 m_frame( aParentFrame ),
103{
104 m_gridDrills->Connect( wxEVT_GRID_COL_SORT,
105 wxGridEventHandler( DIALOG_BOARD_STATISTICS::drillGridSort ),
106 nullptr, this );
107
108 m_checkBoxExcludeComponentsNoPins->SetValue( s_savedDialogState.excludeNoPins );
109 m_checkBoxSubtractHoles->SetValue( s_savedDialogState.subtractHoles );
110 m_checkBoxSubtractHolesFromCopper->SetValue( s_savedDialogState.subtractHolesFromCopper );
111
112 wxFont labelFont = KIUI::GetSmallInfoFont( this );
113 m_componentsLabel->SetFont( labelFont );
114 m_boardLabel->SetFont( labelFont );
115 m_padsLabel->SetFont( labelFont );
116 m_viasLabel->SetFont( labelFont );
117
118 // Make labels for grids
119 m_gridComponents->SetCellValue( ROW_LABEL, COL_FRONT_SIDE, _( "Front Side" ) );
120 m_gridComponents->SetCellValue( ROW_LABEL, COL_BOTTOM_SIDE, _( "Back Side" ) );
121 m_gridComponents->SetCellValue( ROW_LABEL, COL_TOTAL, _( "Total" ) );
122
123 wxFont headingFont = KIUI::GetStatusFont( this );
124
125 for( int col = COL_AMOUNT; col < m_gridComponents->GetNumberCols(); col++ )
126 m_gridComponents->SetCellFont( ROW_LABEL, col, headingFont );
127
128 m_gridBoard->SetCellValue( ROW_BOARD_DIMS, COL_LABEL, _( "Dimensions:" ) );
129 m_gridBoard->SetCellValue( ROW_BOARD_AREA, COL_LABEL, _( "Area:" ) );
130 m_gridBoard->SetCellValue( ROW_FRONT_COPPER_AREA, COL_LABEL, _( "Front copper area:" ) );
131 m_gridBoard->SetCellValue( ROW_BACK_COPPER_AREA, COL_LABEL, _( "Back copper area:" ) );
132 m_gridBoard->SetCellValue( ROW_MIN_CLEARANCE, COL_LABEL, _( "Min track clearance:" ) );
133 m_gridBoard->SetCellValue( ROW_MIN_TRACK_WIDTH, COL_LABEL, _( "Min track width:" ) );
134 m_gridBoard->SetCellValue( ROW_MIN_DRILL_DIAMETER, COL_LABEL, _( "Min drill diameter:" ) );
135 m_gridBoard->SetCellValue( ROW_BOARD_THICKNESS, COL_LABEL, _( "Board stackup thickness:" ) );
136 m_gridBoard->SetCellValue( ROW_FOOTPRINT_COURTYARD_FRONT_AREA, COL_LABEL, _( "Front footprint area:" ) );
137 m_gridBoard->SetCellValue( ROW_FRONT_COMPONENT_DENSITY, COL_LABEL, _( "Front footprint density:" ) );
138 m_gridBoard->SetCellValue( ROW_FOOTPRINT_COURTYARD_BACK_AREA, COL_LABEL, _( "Back footprint area:" ) );
139 m_gridBoard->SetCellValue( ROW_BACK_COMPONENT_DENSITY, COL_LABEL, _( "Back footprint density:" ) );
140
142 {
143 // Remove wxgrid's selection boxes
144 grid->SetCellHighlightPenWidth( 0 );
145 grid->SetColMinimalAcceptableWidth( 80 );
146
147 for( int row = 0; row < grid->GetNumberRows(); row++ )
148 {
149 grid->SetCellAlignment( row, COL_LABEL, wxALIGN_LEFT, wxALIGN_CENTRE );
150
151 for( int col = COL_AMOUNT; col < grid->GetNumberCols(); col++ )
152 grid->SetCellAlignment( row, col, wxALIGN_RIGHT, wxALIGN_CENTER );
153 }
154 }
155
156 wxFileName fn = m_frame->GetBoard()->GetFileName();
157
158 if( !s_savedDialogState.saveReportInitialized
159 || s_savedDialogState.m_project != Prj().GetProjectFullName() )
160 {
161 fn.SetName( fn.GetName() + wxT( "_report" ) );
162 fn.SetExt( wxT( "txt" ) );
163 s_savedDialogState.saveReportName = fn.GetFullName();
164 s_savedDialogState.saveReportFolder = wxPathOnly( Prj().GetProjectFullName() );
166 s_savedDialogState.saveReportInitialized = true;
167 }
168
169 // The wxStdDialogButtonSizer wxID_CANCLE button is in fact a close button
170 // Nothing to cancel:
171 m_sdbControlSizerCancel->SetLabel( _( "Close" ) );
172}
173
174
176{
178
179 int appendRows = static_cast<int>( m_statsData.footprintEntries.size() ) + 2 - m_gridComponents->GetNumberRows();
180
181 if( appendRows > 0 )
182 m_gridComponents->AppendRows( appendRows );
183
184 appendRows = static_cast<int>( m_statsData.padEntries.size() ) + 1
185 + static_cast<int>( m_statsData.padPropertyEntries.size() ) - m_gridPads->GetNumberRows();
186
187 if( appendRows > 0 )
188 m_gridPads->AppendRows( appendRows );
189
190 appendRows = static_cast<int>( m_statsData.viaEntries.size() ) + 1 - m_gridVias->GetNumberRows();
191
192 if( appendRows > 0 )
193 m_gridVias->AppendRows( appendRows );
194}
195
196
198{
202
203 Layout();
204 m_drillsPanel->Layout();
205
206 m_gridDrills->AutoSizeColumns();
209
210 // Add space for the vertical scrollbar, so that it won't overlap with the cells.
211 m_gridDrills->SetMinSize( wxSize( m_gridDrills->GetEffectiveMinSize().x
212 + wxSystemSettings::GetMetric( wxSYS_VSCROLL_X ),
213 60 ) );
214
216
218 return true;
219}
220
221
223{
228
229 ComputeBoardStatistics( m_frame->GetBoard(), options, m_statsData );
230
231 m_gridDrills->ClearRows();
232
233 if( !m_statsData.drillEntries.empty() )
234 m_gridDrills->AppendRows( static_cast<int>( m_statsData.drillEntries.size() ) );
235}
236
237
238static wxString formatCount( int aCount )
239{
240 return wxString::Format( wxT( "%i" ), aCount );
241};
242
243
245{
246 int totalPads = 0;
247 int row = 0;
248
249 for( const BOARD_STATISTICS_INFO_ENTRY<PAD_ATTRIB>& line : m_statsData.padEntries )
250 {
251 m_gridPads->SetCellValue( row, COL_LABEL, line.title );
252 m_gridPads->SetCellValue( row, COL_AMOUNT, formatCount( line.quantity ) );
253 totalPads += line.quantity;
254 row++;
255 }
256
257 m_gridPads->SetCellValue( row, COL_LABEL, _( "Total:" ) );
258 m_gridPads->SetCellValue( row, COL_AMOUNT, formatCount( totalPads ) );
259 row++;
260
261 for( const BOARD_STATISTICS_INFO_ENTRY<PAD_PROP>& line : m_statsData.padPropertyEntries )
262 {
263 m_gridPads->SetCellValue( row, COL_LABEL, line.title );
264 m_gridPads->SetCellValue( row, COL_AMOUNT, formatCount( line.quantity ) );
265 row++;
266 }
267
268 int totalVias = 0;
269 row = 0;
270
271 for( const BOARD_STATISTICS_INFO_ENTRY<VIATYPE>& line : m_statsData.viaEntries )
272 {
273 m_gridVias->SetCellValue( row, COL_LABEL, line.title );
274 m_gridVias->SetCellValue( row, COL_AMOUNT, formatCount( line.quantity ) );
275 totalVias += line.quantity;
276 row++;
277 }
278
279 m_gridVias->SetCellValue( row, COL_LABEL, _( "Total:" ) );
280 m_gridVias->SetCellValue( row, COL_AMOUNT, formatCount( totalVias ) );
281
282
283 int totalFront = 0;
284 int totalBack = 0;
285
286 // We don't use row 0, as there labels are
287 row = 1;
288
289 for( const BOARD_STATISTICS_FP_ENTRY& line : m_statsData.footprintEntries )
290 {
291 m_gridComponents->SetCellValue( row, COL_LABEL, line.title );
292 m_gridComponents->SetCellValue( row, COL_FRONT_SIDE, formatCount( line.frontCount ) );
293 m_gridComponents->SetCellValue( row, COL_BOTTOM_SIDE, formatCount( line.backCount ) );
294 m_gridComponents->SetCellValue( row, 3, formatCount( line.frontCount + line.backCount ) );
295 totalFront += line.frontCount;
296 totalBack += line.backCount;
297 row++;
298 }
299
300 m_gridComponents->SetCellValue( row, COL_LABEL, _( "Total:" ) );
301 m_gridComponents->SetCellValue( row, COL_FRONT_SIDE, formatCount( totalFront ) );
302 m_gridComponents->SetCellValue( row, COL_BOTTOM_SIDE, formatCount( totalBack ) );
303 m_gridComponents->SetCellValue( row, COL_TOTAL, formatCount( totalFront + totalBack ) );
304
305 if( m_statsData.hasOutline )
306 {
307 m_gridBoard->SetCellValue( ROW_BOARD_DIMS, COL_AMOUNT,
308 wxString::Format( wxT( "%s x %s" ),
309 m_frame->MessageTextFromValue( m_statsData.boardWidth, false ),
310 m_frame->MessageTextFromValue( m_statsData.boardHeight, true ) ) );
311 m_gridBoard->SetCellValue( ROW_BOARD_AREA, COL_AMOUNT,
312 m_frame->MessageTextFromValue( m_statsData.boardArea, true, EDA_DATA_TYPE::AREA ) );
313
315 wxString::Format( "%.2f %%", m_statsData.frontFootprintDensity ) );
316
318 wxString::Format( "%.2f %%", m_statsData.backFootprintDensity ) );
319 }
320 else
321 {
322 m_gridBoard->SetCellValue( ROW_BOARD_DIMS, COL_AMOUNT, _( "unknown" ) );
323 m_gridBoard->SetCellValue( ROW_BOARD_AREA, COL_AMOUNT, _( "unknown" ) );
324 }
325
326 m_gridBoard->SetCellValue(
328 m_frame->MessageTextFromValue( m_statsData.frontFootprintCourtyardArea, true, EDA_DATA_TYPE::AREA ) );
329
330 m_gridBoard->SetCellValue(
332 m_frame->MessageTextFromValue( m_statsData.backFootprintCourtyardArea, true, EDA_DATA_TYPE::AREA ) );
333
334 m_gridBoard->SetCellValue(
336 m_frame->MessageTextFromValue( m_statsData.frontCopperArea, true, EDA_DATA_TYPE::AREA ) );
338 m_frame->MessageTextFromValue( m_statsData.backCopperArea, true, EDA_DATA_TYPE::AREA ) );
339
340 m_gridBoard->SetCellValue(
342 m_frame->MessageTextFromValue( m_statsData.minClearanceTrackToTrack, true, EDA_DATA_TYPE::DISTANCE ) );
343
344 m_gridBoard->SetCellValue(
346 m_frame->MessageTextFromValue( m_statsData.minTrackWidth, true, EDA_DATA_TYPE::DISTANCE ) );
347
348 m_gridBoard->SetCellValue(
350 m_frame->MessageTextFromValue( m_statsData.boardThickness, true, EDA_DATA_TYPE::DISTANCE ) );
351
353
354 m_gridBoard->SetCellValue(
356 m_frame->MessageTextFromValue( m_statsData.minDrillSize, true, EDA_DATA_TYPE::DISTANCE ) );
357
358 m_gridComponents->AutoSize();
359 m_gridPads->AutoSize();
360 m_gridBoard->AutoSize();
361 m_gridVias->AutoSize();
362
364}
365
366
368{
369 BOARD* board = m_frame->GetBoard();
370 int row = 0;
371
372 for( const DRILL_LINE_ITEM& line : m_statsData.drillEntries )
373 {
374 wxString shapeStr;
375 wxString startLayerStr;
376 wxString stopLayerStr;
377
378 switch( line.shape )
379 {
380 case PAD_DRILL_SHAPE::CIRCLE: shapeStr = _( "Round" ); break;
381 case PAD_DRILL_SHAPE::OBLONG: shapeStr = _( "Slot" ); break;
382 default: shapeStr = _( "???" ); break;
383 }
384
385 if( line.startLayer == UNDEFINED_LAYER )
386 startLayerStr = _( "N/A" );
387 else
388 startLayerStr = board->GetLayerName( line.startLayer );
389
390 if( line.stopLayer == UNDEFINED_LAYER )
391 stopLayerStr = _( "N/A" );
392 else
393 stopLayerStr = board->GetLayerName( line.stopLayer );
394
395 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_COUNT, formatCount( line.m_Qty ) );
396 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_SHAPE, shapeStr );
397 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_X_SIZE, m_frame->MessageTextFromValue( line.xSize ) );
398 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_Y_SIZE, m_frame->MessageTextFromValue( line.ySize ) );
399 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_PLATED, line.isPlated ? _( "PTH" ) : _( "NPTH" ) );
400 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_VIA_PAD, line.isPad ? _( "Pad" ) : _( "Via" ) );
401 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_START_LAYER, startLayerStr );
402 m_gridDrills->SetCellValue( row, DRILL_LINE_ITEM::COL_STOP_LAYER, stopLayerStr );
403
404 row++;
405 }
406}
407
408
410{
411 wxGridUpdateLocker deferRepaintsTillLeavingScope( m_gridDrills );
412
413 m_gridDrills->EnsureColLabelsVisible();
414
415 double remainingWidth = KIPLATFORM::UI::GetUnobscuredSize( m_gridDrills ).x;
416
417 // Find the total current width
418 for( int i = 0; i < m_gridDrills->GetNumberCols(); i++ )
419 {
421 remainingWidth -= m_gridDrills->GetColSize( i );
422 }
423
424 double scalingFactor = std::max( 1.0,
426 int startLayerColWidth = static_cast<int>( m_startLayerColInitialSize * scalingFactor );
427 int stopLayerColWidth = static_cast<int>( m_stopLayerColInitialSize * scalingFactor );
428
429 m_gridDrills->SetColSize( DRILL_LINE_ITEM::COL_START_LAYER, startLayerColWidth );
430 m_gridDrills->SetColSize( DRILL_LINE_ITEM::COL_STOP_LAYER, stopLayerColWidth );
431}
432
433
434void DIALOG_BOARD_STATISTICS::checkboxClicked( wxCommandEvent& aEvent )
435{
436 s_savedDialogState.excludeNoPins = m_checkBoxExcludeComponentsNoPins->GetValue();
437 s_savedDialogState.subtractHoles = m_checkBoxSubtractHoles->GetValue();
438 s_savedDialogState.subtractHolesFromCopper = m_checkBoxSubtractHolesFromCopper->GetValue();
442 Layout();
443 m_drillsPanel->Layout();
444}
445
446
447void DIALOG_BOARD_STATISTICS::saveReportClicked( wxCommandEvent& aEvent )
448{
449 FILE* outFile;
450 wxString msg;
451 wxString boardName;
452
453 wxFileName fn = m_frame->GetBoard()->GetFileName();
454 boardName = fn.GetName();
455 wxFileDialog dlg( this, _( "Save Report File" ), s_savedDialogState.saveReportFolder,
457 wxFD_SAVE | wxFD_OVERWRITE_PROMPT );
458
460
461 if( dlg.ShowModal() == wxID_CANCEL )
462 return;
463
464 s_savedDialogState.saveReportFolder = wxPathOnly( dlg.GetPath() );
465 s_savedDialogState.saveReportName = dlg.GetFilename();
466
467 outFile = wxFopen( dlg.GetPath(), wxT( "wt" ) );
468
469 if( outFile == nullptr )
470 {
471 msg.Printf( _( "Failed to create file '%s'." ), dlg.GetPath() );
472 DisplayErrorMessage( this, msg );
473 return;
474 }
475
476 const UNITS_PROVIDER& unitsProvider = *m_frame;
477 wxString report = FormatBoardStatisticsReport( m_statsData, m_frame->GetBoard(), unitsProvider,
478 Prj().GetProjectName(), boardName );
479
480 if( fprintf( outFile, "%s", TO_UTF8( report ) ) < 0 )
481 {
482 msg.Printf( _( "Error writing file '%s'." ), dlg.GetPath() );
483 DisplayErrorMessage( this, msg );
484 }
485
486 fclose( outFile );
487}
488
489
490void DIALOG_BOARD_STATISTICS::drillGridSize( wxSizeEvent& aEvent )
491{
492 aEvent.Skip();
494}
495
496void DIALOG_BOARD_STATISTICS::drillGridSort( wxGridEvent& aEvent )
497{
498 DRILL_LINE_ITEM::COL_ID colId = static_cast<DRILL_LINE_ITEM::COL_ID>( aEvent.GetCol() );
499 bool ascending = !( m_gridDrills->IsSortingBy( colId )
500 && m_gridDrills->IsSortOrderAscending() );
501
502 sort( m_statsData.drillEntries.begin(), m_statsData.drillEntries.end(),
503 DRILL_LINE_ITEM::COMPARE( colId, ascending ) );
504
506}
507
508
void ComputeBoardStatistics(BOARD *aBoard, const BOARD_STATISTICS_OPTIONS &aOptions, BOARD_STATISTICS_DATA &aData)
static wxString formatCount(int aCount)
wxString FormatBoardStatisticsReport(const BOARD_STATISTICS_DATA &aData, BOARD *aBoard, const UNITS_PROVIDER &aUnitsProvider, const wxString &aProjectName, const wxString &aBoardName)
void InitializeBoardStatisticsData(BOARD_STATISTICS_DATA &aData)
Information pertinent to a Pcbnew printed circuit board.
Definition board.h:372
const wxString GetLayerName(PCB_LAYER_ID aLayer) const
Return the name of a aLayer.
Definition board.cpp:793
DIALOG_BOARD_STATISTICS_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Board Statistics"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
void checkboxClicked(wxCommandEvent &aEvent) override
Save board statistics to a file.
int m_startLayerColInitialSize
Width of the start layer column as calculated by the wxWidgets autosizing algorithm.
void updateWidgets()
Update drills grid.
void saveReportClicked(wxCommandEvent &aEvent) override
~DIALOG_BOARD_STATISTICS()
Get data from the PCB board and print it to dialog.
int m_stopLayerColInitialSize
Width of the stop layer column.
DIALOG_BOARD_STATISTICS(PCB_EDIT_FRAME *aParentFrame)
void drillGridSort(wxGridEvent &aEvent)
void refreshItemsTypes()
< Function to fill up all items types to be shown in the dialog.
void drillGridSize(wxSizeEvent &aEvent) override
BOARD_STATISTICS_DATA m_statsData
void getDataFromPCB()
Apply data to dialog widgets.
void finishDialogSettings()
In all dialogs, we must call the same functions to fix minimal dlg size, the default position and per...
PROJECT & Prj() const
Return a reference to the PROJECT associated with this KIWAY.
The main frame for Pcbnew.
virtual const wxString GetProjectFullName() const
Return the full path and name of the project.
Definition project.cpp:177
void DisplayErrorMessage(wxWindow *aParent, const wxString &aText, const wxString &aExtraInfo)
Display an error message with aMessage.
Definition confirm.cpp:217
This file is part of the common library.
static DIALOG_BOARD_STATISTICS_SAVED_STATE s_savedDialogState
#define ROW_FOOTPRINT_COURTYARD_FRONT_AREA
#define ROW_BOARD_AREA
#define ROW_BOARD_THICKNESS
#define COL_AMOUNT
#define ROW_FRONT_COMPONENT_DENSITY
#define ROW_LABEL
#define ROW_BACK_COMPONENT_DENSITY
#define COL_BOTTOM_SIDE
#define ROW_BACK_COPPER_AREA
#define ROW_MIN_TRACK_WIDTH
#define COL_LABEL
#define COL_TOTAL
#define ROW_MIN_DRILL_DIAMETER
#define ROW_FRONT_COPPER_AREA
#define ROW_BOARD_DIMS
static wxString formatCount(int aCount)
#define COL_FRONT_SIDE
#define ROW_MIN_CLEARANCE
#define ROW_FOOTPRINT_COURTYARD_BACK_AREA
#define _(s)
static wxString TextFileWildcard()
@ UNDEFINED_LAYER
Definition layer_ids.h:57
This file contains miscellaneous commonly used macros and functions.
wxSize GetUnobscuredSize(const wxWindow *aWindow)
Tries to determine the size of the viewport of a scrollable widget (wxDataViewCtrl,...
Definition wxgtk/ui.cpp:294
void AllowNetworkFileSystems(wxDialog *aDialog)
Configure a file dialog to show network and virtual file systems.
Definition wxgtk/ui.cpp:448
KICOMMON_API wxFont GetStatusFont(wxWindow *aWindow)
KICOMMON_API wxFont GetSmallInfoFont(wxWindow *aWindow)
#define TO_UTF8(wxstring)
Convert a wxString to a UTF8 encoded C string for all wxWidgets build modes.
int quantity
wxString title
PCB_LAYER_ID stopLayer
PAD_DRILL_SHAPE shape
PCB_LAYER_ID startLayer
Functions to provide common constants and other functions to assist in making a consistent UI.
Definition of file extensions used in Kicad.