KiCad PCB EDA Suite
pcb_edit_frame.h
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) 2010 Jean-Pierre Charras, jp.charras@wanadoo.fr
5  * Copyright (C) 1992-2019 KiCad Developers, see AUTHORS.txt for contributors.
6  *
7  * This program is free software: you can redistribute it and/or modify it
8  * under the terms of the GNU General Public License as published by the
9  * Free Software Foundation, either version 3 of the License, or (at your
10  * option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful, but
13  * WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
15  * General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License along
18  * with this program. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
21 #ifndef WXPCB_STRUCT_H_
22 #define WXPCB_STRUCT_H_
23 
24 #include <unordered_map>
25 #include <map>
26 #include "pcb_base_edit_frame.h"
27 #include "undo_redo_container.h"
28 #include "zones.h"
29 
30 /* Forward declarations of classes. */
31 class ACTION_PLUGIN;
32 class PCB_SCREEN;
33 class BOARD;
34 class BOARD_COMMIT;
36 class TEXTE_PCB;
37 class MODULE;
38 class TRACK;
39 class VIA;
40 class D_PAD;
41 class TEXTE_MODULE;
42 class PCB_TARGET;
43 class DIMENSION;
44 class EDGE_MODULE;
45 class DRC;
46 class DIALOG_PLOT;
47 class ZONE_CONTAINER;
48 class DRAWSEGMENT;
49 class GENERAL_COLLECTOR;
51 class PCB_LAYER_WIDGET;
52 class MARKER_PCB;
53 class BOARD_ITEM;
55 class NETLIST;
56 class REPORTER;
57 struct PARSE_ERROR;
58 class IO_ERROR;
59 class FP_LIB_TABLE;
61 class ACTION_MENU;
62 enum LAST_PATH_TYPE : unsigned int;
63 
64 namespace PCB { struct IFACE; } // KIFACE_I is in pcbnew.cpp
65 
70 {
74 };
75 
85 {
86  friend struct PCB::IFACE;
87  friend class PCB_LAYER_WIDGET;
88 
91 
92 protected:
93 
98  {
105 
108  previous_active_layer_color( COLOR4D::UNSPECIFIED ),
109  previous_Route_Layer_TOP_color( COLOR4D::UNSPECIFIED ),
111  previous_via_color( COLOR4D::UNSPECIFIED ),
112  previous_background_color( COLOR4D::UNSPECIFIED )
113  {
114  }
115  };
116 
118 
119  // The Tool Framework initalization
120  void setupTools();
121 
126  void SwitchCanvas( EDA_DRAW_PANEL_GAL::GAL_TYPE aCanvasType ) override;
127 
128 #if defined(KICAD_SCRIPTING) && defined(KICAD_SCRIPTING_ACTION_MENU)
129 
133  void buildActionPluginMenus( ACTION_MENU* aActionMenu );
134 
139  void AddActionPluginTools();
140 
146  void RunActionPlugin( ACTION_PLUGIN* aActionPlugin );
147 
153  void OnActionPluginMenu( wxCommandEvent& aEvent);
154 
160  void OnActionPluginButton( wxCommandEvent& aEvent );
161 
167  void OnActionPluginRefresh( wxCommandEvent& aEvent)
168  {
170  }
171 #endif
172 
177  static const wxChar * pythonConsoleNameId()
178  {
179  return wxT( "PythonConsole" );
180  }
181 
185  static wxWindow * findPythonConsole()
186  {
187  return FindWindowByName( pythonConsoleNameId() );
188  }
189 
193  void onBoardLoaded();
194 
204  void syncLayerWidgetLayer();
205 
212  void syncLayerVisibilities();
213 
221  bool doAutoSave() override;
222 
227  bool isAutoSaveRequired() const override;
228 
234  bool importFile( const wxString& aFileName, int aFileType );
235 
239  int inferLegacyEdgeClearance( BOARD* aBoard );
240 
244  bool fixEagleNets( const std::unordered_map<wxString, wxString>& aRemap );
245 
246  // protected so that PCB::IFACE::CreateWindow() is the only factory.
247  PCB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent );
248 
249 public:
250  PCB_LAYER_BOX_SELECTOR* m_SelLayerBox; // a combo box to display and select active layer
251  wxChoice* m_SelTrackWidthBox; // a choice box to display and select current track width
252  wxChoice* m_SelViaSizeBox; // a choice box to display and select current via diameter
253 
256 
257  bool m_ZoneFillsDirty; // Board has been modified since last zone fill.
258 
259  virtual ~PCB_EDIT_FRAME();
260 
270  void LoadFootprints( NETLIST& aNetlist, REPORTER& aReporter );
271 
272  void OnQuit( wxCommandEvent& event );
273 
279  bool IsContentModified() override;
280 
286  void PythonPluginsReload();
287 
292  void UpdateUserInterface();
293 
300  void ExecuteRemoteCommand( const char* cmdline ) override;
301 
302  void KiwayMailIn( KIWAY_EXPRESS& aEvent ) override;
303 
308  void ToPlotter( int aID );
309 
314  void ExportSVG( wxCommandEvent& event );
315 
316  // User interface update command event handlers.
317  void OnUpdateLayerSelectBox( wxUpdateUIEvent& aEvent );
318  bool LayerManagerShown();
319  bool MicrowaveToolbarShown();
320  void OnUpdateSelectViaSize( wxUpdateUIEvent& aEvent );
321  void OnUpdateSelectTrackWidth( wxUpdateUIEvent& aEvent );
322  void OnLayerColorChange( wxCommandEvent& aEvent );
323 
324  void RunEeschema();
325 
326  void UpdateTrackWidthSelectBox( wxChoice* aTrackWidthSelectBox, bool aEdit = true );
327  void UpdateViaSizeSelectBox( wxChoice* aViaSizeSelectBox, bool aEdit = true );
328 
333  COLOR4D GetGridColor() override;
334 
339  void SetGridColor( COLOR4D aColor ) override;
340 
341  // Configurations:
342  void Process_Config( wxCommandEvent& event );
343 
344 #if defined(KICAD_SCRIPTING) && defined(KICAD_SCRIPTING_ACTION_MENU)
345 
351  bool GetActionPluginButtonVisible( const wxString& aPluginPath, bool aPluginDefault );
352 
357  std::vector<ACTION_PLUGIN*> GetOrderedActionPlugins();
358 
359 #endif
360 
365  void SaveProjectSettings() override;
366 
373  bool LoadProjectSettings();
374 
375  void LoadSettings( APP_SETTINGS_BASE* aCfg ) override;
376 
377  void SaveSettings( APP_SETTINGS_BASE* aCfg ) override;
378 
383  wxString GetLastPath( LAST_PATH_TYPE aType );
384 
396  void SetLastPath( LAST_PATH_TYPE aType, const wxString& aLastPath );
397 
401  void RecordDRCExclusions();
402 
406  void ResolveDRCExclusions();
407 
408  void OnCloseWindow( wxCloseEvent& Event ) override;
409  void Process_Special_Functions( wxCommandEvent& event );
410  void Tracks_and_Vias_Size_Event( wxCommandEvent& event );
411 
412  void ReCreateHToolbar() override;
413  void ReCreateAuxiliaryToolbar() override;
414  void ReCreateVToolbar() override;
416  void ReCreateOptToolbar() override;
417  void ReCreateMenuBar() override;
418 
426  void ReCreateLayerBox( bool aForceResizeToolbar = true );
427 
428 
439  bool SetCurrentNetClass( const wxString& aNetClassName );
440 
449  void OnModify() override;
450 
456  void SetActiveLayer( PCB_LAYER_ID aLayer ) override;
457 
459 
463  void OnUpdateLayerAlpha( wxUpdateUIEvent& aEvent ) override;
464 
473  bool IsElementVisible( GAL_LAYER_ID aElement ) const;
474 
482  void SetElementVisibility( GAL_LAYER_ID aElement, bool aNewState );
483 
488  void SetVisibleAlls();
489 
495  void ReFillLayerWidget();
496 
502  void SyncRenderStates();
503 
505  void ActivateGalCanvas() override;
506 
510  void ShowBoardSetupDialog( const wxString& aInitialPage = wxEmptyString,
511  const wxString& aErrorMsg = wxEmptyString, int aErrorCtrlId = -1,
512  int aErrorLine = -1, int aErrorCol = -1 );
513 
514  /* toolbars update UI functions: */
515 
516  void PrepareLayerIndicator( bool aForceRebuild = false );
517 
518  void ToggleLayersManager();
519  void ToggleMicrowaveToolbar();
520 
535  int DoGenFootprintsPositionFile( const wxString& aFullFileName, bool aUnitsMM,
536  bool aForceSmdItems, bool aTopSide, bool aBottomSide, bool aFormatCSV = false );
537 
543  void GenFootprintsReport( wxCommandEvent& event );
544 
553  bool DoGenFootprintsReport( const wxString& aFullFilename, bool aUnitsMM );
554 
555  void GenD356File( wxCommandEvent& event );
556 
557  void OnFileHistory( wxCommandEvent& event );
558  void OnClearFileHistory( wxCommandEvent& aEvent );
559 
566  void Files_io( wxCommandEvent& event );
567 
580  bool Files_io_from_id( int aId );
581 
596  bool OpenProjectFiles( const std::vector<wxString>& aFileSet, int aCtl = 0 ) override;
597 
609  bool SavePcbFile( const wxString& aFileName, bool addToHistory = true,
610  bool aChangeProject = true );
611 
623  bool SavePcbCopy( const wxString& aFileName );
624 
625  // BOARD handling
626 
633  bool Clear_Pcb( bool aQuery, bool aFinal = false );
634 
636  void SetBoard( BOARD* aBoard ) override;
637 
639  BOARD_ITEM_CONTAINER* GetModel() const override;
640 
642  void SetPageSettings( const PAGE_INFO& aPageSettings ) override;
643 
650  void RecreateCmpFileFromBoard( wxCommandEvent& aEvent );
651 
666  void ArchiveModulesOnBoard( bool aStoreInNewLib, const wxString& aLibName = wxEmptyString,
667  wxString* aLibPath = NULL );
668 
673  void RecreateBOMFileFromBoard( wxCommandEvent& aEvent );
674 
679  void ExportToGenCAD( wxCommandEvent& event );
680 
685  void OnExportVRML( wxCommandEvent& event );
686 
716  bool ExportVRML_File( const wxString & aFullFileName, double aMMtoWRMLunit,
717  bool aExport3DFiles, bool aUseRelativePaths, bool aUsePlainPCB,
718  const wxString & a3D_Subdir, double aXRef, double aYRef );
719 
724  void OnExportIDF3( wxCommandEvent& event );
725 
730  void OnExportHyperlynx( wxCommandEvent& event );
731 
743  bool Export_IDF3( BOARD* aPcb, const wxString& aFullFileName,
744  bool aUseThou, double aXRef, double aYRef );
745 
750  void OnExportSTEP( wxCommandEvent& event );
751 
759  bool ExportSpecctraFile( const wxString& aFullFilename );
760 
768  bool ImportSpecctraSession( const wxString& aFullFilename );
769 
770  // Footprint editing (see also PCB_BASE_FRAME)
772 
773  int InstallExchangeModuleFrame( MODULE* aModule, bool updateMode, bool selectedMode );
774 
784  void Exchange_Module( MODULE* aSrc, MODULE* aDest, BOARD_COMMIT& aCommit,
785  bool deleteExtraTexts = true,
786  bool resetTextLayers = true, bool resetTextEffects = true,
787  bool reset3DModels = true );
788 
789  // loading modules: see PCB_BASE_FRAME
790 
797  void OnEditItemRequest( BOARD_ITEM* aItem ) override;
798 
799  void SwitchLayer( wxDC* DC, PCB_LAYER_ID layer ) override;
800 
816  int SetTrackSegmentWidth( TRACK* aTrackItem,
817  PICKED_ITEMS_LIST* aItemsListPicker,
818  bool aUseNetclassValue );
819 
820 
825  void Edit_Zone_Params( ZONE_CONTAINER* zone_container );
826 
827  // Properties dialogs
828  void ShowTargetOptionsDialog( PCB_TARGET* aTarget );
829  void ShowDimensionPropertyDialog( DIMENSION* aDimension );
830  void InstallNetlistFrame();
831 
838  bool FetchNetlistFromSchematic( NETLIST& aNetlist, FETCH_NETLIST_MODE aMode );
839 
846  void DoUpdatePCBFromNetlist( NETLIST& aNetlist, bool aUseTimestamps );
847 
856  bool ReadNetlistFromFile( const wxString &aFilename, NETLIST& aNetlist, REPORTER& aReporter );
857 
863  void OnNetlistChanged( BOARD_NETLIST_UPDATER& aUpdater, bool* aRunDragCommand );
864 
865 
866 #if defined( KICAD_SCRIPTING_WXPYTHON )
867 
871  void ScriptingConsoleEnableDisable();
872 #endif
873 
874  void LockModule( MODULE* aModule, bool aLocked );
875 
882  void SendMessageToEESCHEMA( BOARD_ITEM* objectToSync );
883 
889  void SendCrossProbeNetName( const wxString& aNetName );
890 
891  void ShowChangedLanguage() override;
892 
903  void UpdateTitle();
904 
905  void On3DShapeLibWizard( wxCommandEvent& event );
906 
910  void InstallPreferences( PAGED_DIALOG* aParent, PANEL_HOTKEYS_EDITOR* aHotkeysPanel ) override;
911 
915  void CommonSettingsChanged( bool aEnvVarsChanged, bool aTextVarsChanged ) override;
916 
917  void SyncToolbars() override;
918 
919  wxString GetCurrentFileName() const override;
920 
921  DECLARE_EVENT_TABLE()
922 };
923 
924 #endif // WXPCB_STRUCT_H_
void UpdateTitle()
Function UpdateTitle sets the main window title bar text.
PCB_EDIT_FRAME(KIWAY *aKiway, wxWindow *aParent)
void OnModify() override
Function OnModify must be called after a board change to set the modified flag.
ZONE_CONTAINER handles a list of polygons defining a copper zone.
Definition: class_zone.h:61
ACTION_PLUGIN This is the parent class from where any action plugin class must derive.
Definition: action_plugin.h:40
void SetPageSettings(const PAGE_INFO &aPageSettings) override
void RecreateCmpFileFromBoard(wxCommandEvent &aEvent)
Function RecreateBOMFileFromBoard Recreates a .cmp file from the current loaded board this is the sam...
ACTION_TOOLBAR.
KIWAY_EXPRESS carries a payload from one KIWAY_PLAYER to another within a PROJECT.
Definition: kiway_express.h:39
void Edit_Zone_Params(ZONE_CONTAINER *zone_container)
Function Edit_Zone_Params Edit params (layer, clearance, ...) for a zone outline.
void SetElementVisibility(GAL_LAYER_ID aElement, bool aNewState)
Function SetElementVisibility changes the visibility of an element category.
void OnExportIDF3(wxCommandEvent &event)
Function OnExportIDF3 will export the current BOARD to a IDFv3 board and lib files.
void syncLayerWidgetLayer()
Function syncLayerWidgetLayer updates the currently layer "selection" within the PCB_LAYER_WIDGET.
void SendCrossProbeNetName(const wxString &aNetName)
Sends a net name to eeschema for highlighting.
void Process_Config(wxCommandEvent &event)
void OnExportHyperlynx(wxCommandEvent &event)
Function OnExportHyperlynx will export the current BOARD to a Hyperlynx HYP file.
bool importFile(const wxString &aFileName, int aFileType)
Load the given filename but sets the path to the current project path.
void OnEditItemRequest(BOARD_ITEM *aItem) override
Function OnEditItemRequest Install the corresponding dialog editor for the given item.
void LockModule(MODULE *aModule, bool aLocked)
ACTION_MENU.
Definition: action_menu.h:44
BOARD_ITEM is a base class for any item which can be embedded within the BOARD container class,...
void ToPlotter(int aID)
Function ToPlotter Open a dialog frame to create plot and drill files relative to the current board.
BOARD_NETLIST_UPDATER updates the BOARD with a new netlist.
PCB_LAYER_WIDGET is here to implement the abstract functions of LAYER_WIDGET so they may be tied into...
bool SavePcbCopy(const wxString &aFileName)
Function SavePcbCopy writes the board data structures to a aFileName but unlike SavePcbFile,...
void LoadFootprints(NETLIST &aNetlist, REPORTER &aReporter)
Function loadFootprints loads the footprints for each COMPONENT in aNetlist from the list of librarie...
bool doAutoSave() override
Function doAutoSave performs auto save when the board has been modified and not saved within the auto...
void ActivateGalCanvas() override
void OnUpdateLayerSelectBox(wxUpdateUIEvent &aEvent)
void OnExportSTEP(wxCommandEvent &event)
Function OnExportSTEP Exports the current BOARD to a STEP assembly.
bool ReadNetlistFromFile(const wxString &aFilename, NETLIST &aNetlist, REPORTER &aReporter)
Reads a netlist from a file into a NETLIST object.
void ResolveDRCExclusions()
Update markers to match recorded exclusions.
wxChoice * m_SelViaSizeBox
void OnLayerColorChange(wxCommandEvent &aEvent)
void RecreateBOMFileFromBoard(wxCommandEvent &aEvent)
Function RecreateBOMFileFromBoard Creates a BOM file from the current loaded board.
bool Export_IDF3(BOARD *aPcb, const wxString &aFullFileName, bool aUseThou, double aXRef, double aYRef)
Function Export_IDF3 Creates an IDF3 compliant BOARD (*.emn) and LIBRARY (*.emp) file.
GAL_LAYER_ID
GAL layers are "virtual" layers, i.e.
bool LoadProjectSettings()
Load the current project's file configuration settings which are pertinent to this PCB_EDIT_FRAME ins...
void ReCreateLayerBox(bool aForceResizeToolbar=true)
Re create the layer Box by clearing the old list, and building le new one, from the new layers names ...
int SetTrackSegmentWidth(TRACK *aTrackItem, PICKED_ITEMS_LIST *aItemsListPicker, bool aUseNetclassValue)
Function SetTrackSegmentWidth Modify one track segment width or one via diameter (using DRC control).
void ExportToGenCAD(wxCommandEvent &event)
Function ExportToGenCAD creates a file in GenCAD 1.4 format from the current board.
void SetGridColor(COLOR4D aColor) override
Function SetGridColor() , virtual.
void ShowTargetOptionsDialog(PCB_TARGET *aTarget)
Class to display a pcb layer list in a wxBitmapComboBox.
bool m_show_microwave_tools
int inferLegacyEdgeClearance(BOARD *aBoard)
Use the existing edge_cut line thicknesses to infer the edge clearace.
void ReCreateHToolbar() override
void syncLayerVisibilities()
Function syncLayerVisibilities updates each "Layer" checkbox in the layer widget according to each la...
void Exchange_Module(MODULE *aSrc, MODULE *aDest, BOARD_COMMIT &aCommit, bool deleteExtraTexts=true, bool resetTextLayers=true, bool resetTextEffects=true, bool reset3DModels=true)
Function Exchange_Module Replaces OldModule by NewModule, using OldModule settings: position,...
REPORTER is a pure virtual class used to derive REPORTER objects from.
Definition: reporter.h:64
void RecordDRCExclusions()
Scan existing markers and record data from any that are Excluded.
void OnCloseWindow(wxCloseEvent &Event) override
void OnNetlistChanged(BOARD_NETLIST_UPDATER &aUpdater, bool *aRunDragCommand)
Called after netlist is updated.
bool SetCurrentNetClass(const wxString &aNetClassName)
Function SetCurrentNetClass Must be called after a netclass selection (or after a netclass parameter ...
wxChoice * m_SelTrackWidthBox
TRACK_ACTION_DRC_ERROR - Track not changed to to DRC.
static wxWindow * findPythonConsole()
void SetVisibleAlls()
Function SetVisibleAlls Set the status of all visible element categories and layers to VISIBLE.
bool fixEagleNets(const std::unordered_map< wxString, wxString > &aRemap)
Rematch orphaned zones and vias to schematic nets.
wxString GetLastPath(LAST_PATH_TYPE aType)
Get the last path for a particular type.
int InstallExchangeModuleFrame(MODULE *aModule, bool updateMode, bool selectedMode)
void CommonSettingsChanged(bool aEnvVarsChanged, bool aTextVarsChanged) override
Called after the preferences dialog is run.
void LoadSettings(APP_SETTINGS_BASE *aCfg) override
Load common frame parameters from a configuration file.
bool isAutoSaveRequired() const override
Function isautoSaveRequired returns true if the board has been modified.
Store the previous layer toolbar icon state information.
bool m_show_layer_manager_tools
void UpdateTrackWidthSelectBox(wxChoice *aTrackWidthSelectBox, bool aEdit=true)
void OnClearFileHistory(wxCommandEvent &aEvent)
void KiwayMailIn(KIWAY_EXPRESS &aEvent) override
Function KiwayMailIn receives KIWAY_EXPRESS messages from other players.
bool DoGenFootprintsReport(const wxString &aFullFilename, bool aUnitsMM)
Function DoGenFootprintsReport Creates an ascii footprint report file giving some infos on footprints...
void GenFootprintsReport(wxCommandEvent &event)
Function GenFootprintsReport Calls DoGenFootprintsReport to create a footprint reprot file See DoGenF...
PCB_LAYER_ID
A quick note on layer IDs:
void Tracks_and_Vias_Size_Event(wxCommandEvent &event)
APP_SETTINGS_BASE is a settings class that should be derived for each standalone KiCad application.
Definition: app_settings.h:92
NETLIST stores all of information read from a netlist along with the flags used to update the NETLIST...
Definition: pcb_netlist.h:186
#define NULL
bool IsContentModified() override
Get if the current board has been modified but not saved.
BOARD_ITEM_CONTAINER * GetModel() const override
bool OpenProjectFiles(const std::vector< wxString > &aFileSet, int aCtl=0) override
Function OpenProjectFiles (was LoadOnePcbFile) loads a KiCad board (.kicad_pcb) from aFileName.
void ExecuteRemoteCommand(const char *cmdline) override
Execute a remote command send by Eeschema via a socket, port KICAD_PCB_PORT_SERVICE_NUMBER (currently...
void onBoardLoaded()
Updates the state of the GUI after a new board is loaded or created.
PAGE_INFO describes the page size and margins of a paper page on which to eventually print or plot.
Definition: page_info.h:54
void SaveProjectSettings() override
Function SaveProjectSettings saves changes to the project settings to the project (....
void ExportSVG(wxCommandEvent &event)
Function SVG_Print Shows the Export to SVG file dialog.
void SyncRenderStates()
Updates the "Render" colors and checkboxes in the layer widget according to current toggle values det...
void ReCreateVToolbar() override
void ReCreateMenuBar() override
Recreates the menu bar.
PCB_LAYER_WIDGET * m_Layers
Layer manager. It is the responsibility of the child frames to instantiate this.
virtual ~PCB_EDIT_FRAME()
void ShowChangedLanguage() override
Redraw the menus and what not in current language.
COLOR4D GetGridColor() override
Function GetGridColor() , virtual.
KIWAY is a minimalistic software bus for communications between various DLLs/DSOs (DSOs) within the s...
Definition: kiway.h:273
ACTION_TOOLBAR * m_microWaveToolBar
The auxiliary right vertical tool bar used to access the microwave tools.
PCB_LAYER_WIDGET * GetLayerManager()
void OnQuit(wxCommandEvent &event)
void UpdateUserInterface()
Update the layer manager and other widgets from the board setup (layer and items visibility,...
PICKED_ITEMS_LIST is a holder to handle information on schematic or board items.
LAST_PATH_TYPE
For storing PcbNew MRU paths of various types.
Definition: project_file.h:44
void SyncToolbars() override
Update the toolbars (mostly settings/check buttons/checkboxes) with the current controller state.
static const wxChar * pythonConsoleNameId()
Has meaning only if KICAD_SCRIPTING_WXPYTHON option is not defined.
DIALOG_PLOT is the dialog to set the plot options, and create plot files in various formats.
Definition: dialog_plot.h:40
void PrepareLayerIndicator(bool aForceRebuild=false)
TRACK_ACTION_SUCCESS - Track changed successfully.
void SendMessageToEESCHEMA(BOARD_ITEM *objectToSync)
Function SendMessageToEESCHEMA sends a message to the schematic editor so that it may move its cursor...
void OnFileHistory(wxCommandEvent &event)
bool ImportSpecctraSession(const wxString &aFullFilename)
Function ImportSpecctraSession will import a specctra *.ses file and use it to relocate MODULEs and t...
Struct PARSE_ERROR contains a filename or source description, a problem input line,...
Definition: ki_exception.h:123
void SaveSettings(APP_SETTINGS_BASE *aCfg) override
Saves common frame parameters to a configuration data file.
bool SavePcbFile(const wxString &aFileName, bool addToHistory=true, bool aChangeProject=true)
Function SavePcbFile writes the board data structures to a aFileName Creates backup when requested an...
void OnUpdateLayerAlpha(wxUpdateUIEvent &aEvent) override
Update the UI to reflect changes to the current layer's transparency.
void SetBoard(BOARD *aBoard) override
void InstallPreferences(PAGED_DIALOG *aParent, PANEL_HOTKEYS_EDITOR *aHotkeysPanel) override
Allows Pcbnew to install its preferences panel into the preferences dialog.
bool ExportVRML_File(const wxString &aFullFileName, double aMMtoWRMLunit, bool aExport3DFiles, bool aUseRelativePaths, bool aUsePlainPCB, const wxString &a3D_Subdir, double aXRef, double aYRef)
Function ExportVRML_File Creates the file(s) exporting current BOARD to a VRML file.
Common, abstract interface for edit frames.
void Process_Special_Functions(wxCommandEvent &event)
Definition: pcbnew/edit.cpp:50
void DoUpdatePCBFromNetlist(NETLIST &aNetlist, bool aUseTimestamps)
Function DoUpdatePCBFromNetlist An automated version of UpdatePCBFromNetlist which skips the UI dialo...
void ArchiveModulesOnBoard(bool aStoreInNewLib, const wxString &aLibName=wxEmptyString, wxString *aLibPath=NULL)
Function ArchiveModulesOnBoard Save modules in a library:
void GenD356File(wxCommandEvent &event)
BOARD holds information pertinent to a Pcbnew printed circuit board.
Definition: class_board.h:180
void Files_io(wxCommandEvent &event)
Function Files_io.
LAYER_TOOLBAR_ICON_VALUES m_prevIconVal
Design Rule Checker object that performs all the DRC tests.
Used when the right click button is pressed, or when the select tool is in effect.
Definition: collectors.h:240
void OnExportVRML(wxCommandEvent &event)
Function OnExportVRML will export the current BOARD to a VRML file.
void OnUpdateSelectViaSize(wxUpdateUIEvent &aEvent)
FETCH_NETLIST_MODE
Function FetchNetlistFromSchematic.
void ReCreateOptToolbar() override
PCB_EDIT_FRAME is the main frame for Pcbnew.
bool Files_io_from_id(int aId)
Function Files_io_from_id Read and write board files.
void On3DShapeLibWizard(wxCommandEvent &event)
void OnUpdateSelectTrackWidth(wxUpdateUIEvent &aEvent)
void UpdateViaSizeSelectBox(wxChoice *aViaSizeSelectBox, bool aEdit=true)
Abstract interface for BOARD_ITEMs capable of storing other items inside.
int DoGenFootprintsPositionFile(const wxString &aFullFileName, bool aUnitsMM, bool aForceSmdItems, bool aTopSide, bool aBottomSide, bool aFormatCSV=false)
Function DoGenFootprintsPositionFile Creates an ascii footprint position file.
PCB_LAYER_BOX_SELECTOR * m_SelLayerBox
bool IsElementVisible(GAL_LAYER_ID aElement) const
Function IsElementVisible tests whether a given element category is visible.
void ReFillLayerWidget()
Function ReFillLayerWidget changes out all the layers in m_Layers and may be called upon loading a ne...
A general implementation of a COLLECTORS_GUIDE.
Definition: collectors.h:385
void ShowDimensionPropertyDialog(DIMENSION *aDimension)
void SwitchCanvas(EDA_DRAW_PANEL_GAL::GAL_TYPE aCanvasType) override
switches currently used canvas (Cairo / OpenGL).
void SwitchLayer(wxDC *DC, PCB_LAYER_ID layer) override
Definition: pcbnew/edit.cpp:82
wxString GetCurrentFileName() const override
Get the full filename + path of the currently opened file in the frame.
void PythonPluginsReload()
Reload the Python plugins if they are newer than the already loaded, and load new plugins if any Do n...
bool Clear_Pcb(bool aQuery, bool aFinal=false)
Function Clear_Pcb delete all and reinitialize the current board.
Definition: initpcb.cpp:42
Struct IO_ERROR is a class used to hold an error message and may be used when throwing exceptions con...
Definition: ki_exception.h:76
void SetActiveLayer(PCB_LAYER_ID aLayer) override
Function SetActiveLayer will change the currently active layer to aLayer and also update the PCB_LAYE...
void ShowBoardSetupDialog(const wxString &aInitialPage=wxEmptyString, const wxString &aErrorMsg=wxEmptyString, int aErrorCtrlId=-1, int aErrorLine=-1, int aErrorCol=-1)
Function ShowBoardSetupDialog.
void InstallFootprintPropertiesDialog(MODULE *Module)
bool FetchNetlistFromSchematic(NETLIST &aNetlist, FETCH_NETLIST_MODE aMode)
void ReCreateAuxiliaryToolbar() override
DIMENSION.
TRACK_ACTION_NONE - Nothing to change.
TRACK_ACTION_RESULT
Enum to signify the result of editing tracks and vias.
void SetLastPath(LAST_PATH_TYPE aType, const wxString &aLastPath)
Set the path of the last file successfully read.
bool ExportSpecctraFile(const wxString &aFullFilename)
Function ExportSpecctraFile will export the current BOARD to a specctra dsn file.
COLOR4D is the color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:99