KiCad PCB EDA Suite
SIM_PLOT_FRAME_BASE Class Referenceabstract

Class SIM_PLOT_FRAME_BASE. More...

#include <sim_plot_frame_base.h>

Inheritance diagram for SIM_PLOT_FRAME_BASE:
KIWAY_PLAYER EDA_BASE_FRAME TOOLS_HOLDER KIWAY_HOLDER SIM_PLOT_FRAME

Public Types

enum  UNDO_REDO_LIST { UNDO_LIST, REDO_LIST }
 Function ClearUndoORRedoList (virtual). More...
 
enum  HOLDER_TYPE { DIALOG, FRAME, PANEL }
 

Public Member Functions

 SIM_PLOT_FRAME_BASE (wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Spice Simulator"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(564, 531), long style=wxDEFAULT_FRAME_STYLE|wxTAB_TRAVERSAL, const wxString &name=wxT("SIM_PLOT_FRAME"))
 
 ~SIM_PLOT_FRAME_BASE ()
 
void m_splitterLeftRightOnIdle (wxIdleEvent &)
 
void m_splitterPlotAndConsoleOnIdle (wxIdleEvent &)
 
void m_splitterSignalsOnIdle (wxIdleEvent &)
 
void m_splitterTuneValuesOnIdle (wxIdleEvent &)
 
virtual bool OpenProjectFiles (const std::vector< wxString > &aFileList, int aCtl=0)
 Function OpenProjectFiles is abstract, and opens a project or set of files given by aFileList. More...
 
virtual void ParseArgs (wxCmdLineParser &aParser)
 Handles command-line arguments in a frame-specific way. More...
 
virtual bool ShowModal (wxString *aResult=NULL, wxWindow *aResultantFocusWindow=NULL)
 Function ShowModal puts up this wxFrame as if it were a modal dialog, with all other instantiated wxFrames disabled until this KIWAY_PLAYER derivative calls DismissModal(). More...
 
virtual void KiwayMailIn (KIWAY_EXPRESS &aEvent)
 Function KiwayMailIn receives KIWAY_EXPRESS messages from other players. More...
 
bool Destroy () override
 Our version of Destroy() which is virtual from wxWidgets. More...
 
bool IsModal () const
 
void SetModal (bool aIsModal)
 
bool IsDismissed ()
 Function IsDismissed returns false only if both the frame is acting in modal mode and it has not been dismissed yet with DismissModal(). More...
 
void DismissModal (bool aRetVal, const wxString &aResult=wxEmptyString)
 
EDA_UNITS GetUserUnits () const
 Return the user units currently in use. More...
 
void SetUserUnits (EDA_UNITS aUnits)
 
void ChangeUserUnits (EDA_UNITS aUnits)
 
virtual void ToggleUserUnits ()
 
SETTINGS_MANAGERGetSettingsManager () const
 
virtual int GetSeverity (int aErrorCode) const
 
bool ProcessEvent (wxEvent &aEvent) override
 Override the default process event handler to implement the auto save feature. More...
 
virtual void OnCharHook (wxKeyEvent &event)
 Capture the key event before it is sent to the GUI. More...
 
void OnMenuEvent (wxMenuEvent &event)
 The TOOL_DISPATCHER needs these to work around some issues in wxWidgets where the menu events aren't captured by the menus themselves. More...
 
virtual void OnMove (wxMoveEvent &aEvent)
 
void OnMaximize (wxMaximizeEvent &aEvent)
 
void SetAutoSaveInterval (int aInterval)
 
int GetAutoSaveInterval () const
 
bool IsType (FRAME_T aType) const
 
virtual const SEARCH_STACKsys_search ()
 Return a SEARCH_STACK pertaining to entire program. More...
 
virtual wxString help_name ()
 
void OnKicadAbout (wxCommandEvent &event)
 
void OnPreferences (wxCommandEvent &event)
 
void PrintMsg (const wxString &text)
 
WX_INFOBARGetInfoBar ()
 
virtual APP_SETTINGS_BASEconfig () const
 Returns the settings object used in SaveSettings(), and is overloaded in KICAD_MANAGER_FRAME. More...
 
virtual void InstallPreferences (PAGED_DIALOG *, PANEL_HOTKEYS_EDITOR *)
 Function InstallPreferences Allow a frame to load its preference panels (if any) into the preferences dialog. More...
 
void LoadWindowSettings (WINDOW_SETTINGS *aCfg)
 Loads window settings from the given settings object Normally called by LoadSettings unless the window in question is a child window that stores its settings somewhere other than APP_SETTINGS_BASE::m_Window. More...
 
void SaveWindowSettings (WINDOW_SETTINGS *aCfg)
 Saves window settings to the given settings object Normally called by SaveSettings unless the window in question is a child window that stores its settings somewhere other than APP_SETTINGS_BASE::m_Window. More...
 
virtual void LoadSettings (APP_SETTINGS_BASE *aCfg)
 Load common frame parameters from a configuration file. More...
 
virtual void SaveSettings (APP_SETTINGS_BASE *aCfg)
 Saves common frame parameters to a configuration data file. More...
 
virtual WINDOW_SETTINGSGetWindowSettings (APP_SETTINGS_BASE *aCfg)
 Returns a pointer to the window settings for this frame. More...
 
wxString ConfigBaseName () override
 
virtual void SaveProjectSettings ()
 Save changes to the project settings to the project (.pro) file. More...
 
void ImportHotkeyConfigFromFile (std::map< std::string, TOOL_ACTION * > aActionMap, const wxString &aDefaultShortname)
 Prompt the user for a hotkey file to read, and read it. More...
 
wxString GetFileFromHistory (int cmdId, const wxString &type, FILE_HISTORY *aFileHistory=nullptr)
 Fetches the file name from the file history list. More...
 
void ClearFileHistory (FILE_HISTORY *aFileHistory=nullptr)
 Removes all files from the file history. More...
 
void UpdateFileHistory (const wxString &FullFileName, FILE_HISTORY *aFileHistory=nullptr)
 Update the list of recently opened files. More...
 
FILE_HISTORYGetFileHistory ()
 Get the frame's main file history. More...
 
void SetMruPath (const wxString &aPath)
 
wxString GetMruPath () const
 
virtual wxString GetCurrentFileName () const
 Get the full filename + path of the currently opened file in the frame. More...
 
virtual void ReCreateMenuBar ()
 Recreates the menu bar. More...
 
void AddStandardHelpMenu (wxMenuBar *aMenuBar)
 Adds the standard KiCad help menu to the menubar. More...
 
bool IsWritable (const wxFileName &aFileName)
 Checks if aFileName can be written. More...
 
void CheckForAutoSaveFile (const wxFileName &aFileName)
 Check if an auto save file exists for aFileName and takes the appropriate action depending on the user input. More...
 
virtual void UpdateStatusBar ()
 Update the status bar information. More...
 
virtual void SyncToolbars ()
 Update the toolbars (mostly settings/check buttons/checkboxes) with the current controller state. More...
 
virtual void ShowChangedLanguage ()
 Redraw the menus and what not in current language. More...
 
void CommonSettingsChanged (bool aEnvVarsChanged, bool aTextVarsChanged) override
 Notification event that some of the common (suite-wide) settings have changed. More...
 
const wxString & GetAboutTitle () const
 
void SetShutdownBlockReason (const wxString &reason)
 Sets the block reason why the window/application is preventing OS shutdown. More...
 
void RemoveShutdownBlockReason ()
 Removes any shutdown block reason set. More...
 
bool SupportsShutdownBlockReason ()
 Whether or not the window supports setting a shutdown block reason. More...
 
virtual bool IsContentModified ()
 Get if the contents of the frame have been modified since the last save. More...
 
wxSize GetWindowSize ()
 Get the undecorated window size that can be used for restoring the window size. More...
 
virtual void ClearUndoORRedoList (UNDO_REDO_LIST aList, int aItemCount=-1)
 
virtual void ClearUndoRedoList ()
 Function ClearUndoRedoList clear undo and redo list, using ClearUndoORRedoList() picked items are deleted by ClearUndoORRedoList() according to their status. More...
 
virtual void PushCommandToUndoList (PICKED_ITEMS_LIST *aItem)
 Function PushCommandToUndoList add a command to undo in undo list delete the very old commands when the max count of undo commands is reached ( using ClearUndoORRedoList) More...
 
virtual void PushCommandToRedoList (PICKED_ITEMS_LIST *aItem)
 Function PushCommandToRedoList add a command to redo in redo list delete the very old commands when the max count of redo commands is reached ( using ClearUndoORRedoList) More...
 
virtual PICKED_ITEMS_LISTPopCommandFromUndoList ()
 PopCommandFromUndoList return the last command to undo and remove it from list nothing is deleted. More...
 
virtual PICKED_ITEMS_LISTPopCommandFromRedoList ()
 PopCommandFromRedoList return the last command to undo and remove it from list nothing is deleted. More...
 
int GetUndoCommandCount () const
 
int GetRedoCommandCount () const
 
int GetMaxUndoItems () const
 
TOOL_MANAGERGetToolManager () const
 Return the MVC controller. More...
 
virtual void PushTool (const std::string &actionName)
 NB: the definition of "tool" is different at the user level. More...
 
virtual void PopTool (const std::string &actionName)
 
bool ToolStackIsEmpty ()
 
std::string CurrentToolName () const
 
bool IsCurrentTool (const TOOL_ACTION &aAction) const
 
virtual void DisplayToolMsg (const wxString &msg)
 
bool GetDoImmediateActions () const
 Indicates that hotkeys should perform an immediate action even if another tool is currently active. More...
 
bool GetDragSelects () const
 Indicates that a drag should draw a selection rectangle, even when started over an item. More...
 
bool GetMoveWarpsCursor () const
 Indicates that a move operation should warp the mouse pointer to the origin of the move object. More...
 
virtual wxWindow * GetToolCanvas () const =0
 Canvas access. More...
 
virtual void RefreshCanvas ()
 
HOLDER_TYPE GetType ()
 
KIWAYKiway () const
 Function Kiway returns a reference to the KIWAY that this object has an opportunity to participate in. More...
 
PROJECTPrj () const
 Function Prj returns a reference to the PROJECT "associated with" this KIWAY. More...
 
void SetKiway (wxWindow *aDest, KIWAY *aKiway)
 Function SetKiway. More...
 

Protected Member Functions

virtual void menuNewPlot (wxCommandEvent &event)
 
virtual void menuOpenWorkbook (wxCommandEvent &event)
 
virtual void menuSaveWorkbook (wxCommandEvent &event)
 
virtual void menuSaveImage (wxCommandEvent &event)
 
virtual void menuSaveCsv (wxCommandEvent &event)
 
virtual void menuExit (wxCommandEvent &event)
 
virtual void menuZoomIn (wxCommandEvent &event)
 
virtual void menuZoomOut (wxCommandEvent &event)
 
virtual void menuZoomFit (wxCommandEvent &event)
 
virtual void menuShowGrid (wxCommandEvent &event)
 
virtual void menuShowGridUpdate (wxUpdateUIEvent &event)
 
virtual void menuShowLegend (wxCommandEvent &event)
 
virtual void menuShowLegendUpdate (wxUpdateUIEvent &event)
 
virtual void menuShowDotted (wxCommandEvent &event)
 
virtual void menuShowDottedUpdate (wxUpdateUIEvent &event)
 
virtual void menuWhiteBackground (wxCommandEvent &event)
 
virtual void menuShowWhiteBackgroundUpdate (wxUpdateUIEvent &event)
 
virtual void onPlotChanged (wxAuiNotebookEvent &event)
 
virtual void onPlotClose (wxAuiNotebookEvent &event)
 
virtual void onSignalDblClick (wxMouseEvent &event)
 
virtual void onSignalRClick (wxListEvent &event)
 
void kiway_express (KIWAY_EXPRESS &aEvent)
 event handler, routes to derivative specific virtual KiwayMailIn() More...
 
void language_change (wxCommandEvent &event)
 Function language_change is an event handler called on a language menu selection. More...
 
void onAutoSaveTimer (wxTimerEvent &aEvent)
 Handle the auto save timer event. More...
 
virtual bool isAutoSaveRequired () const
 Return the auto save status of the application. More...
 
virtual bool doAutoSave ()
 This should be overridden by the derived class to handle the auto save feature. More...
 
virtual void unitsChangeRefresh ()
 Called when when the units setting has changed to allow for any derived classes to handle refreshing and controls that have units based measurements in them. More...
 

Static Protected Member Functions

static wxString GetBackupSuffix ()
 
static wxString GetAutoSaveFilePrefix ()
 

Protected Attributes

wxMenuBar * m_mainMenu
 
wxMenu * m_fileMenu
 
wxMenu * m_simulationMenu
 
wxMenuItem * m_runSimulation
 
wxMenuItem * m_addSignals
 
wxMenuItem * m_probeSignals
 
wxMenuItem * m_tuneValue
 
wxMenuItem * m_showNetlist
 
wxMenuItem * m_settings
 
wxMenu * m_viewMenu
 
wxBoxSizer * m_sizerMain
 
wxToolBar * m_toolBar
 
wxSplitterWindow * m_splitterLeftRight
 
wxPanel * m_panelLeft
 
wxBoxSizer * m_sizer11
 
wxSplitterWindow * m_splitterPlotAndConsole
 
wxPanel * m_plotPanel
 
wxBoxSizer * m_sizerPlot
 
wxAuiNotebook * m_plotNotebook
 
wxPanel * m_panelConsole
 
wxBoxSizer * m_sizerConsole
 
wxTextCtrl * m_simConsole
 
wxPanel * m_sidePanel
 
wxBoxSizer * m_sideSizer
 
wxSplitterWindow * m_splitterSignals
 
wxPanel * m_panelSignals
 
wxStaticText * m_staticTextSignals
 
wxListView * m_signals
 
wxPanel * m_panelCursorsAndTune
 
wxSplitterWindow * m_splitterTuneValues
 
wxPanel * m_panelCursors
 
wxStaticText * m_staticTextCursors
 
wxListCtrl * m_cursors
 
wxPanel * m_tunePanel
 
wxStaticText * m_staticTextTune
 
wxBoxSizer * m_tuneSizer
 
bool m_modal
 
WX_EVENT_LOOPm_modal_loop
 
wxWindow * m_modal_resultant_parent
 
wxString m_modal_string
 
bool m_modal_ret_val
 
FRAME_T m_Ident
 
wxPoint m_FramePos
 
wxSize m_FrameSize
 
wxPoint m_NormalFramePos
 
wxSize m_NormalFrameSize
 
wxString m_AboutTitle
 
wxAuiManager m_auimgr
 
wxString m_perspective
 
WX_INFOBARm_infoBar
 
wxString m_configName
 
SETTINGS_MANAGERm_settingsManager
 
FILE_HISTORYm_fileHistory
 
bool m_hasAutoSave
 
bool m_autoSaveState
 
int m_autoSaveInterval
 
wxTimer * m_autoSaveTimer
 
bool m_FlagModified
 
bool m_FlagSave
 
int m_UndoRedoCountMax
 
UNDO_REDO_CONTAINER m_undoList
 
UNDO_REDO_CONTAINER m_redoList
 
wxString m_mruPath
 
EDA_UNITS m_userUnits
 
TOOL_MANAGERm_toolManager
 
ACTIONSm_actions
 
TOOL_DISPATCHERm_toolDispatcher
 
std::vector< std::string > m_toolStack
 
bool m_immediateActions
 
bool m_dragSelects
 
bool m_moveWarpsCursor
 

Static Protected Attributes

static constexpr int KICAD_AUI_TB_STYLE = wxAUI_TB_DEFAULT_STYLE | wxAUI_TB_PLAIN_BACKGROUND
 

Default style flags used for wxAUI toolbars

More...
 

Detailed Description

Class SIM_PLOT_FRAME_BASE.

Definition at line 51 of file sim_plot_frame_base.h.

Member Enumeration Documentation

◆ HOLDER_TYPE

enum KIWAY_HOLDER::HOLDER_TYPE
inherited
Enumerator
DIALOG 
FRAME 
PANEL 

Definition at line 42 of file kiway_holder.h.

◆ UNDO_REDO_LIST

Function ClearUndoORRedoList (virtual).

this function must remove the aItemCount old commands from aList and delete commands, pickers and picked items if needed Because picked items must be deleted only if they are not in use, this is a virtual pure function that must be created for SCH_SCREEN and PCB_SCREEN

Parameters
aList= the UNDO_REDO_CONTAINER of commands
aItemCount= number of old commands to delete. -1 to remove all old commands this will empty the list of commands. Commands are deleted from the older to the last.
Enumerator
UNDO_LIST 
REDO_LIST 

Definition at line 551 of file eda_base_frame.h.

Constructor & Destructor Documentation

◆ SIM_PLOT_FRAME_BASE()

SIM_PLOT_FRAME_BASE::SIM_PLOT_FRAME_BASE ( wxWindow *  parent,
wxWindowID  id = wxID_ANY,
const wxString &  title = _("Spice Simulator"),
const wxPoint pos = wxDefaultPosition,
const wxSize &  size = wxSize( 564,531 ),
long  style = wxDEFAULT_FRAME_STYLE|wxTAB_TRAVERSAL,
const wxString &  name = wxT("SIM_PLOT_FRAME") 
)

Definition at line 12 of file sim_plot_frame_base.cpp.

12  : KIWAY_PLAYER( parent, id, title, pos, size, style, name )
13 {
14  this->SetSizeHints( wxSize( -1,-1 ), wxDefaultSize );
15 
16  m_mainMenu = new wxMenuBar( 0 );
17  m_fileMenu = new wxMenu();
18  wxMenuItem* m_newPlot;
19  m_newPlot = new wxMenuItem( m_fileMenu, wxID_NEW, wxString( _("New Plot") ) , wxEmptyString, wxITEM_NORMAL );
20  m_fileMenu->Append( m_newPlot );
21 
22  m_fileMenu->AppendSeparator();
23 
24  wxMenuItem* m_openWorkbook;
25  m_openWorkbook = new wxMenuItem( m_fileMenu, wxID_OPEN, wxString( _("Open Workbook") ) , wxEmptyString, wxITEM_NORMAL );
26  m_fileMenu->Append( m_openWorkbook );
27 
28  wxMenuItem* m_saveWorkbook;
29  m_saveWorkbook = new wxMenuItem( m_fileMenu, wxID_SAVE, wxString( _("Save Workbook") ) , wxEmptyString, wxITEM_NORMAL );
30  m_fileMenu->Append( m_saveWorkbook );
31 
32  m_fileMenu->AppendSeparator();
33 
34  wxMenuItem* m_saveImage;
35  m_saveImage = new wxMenuItem( m_fileMenu, ID_SAVE_AS_IMAGE, wxString( _("Save as Image") ) , wxEmptyString, wxITEM_NORMAL );
36  m_fileMenu->Append( m_saveImage );
37 
38  wxMenuItem* m_saveCsv;
39  m_saveCsv = new wxMenuItem( m_fileMenu, ID_SAVE_AS_CSV, wxString( _("Save as .csv File") ) , wxEmptyString, wxITEM_NORMAL );
40  m_fileMenu->Append( m_saveCsv );
41 
42  m_fileMenu->AppendSeparator();
43 
44  wxMenuItem* m_exitSim;
45  m_exitSim = new wxMenuItem( m_fileMenu, wxID_CLOSE, wxString( _("Close Simulation") ) + wxT('\t') + wxT("CTRL+W"), wxEmptyString, wxITEM_NORMAL );
46  m_fileMenu->Append( m_exitSim );
47 
48  m_mainMenu->Append( m_fileMenu, _("File") );
49 
50  m_simulationMenu = new wxMenu();
51  m_runSimulation = new wxMenuItem( m_simulationMenu, ID_MENU_RUN_SIM, wxString( _("Run Simulation") ) + wxT('\t') + wxT("R"), wxEmptyString, wxITEM_NORMAL );
53 
54  m_simulationMenu->AppendSeparator();
55 
56  m_addSignals = new wxMenuItem( m_simulationMenu, ID_MENU_ADD_SIGNAL, wxString( _("Add Signals...") ) + wxT('\t') + wxT("A"), wxEmptyString, wxITEM_NORMAL );
57  m_simulationMenu->Append( m_addSignals );
58 
59  m_probeSignals = new wxMenuItem( m_simulationMenu, ID_MENU_PROBE_SIGNALS, wxString( _("Probe from schematics") ) + wxT('\t') + wxT("P"), wxEmptyString, wxITEM_NORMAL );
61 
62  m_tuneValue = new wxMenuItem( m_simulationMenu, ID_MENU_TUNE_SIGNALS, wxString( _("Tune Component Value") ) + wxT('\t') + wxT("T"), wxEmptyString, wxITEM_NORMAL );
63  m_simulationMenu->Append( m_tuneValue );
64 
65  m_simulationMenu->AppendSeparator();
66 
67  m_showNetlist = new wxMenuItem( m_simulationMenu, ID_MENU_SHOW_NETLIST, wxString( _("Show SPICE Netlist...") ) , _("Shows current simulation's netlist. Useful for debugging SPICE errors."), wxITEM_NORMAL );
69 
70  m_simulationMenu->AppendSeparator();
71 
72  m_settings = new wxMenuItem( m_simulationMenu, ID_MENU_SET_SIMUL, wxString( _("Settings...") ) , wxEmptyString, wxITEM_NORMAL );
73  m_simulationMenu->Append( m_settings );
74 
75  m_mainMenu->Append( m_simulationMenu, _("Simulation") );
76 
77  m_viewMenu = new wxMenu();
78  wxMenuItem* m_zoomIn;
79  m_zoomIn = new wxMenuItem( m_viewMenu, wxID_ZOOM_IN, wxString( _("Zoom In") ) , wxEmptyString, wxITEM_NORMAL );
80  m_viewMenu->Append( m_zoomIn );
81 
82  wxMenuItem* m_zoomOut;
83  m_zoomOut = new wxMenuItem( m_viewMenu, wxID_ZOOM_OUT, wxString( _("Zoom Out") ) , wxEmptyString, wxITEM_NORMAL );
84  m_viewMenu->Append( m_zoomOut );
85 
86  wxMenuItem* m_zoomFit;
87  m_zoomFit = new wxMenuItem( m_viewMenu, wxID_ZOOM_FIT, wxString( _("Fit on Screen") ) , wxEmptyString, wxITEM_NORMAL );
88  m_viewMenu->Append( m_zoomFit );
89 
90  m_viewMenu->AppendSeparator();
91 
92  wxMenuItem* m_showGrid;
93  m_showGrid = new wxMenuItem( m_viewMenu, ID_MENU_SHOW_GRID, wxString( _("Show &Grid") ) , wxEmptyString, wxITEM_CHECK );
94  m_viewMenu->Append( m_showGrid );
95 
96  wxMenuItem* m_showLegend;
97  m_showLegend = new wxMenuItem( m_viewMenu, ID_MENU_SHOW_LEGEND, wxString( _("Show &Legend") ) , wxEmptyString, wxITEM_CHECK );
98  m_viewMenu->Append( m_showLegend );
99 
100  m_viewMenu->AppendSeparator();
101 
102  wxMenuItem* m_showDotted;
103  m_showDotted = new wxMenuItem( m_viewMenu, ID_MENU_DOTTED, wxString( _("Dotted Current/Phase") ) , wxEmptyString, wxITEM_CHECK );
104  m_viewMenu->Append( m_showDotted );
105 
106  wxMenuItem* m_showWhiteBackground;
107  m_showWhiteBackground = new wxMenuItem( m_viewMenu, ID_MENU_WHITE_BG, wxString( _("White Background") ) , wxEmptyString, wxITEM_CHECK );
108  m_viewMenu->Append( m_showWhiteBackground );
109 
110  m_mainMenu->Append( m_viewMenu, _("View") );
111 
112  this->SetMenuBar( m_mainMenu );
113 
114  m_sizerMain = new wxBoxSizer( wxVERTICAL );
115 
116  m_toolBar = new wxToolBar( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTB_FLAT|wxTB_HORIZONTAL|wxTB_TEXT );
117  m_toolBar->Realize();
118 
119  m_sizerMain->Add( m_toolBar, 0, wxEXPAND, 5 );
120 
121  m_splitterLeftRight = new wxSplitterWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE );
122  m_splitterLeftRight->SetSashGravity( 0.7 );
123  m_splitterLeftRight->Connect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterLeftRightOnIdle ), NULL, this );
124  m_splitterLeftRight->SetMinimumPaneSize( 50 );
125 
126  m_panelLeft = new wxPanel( m_splitterLeftRight, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
127  m_panelLeft->SetMinSize( wxSize( 300,-1 ) );
128 
129  m_sizer11 = new wxBoxSizer( wxVERTICAL );
130 
131  m_splitterPlotAndConsole = new wxSplitterWindow( m_panelLeft, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE );
132  m_splitterPlotAndConsole->SetSashGravity( 0.8 );
133  m_splitterPlotAndConsole->Connect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this );
134  m_splitterPlotAndConsole->SetMinimumPaneSize( 50 );
135 
136  m_plotPanel = new wxPanel( m_splitterPlotAndConsole, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
137  m_plotPanel->SetMinSize( wxSize( -1,200 ) );
138 
139  m_sizerPlot = new wxBoxSizer( wxHORIZONTAL );
140 
141  m_plotNotebook = new wxAuiNotebook( m_plotPanel, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxAUI_NB_CLOSE_ON_ALL_TABS|wxAUI_NB_MIDDLE_CLICK_CLOSE|wxAUI_NB_TAB_MOVE|wxAUI_NB_TAB_SPLIT|wxAUI_NB_TOP );
142  m_plotNotebook->SetMinSize( wxSize( 200,-1 ) );
143 
144 
145  m_sizerPlot->Add( m_plotNotebook, 1, wxEXPAND, 5 );
146 
147 
148  m_plotPanel->SetSizer( m_sizerPlot );
149  m_plotPanel->Layout();
150  m_sizerPlot->Fit( m_plotPanel );
151  m_panelConsole = new wxPanel( m_splitterPlotAndConsole, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
152  m_panelConsole->SetMinSize( wxSize( -1,100 ) );
153 
154  m_sizerConsole = new wxBoxSizer( wxVERTICAL );
155 
156  m_simConsole = new wxTextCtrl( m_panelConsole, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxTE_DONTWRAP|wxTE_MULTILINE|wxTE_READONLY );
157  m_simConsole->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), wxFONTFAMILY_TELETYPE, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, false, wxEmptyString ) );
158 
159  m_sizerConsole->Add( m_simConsole, 1, wxEXPAND, 5 );
160 
161 
162  m_panelConsole->SetSizer( m_sizerConsole );
163  m_panelConsole->Layout();
165  m_splitterPlotAndConsole->SplitHorizontally( m_plotPanel, m_panelConsole, 500 );
166  m_sizer11->Add( m_splitterPlotAndConsole, 1, wxEXPAND, 5 );
167 
168 
169  m_panelLeft->SetSizer( m_sizer11 );
170  m_panelLeft->Layout();
171  m_sizer11->Fit( m_panelLeft );
172  m_sidePanel = new wxPanel( m_splitterLeftRight, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
173  m_sidePanel->SetMinSize( wxSize( 200,-1 ) );
174 
175  m_sideSizer = new wxBoxSizer( wxVERTICAL );
176 
177  m_splitterSignals = new wxSplitterWindow( m_sidePanel, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE );
178  m_splitterSignals->SetSashGravity( 0.33 );
179  m_splitterSignals->Connect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterSignalsOnIdle ), NULL, this );
180  m_splitterSignals->SetMinimumPaneSize( 20 );
181 
182  m_panelSignals = new wxPanel( m_splitterSignals, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
183  m_panelSignals->SetMinSize( wxSize( -1,100 ) );
184 
185  wxBoxSizer* bSizer10;
186  bSizer10 = new wxBoxSizer( wxVERTICAL );
187 
188  m_staticTextSignals = new wxStaticText( m_panelSignals, wxID_ANY, _("Signals"), wxDefaultPosition, wxDefaultSize, 0 );
189  m_staticTextSignals->Wrap( -1 );
190  bSizer10->Add( m_staticTextSignals, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 );
191 
192  m_signals = new wxListView( m_panelSignals, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_REPORT|wxLC_SINGLE_SEL );
193  bSizer10->Add( m_signals, 1, wxEXPAND, 5 );
194 
195 
196  m_panelSignals->SetSizer( bSizer10 );
197  m_panelSignals->Layout();
198  bSizer10->Fit( m_panelSignals );
199  m_panelCursorsAndTune = new wxPanel( m_splitterSignals, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
200  m_panelCursorsAndTune->SetMinSize( wxSize( -1,300 ) );
201 
202  wxBoxSizer* bSizer9;
203  bSizer9 = new wxBoxSizer( wxVERTICAL );
204 
205  m_splitterTuneValues = new wxSplitterWindow( m_panelCursorsAndTune, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3DSASH|wxSP_LIVE_UPDATE|wxBORDER_NONE );
206  m_splitterTuneValues->SetSashGravity( 0.5 );
207  m_splitterTuneValues->Connect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterTuneValuesOnIdle ), NULL, this );
208  m_splitterTuneValues->SetMinimumPaneSize( 20 );
209 
210  m_panelCursors = new wxPanel( m_splitterTuneValues, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
211  m_panelCursors->SetMinSize( wxSize( -1,100 ) );
212 
213  wxBoxSizer* bSizer12;
214  bSizer12 = new wxBoxSizer( wxVERTICAL );
215 
216  m_staticTextCursors = new wxStaticText( m_panelCursors, wxID_ANY, _("Cursors"), wxDefaultPosition, wxDefaultSize, 0 );
217  m_staticTextCursors->Wrap( -1 );
218  bSizer12->Add( m_staticTextCursors, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 );
219 
220  m_cursors = new wxListCtrl( m_panelCursors, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLC_HRULES|wxLC_REPORT|wxLC_SINGLE_SEL );
221  bSizer12->Add( m_cursors, 1, wxEXPAND, 5 );
222 
223 
224  m_panelCursors->SetSizer( bSizer12 );
225  m_panelCursors->Layout();
226  bSizer12->Fit( m_panelCursors );
227  m_tunePanel = new wxPanel( m_splitterTuneValues, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
228  m_tunePanel->SetMinSize( wxSize( -1,100 ) );
229 
230  wxBoxSizer* bSizer13;
231  bSizer13 = new wxBoxSizer( wxVERTICAL );
232 
233  m_staticTextTune = new wxStaticText( m_tunePanel, wxID_ANY, _("Tune"), wxDefaultPosition, wxDefaultSize, 0 );
234  m_staticTextTune->Wrap( -1 );
235  bSizer13->Add( m_staticTextTune, 0, wxTOP|wxBOTTOM|wxRIGHT, 5 );
236 
237  m_tuneSizer = new wxBoxSizer( wxHORIZONTAL );
238 
239 
240  bSizer13->Add( m_tuneSizer, 1, wxEXPAND, 5 );
241 
242 
243  m_tunePanel->SetSizer( bSizer13 );
244  m_tunePanel->Layout();
245  bSizer13->Fit( m_tunePanel );
246  m_splitterTuneValues->SplitHorizontally( m_panelCursors, m_tunePanel, 0 );
247  bSizer9->Add( m_splitterTuneValues, 1, wxEXPAND, 5 );
248 
249 
250  m_panelCursorsAndTune->SetSizer( bSizer9 );
251  m_panelCursorsAndTune->Layout();
252  bSizer9->Fit( m_panelCursorsAndTune );
253  m_splitterSignals->SplitHorizontally( m_panelSignals, m_panelCursorsAndTune, 0 );
254  m_sideSizer->Add( m_splitterSignals, 1, wxEXPAND, 5 );
255 
256 
257  m_sidePanel->SetSizer( m_sideSizer );
258  m_sidePanel->Layout();
259  m_sideSizer->Fit( m_sidePanel );
260  m_splitterLeftRight->SplitVertically( m_panelLeft, m_sidePanel, 700 );
261  m_sizerMain->Add( m_splitterLeftRight, 1, wxEXPAND, 5 );
262 
263 
264  this->SetSizer( m_sizerMain );
265  this->Layout();
266 
267  this->Centre( wxBOTH );
268 
269  // Connect Events
270  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuNewPlot ), this, m_newPlot->GetId());
271  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuOpenWorkbook ), this, m_openWorkbook->GetId());
272  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuSaveWorkbook ), this, m_saveWorkbook->GetId());
273  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuSaveImage ), this, m_saveImage->GetId());
274  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuSaveCsv ), this, m_saveCsv->GetId());
275  m_fileMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuExit ), this, m_exitSim->GetId());
276  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuZoomIn ), this, m_zoomIn->GetId());
277  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuZoomOut ), this, m_zoomOut->GetId());
278  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuZoomFit ), this, m_zoomFit->GetId());
279  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuShowGrid ), this, m_showGrid->GetId());
280  this->Connect( m_showGrid->GetId(), wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowGridUpdate ) );
281  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuShowLegend ), this, m_showLegend->GetId());
282  this->Connect( m_showLegend->GetId(), wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowLegendUpdate ) );
283  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuShowDotted ), this, m_showDotted->GetId());
284  this->Connect( m_showDotted->GetId(), wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowDottedUpdate ) );
285  m_viewMenu->Bind(wxEVT_COMMAND_MENU_SELECTED, wxCommandEventHandler( SIM_PLOT_FRAME_BASE::menuWhiteBackground ), this, m_showWhiteBackground->GetId());
286  this->Connect( m_showWhiteBackground->GetId(), wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowWhiteBackgroundUpdate ) );
287  m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIM_PLOT_FRAME_BASE::onPlotChanged ), NULL, this );
288  m_plotNotebook->Connect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIM_PLOT_FRAME_BASE::onPlotClose ), NULL, this );
289  m_signals->Connect( wxEVT_LEFT_DCLICK, wxMouseEventHandler( SIM_PLOT_FRAME_BASE::onSignalDblClick ), NULL, this );
290  m_signals->Connect( wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, wxListEventHandler( SIM_PLOT_FRAME_BASE::onSignalRClick ), NULL, this );
291 }
#define ID_MENU_PROBE_SIGNALS
#define ID_SAVE_AS_IMAGE
virtual void menuShowWhiteBackgroundUpdate(wxUpdateUIEvent &event)
wxSplitterWindow * m_splitterSignals
virtual void menuSaveWorkbook(wxCommandEvent &event)
KIWAY_PLAYER(KIWAY *aKiway, wxWindow *aParent, FRAME_T aFrameType, const wxString &aTitle, const wxPoint &aPos, const wxSize &aSize, long aStyle, const wxString &aWdoName=wxFrameNameStr)
virtual void menuShowLegendUpdate(wxUpdateUIEvent &event)
void m_splitterLeftRightOnIdle(wxIdleEvent &)
void m_splitterSignalsOnIdle(wxIdleEvent &)
virtual void onPlotChanged(wxAuiNotebookEvent &event)
virtual void menuShowGrid(wxCommandEvent &event)
virtual void menuZoomOut(wxCommandEvent &event)
#define ID_MENU_WHITE_BG
#define ID_SAVE_AS_CSV
virtual void menuShowDotted(wxCommandEvent &event)
wxSplitterWindow * m_splitterTuneValues
wxAuiNotebook * m_plotNotebook
virtual void menuSaveCsv(wxCommandEvent &event)
virtual void onSignalRClick(wxListEvent &event)
virtual void menuShowLegend(wxCommandEvent &event)
#define NULL
#define ID_MENU_SHOW_NETLIST
virtual void onPlotClose(wxAuiNotebookEvent &event)
wxSplitterWindow * m_splitterLeftRight
wxMenuItem * m_runSimulation
#define ID_MENU_TUNE_SIGNALS
virtual void menuOpenWorkbook(wxCommandEvent &event)
virtual void menuZoomIn(wxCommandEvent &event)
void m_splitterPlotAndConsoleOnIdle(wxIdleEvent &)
#define ID_MENU_SHOW_LEGEND
wxStaticText * m_staticTextTune
virtual void menuWhiteBackground(wxCommandEvent &event)
virtual void onSignalDblClick(wxMouseEvent &event)
#define ID_MENU_SET_SIMUL
virtual void menuShowGridUpdate(wxUpdateUIEvent &event)
virtual void menuNewPlot(wxCommandEvent &event)
#define ID_MENU_ADD_SIGNAL
virtual void menuSaveImage(wxCommandEvent &event)
wxStaticText * m_staticTextSignals
const char * name
Definition: DXF_plotter.cpp:60
#define ID_MENU_SHOW_GRID
#define _(s)
Definition: 3d_actions.cpp:33
#define ID_MENU_DOTTED
void m_splitterTuneValuesOnIdle(wxIdleEvent &)
virtual void menuZoomFit(wxCommandEvent &event)
virtual void menuExit(wxCommandEvent &event)
wxSplitterWindow * m_splitterPlotAndConsole
virtual void menuShowDottedUpdate(wxUpdateUIEvent &event)
#define ID_MENU_RUN_SIM
wxStaticText * m_staticTextCursors

References _, ID_MENU_ADD_SIGNAL, ID_MENU_DOTTED, ID_MENU_PROBE_SIGNALS, ID_MENU_RUN_SIM, ID_MENU_SET_SIMUL, ID_MENU_SHOW_GRID, ID_MENU_SHOW_LEGEND, ID_MENU_SHOW_NETLIST, ID_MENU_TUNE_SIGNALS, ID_MENU_WHITE_BG, ID_SAVE_AS_CSV, ID_SAVE_AS_IMAGE, m_addSignals, m_cursors, m_fileMenu, m_mainMenu, m_panelConsole, m_panelCursors, m_panelCursorsAndTune, m_panelLeft, m_panelSignals, m_plotNotebook, m_plotPanel, m_probeSignals, m_runSimulation, m_settings, m_showNetlist, m_sidePanel, m_sideSizer, m_signals, m_simConsole, m_simulationMenu, m_sizer11, m_sizerConsole, m_sizerMain, m_sizerPlot, m_splitterLeftRight, m_splitterLeftRightOnIdle(), m_splitterPlotAndConsole, m_splitterPlotAndConsoleOnIdle(), m_splitterSignals, m_splitterSignalsOnIdle(), m_splitterTuneValues, m_splitterTuneValuesOnIdle(), m_staticTextCursors, m_staticTextSignals, m_staticTextTune, m_toolBar, m_tunePanel, m_tuneSizer, m_tuneValue, m_viewMenu, menuExit(), menuNewPlot(), menuOpenWorkbook(), menuSaveCsv(), menuSaveImage(), menuSaveWorkbook(), menuShowDotted(), menuShowDottedUpdate(), menuShowGrid(), menuShowGridUpdate(), menuShowLegend(), menuShowLegendUpdate(), menuShowWhiteBackgroundUpdate(), menuWhiteBackground(), menuZoomFit(), menuZoomIn(), menuZoomOut(), NULL, onPlotChanged(), onPlotClose(), onSignalDblClick(), and onSignalRClick().

◆ ~SIM_PLOT_FRAME_BASE()

SIM_PLOT_FRAME_BASE::~SIM_PLOT_FRAME_BASE ( )

Definition at line 293 of file sim_plot_frame_base.cpp.

294 {
295  // Disconnect Events
296  this->Disconnect( ID_MENU_SHOW_GRID, wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowGridUpdate ) );
297  this->Disconnect( ID_MENU_SHOW_LEGEND, wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowLegendUpdate ) );
298  this->Disconnect( ID_MENU_DOTTED, wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowDottedUpdate ) );
299  this->Disconnect( ID_MENU_WHITE_BG, wxEVT_UPDATE_UI, wxUpdateUIEventHandler( SIM_PLOT_FRAME_BASE::menuShowWhiteBackgroundUpdate ) );
300  m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CHANGED, wxAuiNotebookEventHandler( SIM_PLOT_FRAME_BASE::onPlotChanged ), NULL, this );
301  m_plotNotebook->Disconnect( wxEVT_COMMAND_AUINOTEBOOK_PAGE_CLOSE, wxAuiNotebookEventHandler( SIM_PLOT_FRAME_BASE::onPlotClose ), NULL, this );
302  m_signals->Disconnect( wxEVT_LEFT_DCLICK, wxMouseEventHandler( SIM_PLOT_FRAME_BASE::onSignalDblClick ), NULL, this );
303  m_signals->Disconnect( wxEVT_COMMAND_LIST_ITEM_RIGHT_CLICK, wxListEventHandler( SIM_PLOT_FRAME_BASE::onSignalRClick ), NULL, this );
304 
305 }
virtual void menuShowWhiteBackgroundUpdate(wxUpdateUIEvent &event)
virtual void menuShowLegendUpdate(wxUpdateUIEvent &event)
virtual void onPlotChanged(wxAuiNotebookEvent &event)
#define ID_MENU_WHITE_BG
wxAuiNotebook * m_plotNotebook
virtual void onSignalRClick(wxListEvent &event)
#define NULL
virtual void onPlotClose(wxAuiNotebookEvent &event)
#define ID_MENU_SHOW_LEGEND
virtual void onSignalDblClick(wxMouseEvent &event)
virtual void menuShowGridUpdate(wxUpdateUIEvent &event)
#define ID_MENU_SHOW_GRID
#define ID_MENU_DOTTED
virtual void menuShowDottedUpdate(wxUpdateUIEvent &event)

References ID_MENU_DOTTED, ID_MENU_SHOW_GRID, ID_MENU_SHOW_LEGEND, ID_MENU_WHITE_BG, m_plotNotebook, m_signals, menuShowDottedUpdate(), menuShowGridUpdate(), menuShowLegendUpdate(), menuShowWhiteBackgroundUpdate(), NULL, onPlotChanged(), onPlotClose(), onSignalDblClick(), and onSignalRClick().

Member Function Documentation

◆ AddStandardHelpMenu()

void EDA_BASE_FRAME::AddStandardHelpMenu ( wxMenuBar *  aMenuBar)
inherited

Adds the standard KiCad help menu to the menubar.

Definition at line 298 of file eda_base_frame.cpp.

299 {
300  COMMON_CONTROL* commonControl = m_toolManager->GetTool<COMMON_CONTROL>();
301  ACTION_MENU* helpMenu = new ACTION_MENU( false );
302 
303  helpMenu->SetTool( commonControl );
304 
305  helpMenu->Add( ACTIONS::help );
306  helpMenu->Add( ACTIONS::gettingStarted );
307  helpMenu->Add( ACTIONS::listHotKeys );
308  helpMenu->Add( ACTIONS::getInvolved );
309  helpMenu->Add( ACTIONS::reportBug );
310 
311  helpMenu->AppendSeparator();
312  helpMenu->Add( _( "&About KiCad" ), "", wxID_ABOUT, about_xpm );
313 
314  aMenuBar->Append( helpMenu, _( "&Help" ) );
315 }
static TOOL_ACTION listHotKeys
Definition: actions.h:172
ACTION_MENU.
Definition: action_menu.h:44
static TOOL_ACTION reportBug
Definition: actions.h:174
const BITMAP_OPAQUE about_xpm[1]
Definition: about.cpp:84
COMMON_CONTROL.
TOOL_MANAGER * m_toolManager
Definition: tools_holder.h:48
#define _(s)
Definition: 3d_actions.cpp:33
static TOOL_ACTION help
Definition: actions.h:171
static TOOL_ACTION getInvolved
Definition: actions.h:173
static TOOL_ACTION gettingStarted
Definition: actions.h:170

References _, about_xpm, ACTIONS::getInvolved, ACTIONS::gettingStarted, TOOL_MANAGER::GetTool(), ACTIONS::help, ACTIONS::listHotKeys, TOOLS_HOLDER::m_toolManager, and ACTIONS::reportBug.

Referenced by EDA_3D_VIEWER::CreateMenuBar(), LIB_VIEW_FRAME::ReCreateMenuBar(), KICAD_MANAGER_FRAME::ReCreateMenuBar(), FOOTPRINT_EDIT_FRAME::ReCreateMenuBar(), FOOTPRINT_VIEWER_FRAME::ReCreateMenuBar(), LIB_EDIT_FRAME::ReCreateMenuBar(), PL_EDITOR_FRAME::ReCreateMenuBar(), CVPCB_MAINFRAME::ReCreateMenuBar(), SCH_EDIT_FRAME::ReCreateMenuBar(), GERBVIEW_FRAME::ReCreateMenuBar(), and PCB_EDIT_FRAME::ReCreateMenuBar().

◆ ChangeUserUnits()

void EDA_BASE_FRAME::ChangeUserUnits ( EDA_UNITS  aUnits)
inherited

Definition at line 831 of file eda_base_frame.cpp.

832 {
833  SetUserUnits( aUnits );
835 
836  wxCommandEvent e( UNITS_CHANGED );
837  ProcessEventLocally( e );
838 }
virtual void unitsChangeRefresh()
Called when when the units setting has changed to allow for any derived classes to handle refreshing ...
void SetUserUnits(EDA_UNITS aUnits)

References EDA_BASE_FRAME::SetUserUnits(), and EDA_BASE_FRAME::unitsChangeRefresh().

Referenced by COMMON_TOOLS::ImperialUnits(), COMMON_TOOLS::MetricUnits(), and COMMON_TOOLS::ToggleUnits().

◆ CheckForAutoSaveFile()

void EDA_BASE_FRAME::CheckForAutoSaveFile ( const wxFileName &  aFileName)
inherited

Check if an auto save file exists for aFileName and takes the appropriate action depending on the user input.

If an auto save file exists for aFileName, the user is prompted if they wish to replace file aFileName with the auto saved file. If the user chooses to replace the file, the backup file of aFileName is removed, aFileName is renamed to the backup file name, and the auto save file is renamed to aFileName. If user chooses to keep the existing version of aFileName, the auto save file is removed.

Parameters
aFileNameA wxFileName object containing the file name to check.

Definition at line 729 of file eda_base_frame.cpp.

730 {
731  wxCHECK_RET( aFileName.IsOk(), wxT( "Invalid file name!" ) );
732 
733  wxFileName autoSaveFileName = aFileName;
734 
735  // Check for auto save file.
736  autoSaveFileName.SetName( GetAutoSaveFilePrefix() + aFileName.GetName() );
737 
738  wxLogTrace( traceAutoSave,
739  wxT( "Checking for auto save file " ) + autoSaveFileName.GetFullPath() );
740 
741  if( !autoSaveFileName.FileExists() )
742  return;
743 
744  wxString msg = wxString::Format( _(
745  "Well this is potentially embarrassing!\n"
746  "It appears that the last time you were editing the file\n"
747  "\"%s\"\n"
748  "it was not saved properly. Do you wish to restore the last saved edits you made?" ),
749  GetChars( aFileName.GetFullName() )
750  );
751 
752  int response = wxMessageBox( msg, Pgm().App().GetAppName(), wxYES_NO | wxICON_QUESTION, this );
753 
754  // Make a backup of the current file, delete the file, and rename the auto save file to
755  // the file name.
756  if( response == wxYES )
757  {
758  if( !wxRenameFile( autoSaveFileName.GetFullPath(), aFileName.GetFullPath() ) )
759  {
760  wxMessageBox( _( "The auto save file could not be renamed to the board file name." ),
761  Pgm().App().GetAppName(), wxOK | wxICON_EXCLAMATION, this );
762  }
763  }
764  else
765  {
766  wxLogTrace( traceAutoSave,
767  wxT( "Removing auto save file " ) + autoSaveFileName.GetFullPath() );
768 
769  // Remove the auto save file when using the previous file as is.
770  wxRemoveFile( autoSaveFileName.GetFullPath() );
771  }
772 }
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:104
const wxChar *const traceAutoSave
Flag to enable auto save feature debug tracing.
static wxString GetAutoSaveFilePrefix()
static const wxChar * GetChars(const wxString &s)
Function GetChars returns a wxChar* to the actual wxChar* data within a wxString, and is helpful for ...
Definition: macros.h:153
void Format(OUTPUTFORMATTER *out, int aNestLevel, int aCtl, CPTREE &aTree)
Function Format outputs a PTREE into s-expression format via an OUTPUTFORMATTER derivative.
Definition: ptree.cpp:205
#define _(s)
Definition: 3d_actions.cpp:33

References _, Format(), EDA_BASE_FRAME::GetAutoSaveFilePrefix(), GetChars(), Pgm(), and traceAutoSave.

Referenced by SCH_EDIT_FRAME::OpenProjectFiles(), and PCB_EDIT_FRAME::OpenProjectFiles().

◆ ClearFileHistory()

void EDA_BASE_FRAME::ClearFileHistory ( FILE_HISTORY aFileHistory = nullptr)
inherited

Removes all files from the file history.

Parameters
aFileHistoryThe FILE_HISTORY in use. If null, the main application file history is used

Definition at line 626 of file eda_base_frame.cpp.

627 {
628  if( !aFileHistory )
629  aFileHistory = m_fileHistory;
630 
631  wxASSERT( aFileHistory );
632 
633  aFileHistory->ClearFileHistory();
634 
635  // Update the menubar to update the file history menu
636  if( GetMenuBar() )
637  {
638  ReCreateMenuBar();
639  GetMenuBar()->Refresh();
640  }
641 }
void ClearFileHistory()
Clear all entries from the file history.
FILE_HISTORY * m_fileHistory
virtual void ReCreateMenuBar()
Recreates the menu bar.

References FILE_HISTORY::ClearFileHistory(), EDA_BASE_FRAME::m_fileHistory, and EDA_BASE_FRAME::ReCreateMenuBar().

Referenced by GERBVIEW_FRAME::OnClearDrlFileHistory(), KICAD_MANAGER_FRAME::OnClearFileHistory(), PL_EDITOR_FRAME::OnClearFileHistory(), PCB_EDIT_FRAME::OnClearFileHistory(), SCH_EDIT_FRAME::OnClearFileHistory(), GERBVIEW_FRAME::OnClearGbrFileHistory(), GERBVIEW_FRAME::OnClearJobFileHistory(), and GERBVIEW_FRAME::OnClearZipFileHistory().

◆ ClearUndoORRedoList()

virtual void EDA_BASE_FRAME::ClearUndoORRedoList ( UNDO_REDO_LIST  aList,
int  aItemCount = -1 
)
inlinevirtualinherited

◆ ClearUndoRedoList()

◆ CommonSettingsChanged()

void EDA_BASE_FRAME::CommonSettingsChanged ( bool  aEnvVarsChanged,
bool  aTextVarsChanged 
)
overridevirtualinherited

Notification event that some of the common (suite-wide) settings have changed.

Update menus, toolbars, local variables, etc.

Reimplemented from TOOLS_HOLDER.

Reimplemented in PCB_EDIT_FRAME, PCB_BASE_FRAME, FOOTPRINT_EDIT_FRAME, KICAD_MANAGER_FRAME, FOOTPRINT_VIEWER_FRAME, PL_EDITOR_FRAME, and EDA_DRAW_FRAME.

Definition at line 328 of file eda_base_frame.cpp.

329 {
330  TOOLS_HOLDER::CommonSettingsChanged( aEnvVarsChanged, aTextVarsChanged );
331 
332  COMMON_SETTINGS* settings = Pgm().GetCommonSettings();
333 
334  if( m_fileHistory )
335  {
336  int historySize = settings->m_System.file_history_size;
337  m_fileHistory->SetMaxFiles( (unsigned) std::max( 0, historySize ) );
338  }
339 
340  if( GetMenuBar() )
341  {
342  // For icons in menus, icon scaling & hotkeys
343  ReCreateMenuBar();
344  GetMenuBar()->Refresh();
345  }
346 }
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:104
void SetMaxFiles(size_t aMaxFiles)
Update the number of files that will be contained inside the file history.
Definition: filehistory.cpp:83
virtual void CommonSettingsChanged(bool aEnvVarsChanged, bool aTextVarsChanged)
Notification event that some of the common (suite-wide) settings have changed.
FILE_HISTORY * m_fileHistory
virtual void ReCreateMenuBar()
Recreates the menu bar.

References TOOLS_HOLDER::CommonSettingsChanged(), COMMON_SETTINGS::SYSTEM::file_history_size, EDA_BASE_FRAME::m_fileHistory, COMMON_SETTINGS::m_System, Pgm(), EDA_BASE_FRAME::ReCreateMenuBar(), and FILE_HISTORY::SetMaxFiles().

Referenced by EDA_DRAW_FRAME::CommonSettingsChanged(), EDA_3D_VIEWER::CommonSettingsChanged(), and KIWAY::CommonSettingsChanged().

◆ config()

APP_SETTINGS_BASE * EDA_BASE_FRAME::config ( ) const
virtualinherited

Returns the settings object used in SaveSettings(), and is overloaded in KICAD_MANAGER_FRAME.

Reimplemented in KICAD_MANAGER_FRAME.

Definition at line 543 of file eda_base_frame.cpp.

544 {
545  // KICAD_MANAGER_FRAME overrides this
546  return Kiface().KifaceSettings();
547 }
APP_SETTINGS_BASE * KifaceSettings() const
Definition: kiface_i.h:103
KIFACE_I & Kiface()
Global KIFACE_I "get" accessor.

References Kiface(), and KIFACE_I::KifaceSettings().

Referenced by PCB_BASE_FRAME::ActivateGalCanvas(), GERBVIEW_FRAME::ActivateGalCanvas(), BM2CMP_FRAME::BM2CMP_FRAME(), CVPCB_MAINFRAME::CVPCB_MAINFRAME(), DIALOG_GRID_SETTINGS::DIALOG_GRID_SETTINGS(), SCH_BASE_FRAME::eeconfig(), FOOTPRINT_VIEWER_FRAME::FOOTPRINT_VIEWER_FRAME(), GERBVIEW_FRAME::GERBVIEW_FRAME(), DISPLAY_FOOTPRINTS_FRAME::GetAutoZoom(), GRID_MENU::GRID_MENU(), COMMON_TOOLS::GridFast1(), COMMON_TOOLS::GridFast2(), EDA_DRAW_FRAME::IsGridVisible(), LIB_VIEW_FRAME::LIB_VIEW_FRAME(), SCH_BASE_FRAME::libeditconfig(), SIM_PLOT_FRAME::onClose(), FOOTPRINT_WIZARD_FRAME::OnCloseWindow(), EDA_DRAW_FRAME::OnUpdateSelectGrid(), EDA_DRAW_FRAME::OnUpdateSelectZoom(), PCB_CALCULATOR_FRAME::PCB_CALCULATOR_FRAME(), DISPLAY_FOOTPRINTS_FRAME::SetAutoZoom(), PCB_BASE_EDIT_FRAME::SetBoard(), EDA_DRAW_FRAME::SetGridVisibility(), PL_EDITOR_FRAME::setupTools(), FOOTPRINT_EDIT_FRAME::setupTools(), LIB_VIEW_FRAME::setupTools(), GERBVIEW_FRAME::setupTools(), LIB_EDIT_FRAME::setupTools(), CVPCB_MAINFRAME::setupTools(), SCH_EDIT_FRAME::setupTools(), SIM_PLOT_FRAME::SIM_PLOT_FRAME(), DIALOG_GRID_SETTINGS::TransferDataFromWindow(), DIALOG_GRID_SETTINGS::TransferDataToWindow(), ZOOM_MENU::update(), GRID_MENU::update(), EDA_DRAW_FRAME::UpdateGridSelectBox(), EDA_DRAW_FRAME::UpdateZoomSelectBox(), EDA_BASE_FRAME::windowClosing(), ZOOM_MENU::ZOOM_MENU(), and BM2CMP_FRAME::~BM2CMP_FRAME().

◆ ConfigBaseName()

wxString EDA_BASE_FRAME::ConfigBaseName ( )
inlineoverridevirtualinherited
Returns
a base name prefix used in Load/Save settings to build the full name of keys used in config. This is usually the name of the frame set by CTOR, except for frames shown in multiple modes in which case the m_configName must be set to the base name so that a single config can be used.

Reimplemented from TOOLS_HOLDER.

Definition at line 348 of file eda_base_frame.h.

349  {
350  wxString baseCfgName = m_configName.IsEmpty() ? GetName() : m_configName;
351  return baseCfgName;
352  }
wxString m_configName

References EDA_BASE_FRAME::m_configName.

Referenced by EDA_BASE_FRAME::SaveWindowSettings().

◆ CurrentToolName()

std::string TOOLS_HOLDER::CurrentToolName ( ) const
inherited

Definition at line 99 of file tools_holder.cpp.

100 {
101  if( m_toolStack.empty() )
102  return ACTIONS::selectionTool.GetName();
103  else
104  return m_toolStack.back();
105 }
std::vector< std::string > m_toolStack
Definition: tools_holder.h:52
static TOOL_ACTION selectionTool
Definition: actions.h:147

References TOOLS_HOLDER::m_toolStack, and ACTIONS::selectionTool.

Referenced by TOOL_MANAGER::processEvent().

◆ Destroy()

◆ DismissModal()

void KIWAY_PLAYER::DismissModal ( bool  aRetVal,
const wxString &  aResult = wxEmptyString 
)
inherited

Definition at line 160 of file kiway_player.cpp.

161 {
162  m_modal_ret_val = aRetVal;
163  m_modal_string = aResult;
164 
165  if( m_modal_loop )
166  {
167  m_modal_loop->Exit();
168  m_modal_loop = 0; // this marks it as dismissed.
169  }
170 
171  Show( false );
172 }
bool m_modal_ret_val
Definition: kiway_player.h:205
wxString m_modal_string
Definition: kiway_player.h:204
WX_EVENT_LOOP * m_modal_loop
Definition: kiway_player.h:202

References KIWAY_PLAYER::m_modal_loop, KIWAY_PLAYER::m_modal_ret_val, and KIWAY_PLAYER::m_modal_string.

Referenced by FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), FOOTPRINT_WIZARD_FRAME::ExportSelectedFootprint(), LIB_VIEW_FRAME::FinishModal(), LIB_VIEW_FRAME::OnCloseWindow(), FOOTPRINT_VIEWER_FRAME::OnCloseWindow(), and FOOTPRINT_WIZARD_FRAME::OnCloseWindow().

◆ DisplayToolMsg()

virtual void TOOLS_HOLDER::DisplayToolMsg ( const wxString &  msg)
inlinevirtualinherited

Reimplemented in EDA_DRAW_FRAME.

Definition at line 89 of file tools_holder.h.

89 {};

Referenced by TOOLS_HOLDER::PopTool(), and TOOLS_HOLDER::PushTool().

◆ doAutoSave()

bool EDA_BASE_FRAME::doAutoSave ( )
protectedvirtualinherited

This should be overridden by the derived class to handle the auto save feature.

Returns
true if the auto save was successful otherwise false.

Reimplemented in PCB_EDIT_FRAME, and SCH_EDIT_FRAME.

Definition at line 269 of file eda_base_frame.cpp.

270 {
271  wxCHECK_MSG( false, true, wxT( "Auto save timer function not overridden. Bad programmer!" ) );
272 }

Referenced by EDA_BASE_FRAME::onAutoSaveTimer().

◆ GetAboutTitle()

const wxString& EDA_BASE_FRAME::GetAboutTitle ( ) const
inlineinherited

Definition at line 499 of file eda_base_frame.h.

499 { return m_AboutTitle; }
wxString m_AboutTitle

References EDA_BASE_FRAME::m_AboutTitle.

Referenced by DIALOG_ABOUT::DIALOG_ABOUT(), and COMMON_CONTROL::ReportBug().

◆ GetAutoSaveFilePrefix()

static wxString EDA_BASE_FRAME::GetAutoSaveFilePrefix ( )
inlinestaticprotectedinherited
Returns
the string to prepend to a file name for automatic save.

Definition at line 176 of file eda_base_frame.h.

177  {
178  return wxT( "_autosave-" );
179  }

Referenced by EDA_BASE_FRAME::CheckForAutoSaveFile(), SCH_EDIT_FRAME::doAutoSave(), PCB_EDIT_FRAME::doAutoSave(), PCB_EDIT_FRAME::Files_io_from_id(), SCH_EDIT_FRAME::OnCloseWindow(), PCB_EDIT_FRAME::OnExportSTEP(), SCH_EDIT_FRAME::SaveEEFile(), and PCB_EDIT_FRAME::SavePcbFile().

◆ GetAutoSaveInterval()

int EDA_BASE_FRAME::GetAutoSaveInterval ( ) const
inlineinherited

Definition at line 270 of file eda_base_frame.h.

270 { return m_autoSaveInterval; }

References EDA_BASE_FRAME::m_autoSaveInterval.

◆ GetBackupSuffix()

static wxString EDA_BASE_FRAME::GetBackupSuffix ( )
inlinestaticprotectedinherited
Returns
the suffix to be appended to the file extension on backup

Definition at line 168 of file eda_base_frame.h.

169  {
170  return wxT( "-bak" );
171  }

◆ GetCurrentFileName()

virtual wxString EDA_BASE_FRAME::GetCurrentFileName ( ) const
inlinevirtualinherited

Get the full filename + path of the currently opened file in the frame.

If no file is open, an empty string is returned.

Returns
the filename and full path to the open file

Reimplemented in PCB_EDIT_FRAME, SCH_EDIT_FRAME, PL_EDITOR_FRAME, and KICAD_MANAGER_FRAME.

Definition at line 429 of file eda_base_frame.h.

429 { return wxEmptyString; }

Referenced by EDA_BASE_FRAME::SaveSettings().

◆ GetDoImmediateActions()

bool TOOLS_HOLDER::GetDoImmediateActions ( ) const
inlineinherited

Indicates that hotkeys should perform an immediate action even if another tool is currently active.

If false, the first hotkey should select the relevant tool.

Definition at line 95 of file tools_holder.h.

95 { return m_immediateActions; }
bool m_immediateActions
Definition: tools_holder.h:59

References TOOLS_HOLDER::m_immediateActions.

◆ GetDragSelects()

bool TOOLS_HOLDER::GetDragSelects ( ) const
inlineinherited

Indicates that a drag should draw a selection rectangle, even when started over an item.

Definition at line 101 of file tools_holder.h.

101 { return m_dragSelects; }
bool m_dragSelects
Definition: tools_holder.h:63

References TOOLS_HOLDER::m_dragSelects.

Referenced by EE_SELECTION_TOOL::Main().

◆ GetFileFromHistory()

wxString EDA_BASE_FRAME::GetFileFromHistory ( int  cmdId,
const wxString &  type,
FILE_HISTORY aFileHistory = nullptr 
)
inherited

Fetches the file name from the file history list.

This removes the selected file, if this file does not exist. The menu is also updated, if FILE_HISTORY::UseMenu was called at init time

Parameters
cmdIdThe command ID associated with the aFileHistory object.
typePlease document me!
aFileHistoryThe FILE_HISTORY in use. If null, the main application file history is used
Returns
a wxString containing the selected filename

Definition at line 586 of file eda_base_frame.cpp.

588 {
589  if( !aFileHistory )
590  aFileHistory = m_fileHistory;
591 
592  wxASSERT( aFileHistory );
593 
594  int baseId = aFileHistory->GetBaseId();
595 
596  wxASSERT( cmdId >= baseId && cmdId < baseId + (int) aFileHistory->GetCount() );
597 
598  unsigned i = cmdId - baseId;
599 
600  if( i < aFileHistory->GetCount() )
601  {
602  wxString fn = aFileHistory->GetHistoryFile( i );
603 
604  if( wxFileName::FileExists( fn ) )
605  return fn;
606  else
607  {
608  wxString msg = wxString::Format( _( "File \"%s\" was not found." ), fn );
609  wxMessageBox( msg );
610 
611  aFileHistory->RemoveFileFromHistory( i );
612  }
613  }
614 
615  // Update the menubar to update the file history menu
616  if( GetMenuBar() )
617  {
618  ReCreateMenuBar();
619  GetMenuBar()->Refresh();
620  }
621 
622  return wxEmptyString;
623 }
void Format(OUTPUTFORMATTER *out, int aNestLevel, int aCtl, CPTREE &aTree)
Function Format outputs a PTREE into s-expression format via an OUTPUTFORMATTER derivative.
Definition: ptree.cpp:205
#define _(s)
Definition: 3d_actions.cpp:33
FILE_HISTORY * m_fileHistory
virtual void ReCreateMenuBar()
Recreates the menu bar.

References _, Format(), EDA_BASE_FRAME::m_fileHistory, and EDA_BASE_FRAME::ReCreateMenuBar().

Referenced by GERBVIEW_FRAME::OnDrlFileHistory(), KICAD_MANAGER_FRAME::OnFileHistory(), PL_EDITOR_FRAME::OnFileHistory(), PCB_EDIT_FRAME::OnFileHistory(), GERBVIEW_FRAME::OnGbrFileHistory(), GERBVIEW_FRAME::OnJobFileHistory(), SCH_EDIT_FRAME::OnLoadFile(), and GERBVIEW_FRAME::OnZipFileHistory().

◆ GetFileHistory()

FILE_HISTORY& EDA_BASE_FRAME::GetFileHistory ( )
inlineinherited

◆ GetInfoBar()

WX_INFOBAR* EDA_BASE_FRAME::GetInfoBar ( )
inlineinherited

Definition at line 288 of file eda_base_frame.h.

288 { return m_infoBar; }
WX_INFOBAR * m_infoBar

References EDA_BASE_FRAME::m_infoBar.

Referenced by PAD_TOOL::EditPad(), and SCH_EDIT_TOOL::RefreshSymbolFromLibrary().

◆ GetMaxUndoItems()

int EDA_BASE_FRAME::GetMaxUndoItems ( ) const
inlineinherited

Definition at line 596 of file eda_base_frame.h.

596 { return m_UndoRedoCountMax; }

References EDA_BASE_FRAME::m_UndoRedoCountMax.

Referenced by EDA_DRAW_FRAME::SaveSettings().

◆ GetMoveWarpsCursor()

bool TOOLS_HOLDER::GetMoveWarpsCursor ( ) const
inlineinherited

Indicates that a move operation should warp the mouse pointer to the origin of the move object.

This improves snapping, but some users are alergic to mouse warping.

Definition at line 107 of file tools_holder.h.

107 { return m_moveWarpsCursor; }
bool m_moveWarpsCursor
Definition: tools_holder.h:64

References TOOLS_HOLDER::m_moveWarpsCursor.

Referenced by LIB_MOVE_TOOL::Main(), and SCH_MOVE_TOOL::Main().

◆ GetMruPath()

◆ GetRedoCommandCount()

◆ GetSettingsManager()

◆ GetSeverity()

virtual int EDA_BASE_FRAME::GetSeverity ( int  aErrorCode) const
inlinevirtualinherited

Reimplemented in PCB_BASE_FRAME.

Definition at line 236 of file eda_base_frame.h.

References RPT_SEVERITY_UNDEFINED.

Referenced by RC_TREE_MODEL::GetValue().

◆ GetToolCanvas()

virtual wxWindow* TOOLS_HOLDER::GetToolCanvas ( ) const
pure virtualinherited

◆ GetToolManager()

TOOL_MANAGER* TOOLS_HOLDER::GetToolManager ( ) const
inlineinherited

Return the MVC controller.

Definition at line 74 of file tools_holder.h.

74 { return m_toolManager; }
TOOL_MANAGER * m_toolManager
Definition: tools_holder.h:48

References TOOLS_HOLDER::m_toolManager.

Referenced by DIALOG_GLOBAL_DELETION::AcceptPcbDelete(), TREEPROJECT_ITEM::Activate(), FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), LIB_CONTROL::AddSymbolToSchematic(), BOARD_COMMIT::BOARD_COMMIT(), FOOTPRINT_VIEWER_FRAME::ClickOnFootprintList(), TOOLS_HOLDER::CommonSettingsChanged(), DIALOG_ERC::deleteAllMarkers(), DIALOG_DRC::deleteAllMarkers(), DIALOG_MIGRATE_BUSES::DIALOG_MIGRATE_BUSES(), PL_DRAW_PANEL_GAL::DisplayWorksheet(), DIALOG_CLEANUP_TRACKS_AND_VIAS::doCleanup(), DIALOG_CLEANUP_GRAPHICS::doCleanup(), DRAWING_TOOL::DrawVia(), TRACK_WIDTH_MENU::eventHandler(), DIFF_PAIR_MENU::eventHandler(), SCH_EDIT_FRAME::ExecuteRemoteCommand(), PCB_EDIT_FRAME::ExecuteRemoteCommand(), GERBVIEW_FRAME::GERBVIEW_FRAME(), FP_TREE_SYNCHRONIZING_ADAPTER::GetContextMenuTool(), SYMBOL_TREE_SYNCHRONIZING_ADAPTER::GetContextMenuTool(), PL_EDITOR_FRAME::GetLayoutFromRedoList(), PL_EDITOR_FRAME::GetLayoutFromUndoList(), KICAD_MANAGER_FRAME::InstallPreferences(), PL_EDITOR_FRAME::InstallPreferences(), FOOTPRINT_EDIT_FRAME::InstallPreferences(), LIB_EDIT_FRAME::InstallPreferences(), GERBVIEW_FRAME::InstallPreferences(), PCB_EDIT_FRAME::InstallPreferences(), SCH_EDIT_FRAME::InstallPreferences(), LIB_VIEW_FRAME::LIB_VIEW_FRAME(), LIB_EDIT_FRAME::LoadPart(), PCB_EDIT_FRAME::LoadProjectSettings(), PROPERTIES_FRAME::OnAcceptPrms(), DIALOG_INSPECTOR::onCellClicked(), SIM_PLOT_FRAME::onClose(), SYMBOL_TREE_PANE::onComponentSelected(), DIALOG_DRC::OnDeleteOneClick(), DIALOG_DRC::OnDRCItemRClick(), DIALOG_ERC::OnERCItemSelected(), FOOTPRINTS_LISTBOX::OnLeftDClick(), SIM_PLOT_FRAME::onProbe(), DIALOG_PLOT::onRunDRC(), HIERARCHY_NAVIG_DLG::onSelectSheetPath(), DIALOG_FIELDS_EDITOR_GLOBAL::OnTableCellClick(), SIM_PLOT_FRAME::onTune(), PANEL_SELECTION_FILTER::PANEL_SELECTION_FILTER(), DIALOG_PLOT::Plot(), TOOLS_HOLDER::PopTool(), SCH_EDIT_FRAME::PutDataInPreviousState(), PL_EDITOR_FRAME::RollbackFromUndo(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), PCB_EDIT_FRAME::SaveProjectSettings(), EDA_3D_VIEWER::SaveSettings(), DIALOG_FIND::search(), CVPCB_MAINFRAME::setupEventHandlers(), PCB_LAYER_WIDGET::SyncLayerAlphaIndicators(), DIALOG_GRID_SETTINGS::TransferDataFromWindow(), DIALOG_3D_VIEW_OPTIONS::TransferDataFromWindow(), DIALOG_LIB_EDIT_TEXT::TransferDataFromWindow(), PANEL_SETUP_RULES::TransferDataFromWindow(), DIALOG_FIELDS_EDITOR_GLOBAL::TransferDataToWindow(), DIALOG_LIB_EDIT_TEXT::TransferDataToWindow(), DIALOG_3D_VIEW_OPTIONS::TransferDataToWindow(), DIALOG_GLOBAL_EDIT_TRACKS_AND_VIAS::TransferDataToWindow(), DIALOG_GLOBAL_EDIT_TEXT_AND_GRAPHICS::TransferDataToWindow(), EDA_DRAW_FRAME::UpdateMsgPanel(), DIALOG_NETLIST::~DIALOG_NETLIST(), and DIALOG_UPDATE_PCB::~DIALOG_UPDATE_PCB().

◆ GetType()

HOLDER_TYPE KIWAY_HOLDER::GetType ( )
inlineinherited

Definition at line 49 of file kiway_holder.h.

49 { return m_type; }
HOLDER_TYPE m_type
Definition: kiway_holder.h:82

References KIWAY_HOLDER::m_type.

Referenced by DIALOG_SHIM::DIALOG_SHIM().

◆ GetUndoCommandCount()

◆ GetUserUnits()

EDA_UNITS EDA_BASE_FRAME::GetUserUnits ( ) const
inlineinherited

Return the user units currently in use.

Definition at line 220 of file eda_base_frame.h.

221  {
222  return m_userUnits;
223  }
EDA_UNITS m_userUnits

References EDA_BASE_FRAME::m_userUnits.

Referenced by PANEL_SETUP_TRACKS_AND_VIAS::AppendDiffPairs(), PANEL_SETUP_TRACKS_AND_VIAS::AppendTrackWidth(), PANEL_SETUP_TRACKS_AND_VIAS::AppendViaSize(), MICROWAVE_TOOL::createFootprint(), MICROWAVE_TOOL::createMicrowaveInductor(), GERBVIEW_SELECTION_TOOL::disambiguationMenu(), GERBER_FILE_IMAGE::DisplayImageInfo(), PL_SELECTION_TOOL::doSelectionMenu(), EE_SELECTION_TOOL::doSelectionMenu(), SELECTION_TOOL::doSelectionMenu(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::drawSegment(), EVT_GRID_CMD_CELL_CHANGED(), PCB_EDIT_FRAME::GenFootprintsReport(), PANEL_MODEDIT_DEFAULTS::getGridValue(), PANEL_SETUP_TEXT_AND_GRAPHICS::getGridValue(), LIB_CIRCLE::GetMsgPanelInfo(), LIB_RECTANGLE::GetMsgPanelInfo(), LIB_TEXT::GetMsgPanelInfo(), LIB_ARC::GetMsgPanelInfo(), LIB_POLYLINE::GetMsgPanelInfo(), MARKER_PCB::GetMsgPanelInfo(), LIB_BEZIER::GetMsgPanelInfo(), TEXTE_PCB::GetMsgPanelInfo(), ZONE_CONTAINER::GetMsgPanelInfo(), WS_DRAW_ITEM_BASE::GetMsgPanelInfo(), SCH_BITMAP::GetMsgPanelInfo(), LIB_FIELD::GetMsgPanelInfo(), TRACK::GetMsgPanelInfo(), TEXTE_MODULE::GetMsgPanelInfo(), LIB_PIN::GetMsgPanelInfo(), DRAWSEGMENT::GetMsgPanelInfo(), NETINFO_ITEM::GetMsgPanelInfo(), SCH_TEXT::GetMsgPanelInfo(), VIA::GetMsgPanelInfo(), D_PAD::GetMsgPanelInfo(), LIB_PIN::getMsgPanelInfoBase(), GetUserUnits(), RC_TREE_MODEL::GetValue(), GRID_MENU::GRID_MENU(), GERBVIEW_FRAME::Liste_D_Codes(), PCB_VIEWER_TOOLS::MeasureTool(), GERBVIEW_SELECTION_TOOL::MeasureTool(), PANEL_SETUP_BOARD_STACKUP::onThicknessChange(), DIALOG_SELECT_NET_FROM_LIST::onUnitsChanged(), UNIT_BINDER::onUnitsChanged(), PANEL_SETUP_BOARD_STACKUP::onUpdateThicknessValue(), PANEL_PREV_3D::PANEL_PREV_3D(), PANEL_SETUP_BOARD_STACKUP::PANEL_SETUP_BOARD_STACKUP(), POSITION_RELATIVE_TOOL::PositionRelative(), FOOTPRINT_EDIT_FRAME::ReCreateMenuBar(), LIB_EDIT_FRAME::ReCreateMenuBar(), SCH_EDIT_FRAME::ReCreateMenuBar(), GERBVIEW_FRAME::ReCreateMenuBar(), PCB_EDIT_FRAME::ReCreateMenuBar(), DRC_ITEM::ShowHtml(), DISPLAY_FOOTPRINTS_FRAME::SyncToolbars(), FOOTPRINT_VIEWER_FRAME::SyncToolbars(), FOOTPRINT_EDIT_FRAME::SyncToolbars(), LIB_EDIT_FRAME::SyncToolbars(), GERBVIEW_FRAME::SyncToolbars(), PCB_EDIT_FRAME::SyncToolbars(), SCH_EDIT_FRAME::SyncToolbars(), COMMON_TOOLS::ToggleUnits(), PANEL_SETUP_BOARD_STACKUP::transferDataFromUIToStackup(), PANEL_SETUP_TRACKS_AND_VIAS::TransferDataFromWindow(), PANEL_EESCHEMA_SETTINGS::TransferDataToWindow(), PANEL_GERBVIEW_SETTINGS::TransferDataToWindow(), PANEL_EDIT_OPTIONS::TransferDataToWindow(), UNIT_BINDER::UNIT_BINDER(), GRID_MENU::update(), TRACK_WIDTH_MENU::update(), DIFF_PAIR_MENU::update(), GERBVIEW_FRAME::updateDCodeSelectBox(), EDA_DRAW_FRAME::UpdateGridSelectBox(), PNS_TUNE_STATUS_POPUP::UpdateStatus(), PL_EDITOR_FRAME::UpdateStatusBar(), SCH_BASE_FRAME::UpdateStatusBar(), PCB_BASE_FRAME::UpdateStatusBar(), GERBVIEW_FRAME::UpdateStatusBar(), PCB_EDIT_FRAME::UpdateTrackWidthSelectBox(), PCB_EDIT_FRAME::UpdateViaSizeSelectBox(), DRC::userUnits(), userUnits(), and PANEL_SETUP_TRACKS_AND_VIAS::validateData().

◆ GetWindowSettings()

WINDOW_SETTINGS * EDA_BASE_FRAME::GetWindowSettings ( APP_SETTINGS_BASE aCfg)
virtualinherited

Returns a pointer to the window settings for this frame.

By default, points to aCfg->m_Window for top-level frames.

Parameters
aCfgis this frame's config object

Reimplemented in SIM_PLOT_FRAME, FOOTPRINT_WIZARD_FRAME, FOOTPRINT_VIEWER_FRAME, LIB_VIEW_FRAME, and DISPLAY_FOOTPRINTS_FRAME.

Definition at line 537 of file eda_base_frame.cpp.

538 {
539  return &aCfg->m_Window;
540 }
WINDOW_SETTINGS m_Window
Definition: app_settings.h:154

References APP_SETTINGS_BASE::m_Window.

Referenced by EDA_BASE_FRAME::LoadSettings(), EDA_DRAW_FRAME::LoadSettings(), EDA_BASE_FRAME::SaveSettings(), and EDA_DRAW_FRAME::SaveSettings().

◆ GetWindowSize()

wxSize EDA_BASE_FRAME::GetWindowSize ( )
inherited

Get the undecorated window size that can be used for restoring the window size.

This is needed for GTK, since the normal wxWidgets GetSize() call will return a window size that includes the window decorations added by the window manager.

Returns
the undecorated window size

Definition at line 863 of file eda_base_frame.cpp.

864 {
865 #ifdef __WXGTK__
866  // GTK includes the window decorations in the normal GetSize call,
867  // so we have to use a GTK-specific sizing call that returns the
868  // non-decorated window size.
869  int width = 0;
870  int height = 0;
871  GTKDoGetSize( &width, &height );
872 
873  wxSize winSize( width, height );
874 #else
875  wxSize winSize = GetSize();
876 #endif
877 
878  return winSize;
879 }

Referenced by EDA_BASE_FRAME::OnMaximize(), and EDA_BASE_FRAME::SaveWindowSettings().

◆ help_name()

wxString EDA_BASE_FRAME::help_name ( )
virtualinherited

Reimplemented in KICAD_MANAGER_FRAME.

Definition at line 556 of file eda_base_frame.cpp.

557 {
558  return Kiface().GetHelpFileName();
559 }
const wxString & GetHelpFileName() const
Function GetHelpFileName returns just the basename portion of the current help file.
Definition: kiface_i.h:123
KIFACE_I & Kiface()
Global KIFACE_I "get" accessor.

References KIFACE_I::GetHelpFileName(), and Kiface().

Referenced by COMMON_CONTROL::ShowHelp().

◆ ImportHotkeyConfigFromFile()

void EDA_BASE_FRAME::ImportHotkeyConfigFromFile ( std::map< std::string, TOOL_ACTION * >  aActionMap,
const wxString &  aDefaultShortname 
)
inherited

Prompt the user for a hotkey file to read, and read it.

Parameters
aActionMap= current hotkey map (over which the imported hotkeys will be applied)
aDefaultShortname= a default short name (extension not needed) like eechema, kicad...

◆ InstallPreferences()

virtual void EDA_BASE_FRAME::InstallPreferences ( PAGED_DIALOG ,
PANEL_HOTKEYS_EDITOR  
)
inlinevirtualinherited

Function InstallPreferences Allow a frame to load its preference panels (if any) into the preferences dialog.

Parameters
aParenta paged dialog into which the preference panels should be installed

Reimplemented in SCH_EDIT_FRAME, PCB_EDIT_FRAME, GERBVIEW_FRAME, LIB_EDIT_FRAME, FOOTPRINT_EDIT_FRAME, PL_EDITOR_FRAME, and KICAD_MANAGER_FRAME.

Definition at line 301 of file eda_base_frame.h.

301 { }

Referenced by EDA_BASE_FRAME::OnPreferences().

◆ isAutoSaveRequired()

virtual bool EDA_BASE_FRAME::isAutoSaveRequired ( ) const
inlineprotectedvirtualinherited

Return the auto save status of the application.

Override this function if your derived frame supports automatic file saving.

Reimplemented in PCB_EDIT_FRAME, and SCH_EDIT_FRAME.

Definition at line 191 of file eda_base_frame.h.

191 { return false; }

Referenced by EDA_BASE_FRAME::ProcessEvent().

◆ IsContentModified()

bool EDA_BASE_FRAME::IsContentModified ( )
virtualinherited

Get if the contents of the frame have been modified since the last save.

Returns
true if the contents of the frame have not been saved

Reimplemented in PCB_EDIT_FRAME, SCH_EDIT_FRAME, CVPCB_MAINFRAME, LIB_EDIT_FRAME, PL_EDITOR_FRAME, and FOOTPRINT_EDIT_FRAME.

Definition at line 775 of file eda_base_frame.cpp.

776 {
777  // This function should be overridden in child classes
778  return false;
779 }

◆ IsCurrentTool()

bool TOOLS_HOLDER::IsCurrentTool ( const TOOL_ACTION aAction) const
inherited

Definition at line 108 of file tools_holder.cpp.

109 {
110  if( m_toolStack.empty() )
111  return &aAction == &ACTIONS::selectionTool;
112  else
113  return m_toolStack.back() == aAction.GetName();
114 }
std::vector< std::string > m_toolStack
Definition: tools_holder.h:52
static TOOL_ACTION selectionTool
Definition: actions.h:147
const std::string & GetName() const
Function GetName() Returns name of the action.
Definition: tool_action.h:78

References TOOL_ACTION::GetName(), TOOLS_HOLDER::m_toolStack, and ACTIONS::selectionTool.

Referenced by PCB_INSPECTION_TOOL::HighlightNetTool(), SCH_EDIT_TOOL::Init(), PCB_EDITOR_CONTROL::Init(), SCH_LINE_WIRE_BUS_TOOL::Init(), EDIT_TOOL::Init(), DISPLAY_FOOTPRINTS_FRAME::SyncToolbars(), FOOTPRINT_VIEWER_FRAME::SyncToolbars(), and LIB_EDIT_FRAME::SyncToolbars().

◆ IsDismissed()

bool KIWAY_PLAYER::IsDismissed ( )
inherited

Function IsDismissed returns false only if both the frame is acting in modal mode and it has not been dismissed yet with DismissModal().

IOW, it will return true if the dialog is not modal or if it is modal and has been dismissed.

Definition at line 154 of file kiway_player.cpp.

155 {
156  return !m_modal_loop;
157 }
WX_EVENT_LOOP * m_modal_loop
Definition: kiway_player.h:202

References KIWAY_PLAYER::m_modal_loop.

Referenced by LIB_VIEW_FRAME::OnCloseWindow(), FOOTPRINT_VIEWER_FRAME::OnCloseWindow(), and FOOTPRINT_WIZARD_FRAME::OnCloseWindow().

◆ IsModal()

◆ IsType()

bool EDA_BASE_FRAME::IsType ( FRAME_T  aType) const
inlineinherited

Definition at line 272 of file eda_base_frame.h.

272 { return m_Ident == aType; }

References EDA_BASE_FRAME::m_Ident.

Referenced by LIB_CONTROL::AddLibrary(), PCBNEW_CONTROL::AddLibrary(), LIB_CONTROL::AddSymbol(), ALIGN_DISTRIBUTE_TOOL::AlignBottom(), ALIGN_DISTRIBUTE_TOOL::AlignCenterX(), ALIGN_DISTRIBUTE_TOOL::AlignCenterY(), ALIGN_DISTRIBUTE_TOOL::AlignTop(), BOARD_COMMIT::BOARD_COMMIT(), EDA_3D_VIEWER::CreateMenuBar(), LIB_CONTROL::CutCopyDelete(), DIALOG_GRID_SETTINGS::DIALOG_GRID_SETTINGS(), DIALOG_KEEPOUT_AREA_PROPERTIES::DIALOG_KEEPOUT_AREA_PROPERTIES(), DIALOG_MOVE_EXACT::DIALOG_MOVE_EXACT(), DIALOG_PUSH_PAD_PROPERTIES::DIALOG_PUSH_PAD_PROPERTIES(), KIGFX::SCH_VIEW::DisplaySheet(), ALIGN_DISTRIBUTE_TOOL::doAlignLeft(), ALIGN_DISTRIBUTE_TOOL::doAlignRight(), ALIGN_DISTRIBUTE_TOOL::doDistributeCentersHorizontally(), ALIGN_DISTRIBUTE_TOOL::doDistributeCentersVertically(), ALIGN_DISTRIBUTE_TOOL::doDistributeGapsHorizontally(), ALIGN_DISTRIBUTE_TOOL::doDistributeGapsVertically(), LIB_CONTROL::DuplicateSymbol(), LIB_CONTROL::EditSymbol(), LIB_CONTROL::ExportSymbol(), MODULE::GetMsgPanelInfo(), LIB_CONTROL::Init(), DIALOG_EDIT_ONE_FIELD::init(), SELECTION_TOOL::Init(), DIALOG_PAD_PROPERTIES::initValues(), PICKER_TOOL::Main(), LIB_CONTROL::OnDeMorgan(), PCB_LAYER_WIDGET::OnLayerVisible(), PCB_LAYER_WIDGET::OnRenderEnable(), PCBNEW_CONTROL::Paste(), LIB_CONTROL::PinLibrary(), POSITION_RELATIVE_TOOL::RelativeItemSelectionMove(), LIB_CONTROL::Revert(), EE_INSPECTION_TOOL::RunERC(), LIB_CONTROL::Save(), LIB_CONTROL::ShowComponentTree(), EE_INSPECTION_TOOL::ShowDatasheet(), LIB_CONTROL::UnpinLibrary(), and COMMON_TOOLS::ZoomFitScreen().

◆ IsWritable()

bool EDA_BASE_FRAME::IsWritable ( const wxFileName &  aFileName)
inherited

Checks if aFileName can be written.

The function performs a number of tests on aFileName to verify that it can be saved. If aFileName defines a path with no file name, them the path is tested for user write permission. If aFileName defines a file name that does not exist in the path, the path is tested for user write permission. If aFileName defines a file that already exits, the file name is tested for user write permissions.

Note
The file name path must be set or an assertion will be raised on debug builds and return false on release builds.
Parameters
aFileNameThe full path and/or file name of the file to test.
Returns
False if aFileName cannot be written.

Definition at line 685 of file eda_base_frame.cpp.

686 {
687  wxString msg;
688  wxFileName fn = aFileName;
689 
690  // Check for absence of a file path with a file name. Unfortunately KiCad
691  // uses paths relative to the current project path without the ./ part which
692  // confuses wxFileName. Making the file name path absolute may be less than
693  // elegant but it solves the problem.
694  if( fn.GetPath().IsEmpty() && fn.HasName() )
695  fn.MakeAbsolute();
696 
697  wxCHECK_MSG( fn.IsOk(), false,
698  wxT( "File name object is invalid. Bad programmer!" ) );
699  wxCHECK_MSG( !fn.GetPath().IsEmpty(), false,
700  wxT( "File name object path <" ) + fn.GetFullPath() +
701  wxT( "> is not set. Bad programmer!" ) );
702 
703  if( fn.IsDir() && !fn.IsDirWritable() )
704  {
705  msg.Printf( _( "You do not have write permissions to folder \"%s\"." ),
706  GetChars( fn.GetPath() ) );
707  }
708  else if( !fn.FileExists() && !fn.IsDirWritable() )
709  {
710  msg.Printf( _( "You do not have write permissions to save file \"%s\" to folder \"%s\"." ),
711  GetChars( fn.GetFullName() ), GetChars( fn.GetPath() ) );
712  }
713  else if( fn.FileExists() && !fn.IsFileWritable() )
714  {
715  msg.Printf( _( "You do not have write permissions to save file \"%s\"." ),
716  GetChars( fn.GetFullPath() ) );
717  }
718 
719  if( !msg.IsEmpty() )
720  {
721  wxMessageBox( msg );
722  return false;
723  }
724 
725  return true;
726 }
static const wxChar * GetChars(const wxString &s)
Function GetChars returns a wxChar* to the actual wxChar* data within a wxString, and is helpful for ...
Definition: macros.h:153
#define _(s)
Definition: 3d_actions.cpp:33

References _, and GetChars().

Referenced by SCH_EDIT_FRAME::doAutoSave(), SCH_EDIT_FRAME::SaveEEFile(), PCB_EDIT_FRAME::SavePcbCopy(), PCB_EDIT_FRAME::SavePcbFile(), and SCH_EDIT_FRAME::SaveProjectSettings().

◆ Kiway()

KIWAY& KIWAY_HOLDER::Kiway ( ) const
inlineinherited

Function Kiway returns a reference to the KIWAY that this object has an opportunity to participate in.

A KIWAY_HOLDER is not necessarily a KIWAY_PLAYER.

Definition at line 56 of file kiway_holder.h.

57  {
58  wxASSERT( m_kiway ); // smoke out bugs in Debug build, then Release runs fine.
59  return *m_kiway;
60  }
KIWAY * m_kiway
Definition: kiway_holder.h:81

References KIWAY_HOLDER::m_kiway.

Referenced by TREEPROJECT_ITEM::Activate(), FOOTPRINT_VIEWER_FRAME::AddFootprintToPCB(), PCB_BASE_EDIT_FRAME::AddLibrary(), LIB_CONTROL::AddSymbolToSchematic(), CVPCB_MAINFRAME::BuildLIBRARY_LISTBOX(), COMMON_CONTROL::ConfigurePaths(), DIALOG_CHOOSE_FOOTPRINT::ConstructRightPanel(), DIALOG_CHOOSE_COMPONENT::ConstructRightPanel(), PCB_BASE_FRAME::CreateAndShow3D_Frame(), CVPCB_MAINFRAME::CVPCB_MAINFRAME(), DIALOG_RESCUE_EACH::DIALOG_RESCUE_EACH(), DIALOG_SHIM::DIALOG_SHIM(), CVPCB_MAINFRAME::DisplayStatus(), FIELDS_GRID_TRICKS::doPopupSelection(), FIELDS_EDITOR_GRID_TRICKS::doPopupSelection(), PCB_EDITOR_CONTROL::EditFpInFpEditor(), SCH_EDITOR_CONTROL::EditWithLibEdit(), BACK_ANNOTATE::FetchNetlistFromPCB(), DISPLAY_FOOTPRINTS_FRAME::GetModule(), PCB_EDIT_FRAME::importFile(), KICAD_MANAGER_FRAME::language_change(), KIWAY_PLAYER::language_change(), LIB_TREE_MODEL_ADAPTER::LIB_TREE_MODEL_ADAPTER(), CVPCB_MAINFRAME::LoadFootprintFiles(), KICAD_MANAGER_FRAME::LoadProject(), TEXT_BUTTON_SYMBOL_CHOOSER::OnButtonClick(), TEXT_BUTTON_FP_CHOOSER::OnButtonClick(), KICAD_MANAGER_FRAME::OnCloseWindow(), SCH_EDIT_FRAME::OnCloseWindow(), PL_EDITOR_FRAME::OnExit(), SCH_EDIT_FRAME::OnExit(), FOOTPRINT_EDIT_FRAME::OnExitKiCad(), FOOTPRINT_VIEWER_FRAME::OnExitKiCad(), LIB_EDIT_FRAME::OnExitKiCad(), SAVE_AS_TRAVERSER::OnFile(), KICAD_MANAGER_FRAME::OnImportEagleFiles(), DIALOG_CHOOSE_COMPONENT::OnInitDialog(), SCH_EDIT_FRAME::OnOpenCvpcb(), SCH_EDIT_FRAME::OnOpenPcbnew(), EDA_BASE_FRAME::OnPreferences(), DIALOG_SYMBOL_REMAP::OnRemapSymbols(), DIALOG_EDIT_ONE_FIELD::OnTextValueSelectButtonClick(), KICAD_MANAGER_FRAME::OnUnarchiveFiles(), FOOTPRINT_EDIT_FRAME::OnUpdateInsertModuleInBoard(), FOOTPRINT_EDIT_FRAME::OnUpdateLoadModuleFromBoard(), SCH_EDIT_FRAME::OnUpdatePCB(), KIWAY_HOLDER::Prj(), BACK_ANNOTATE::PushNewLinksToPCB(), CVPCB_MAINFRAME::ReadNetListAndFpFiles(), FOOTPRINT_VIEWER_FRAME::ReCreateFootprintList(), LIB_EDIT_FRAME::refreshSchematic(), SCH_EDITOR_CONTROL::rescueProject(), EE_INSPECTION_TOOL::RunSimulation(), CVPCB_MAINFRAME::SaveFootprintAssociation(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), LIB_TREE_MODEL_ADAPTER::SavePinnedItems(), SCH_BASE_FRAME::SelectComponentFromLibBrowser(), SCH_EDIT_FRAME::SendCrossProbeClearHighlight(), SCH_EDIT_FRAME::SendCrossProbeNetName(), PCB_EDIT_FRAME::SendCrossProbeNetName(), CVPCB_MAINFRAME::SendMessageToEESCHEMA(), PCB_EDIT_FRAME::SendMessageToEESCHEMA(), SCH_EDIT_FRAME::SendMessageToPCBNEW(), SCH_EDIT_FRAME::sendNetlistToCvpcb(), SCH_EDIT_FRAME::SetCrossProbeConnection(), CVPCB_CONTROL::ShowFootprintViewer(), COMMON_CONTROL::ShowLibraryTable(), COMMON_CONTROL::ShowPlayer(), KICAD_MANAGER_CONTROL::ShowPlayer(), SCH_EDIT_FRAME::ShowSchematicSetupDialog(), SIM_PLOT_FRAME::SIM_PLOT_FRAME(), PCB_EDITOR_CONTROL::UpdateSchematicFromPCB(), and DIALOG_EXCHANGE_FOOTPRINTS::ViewAndSelectFootprint().

◆ kiway_express()

void KIWAY_PLAYER::kiway_express ( KIWAY_EXPRESS aEvent)
protectedinherited

event handler, routes to derivative specific virtual KiwayMailIn()

Definition at line 175 of file kiway_player.cpp.

176 {
177  // logging support
178  KiwayMailIn( aEvent ); // call the virtual, override in derived.
179 }
virtual void KiwayMailIn(KIWAY_EXPRESS &aEvent)
Function KiwayMailIn receives KIWAY_EXPRESS messages from other players.

References KIWAY_PLAYER::KiwayMailIn().

◆ KiwayMailIn()

void KIWAY_PLAYER::KiwayMailIn ( KIWAY_EXPRESS aEvent)
virtualinherited

Function KiwayMailIn receives KIWAY_EXPRESS messages from other players.

Merely override it in derived classes.

Reimplemented in LIB_EDIT_FRAME, FOOTPRINT_EDIT_FRAME, PCB_EDIT_FRAME, SCH_EDIT_FRAME, and CVPCB_MAINFRAME.

Definition at line 69 of file kiway_player.cpp.

70 {
71  // override this in derived classes.
72 }

Referenced by KIWAY_PLAYER::kiway_express(), and KIWAY::ProcessEvent().

◆ language_change()

void KIWAY_PLAYER::language_change ( wxCommandEvent &  event)
protectedinherited

Function language_change is an event handler called on a language menu selection.

Definition at line 182 of file kiway_player.cpp.

183 {
184  int id = event.GetId();
185 
186  // tell all the KIWAY_PLAYERs about the language change.
187  Kiway().SetLanguage( id );
188 }
KIWAY & Kiway() const
Function Kiway returns a reference to the KIWAY that this object has an opportunity to participate in...
Definition: kiway_holder.h:56
VTBL_ENTRY void SetLanguage(int aLanguage)
Function SetLanguage changes the language and then calls ShowChangedLanguage() on all KIWAY_PLAYERs.
Definition: kiway.cpp:440

References KIWAY_HOLDER::Kiway(), and KIWAY::SetLanguage().

◆ LoadSettings()

void EDA_BASE_FRAME::LoadSettings ( APP_SETTINGS_BASE aCfg)
virtualinherited

Load common frame parameters from a configuration file.

Don't forget to call the base method or your frames won't remember their positions and sizes.

Reimplemented in EDA_DRAW_FRAME, GERBVIEW_FRAME, PCB_EDIT_FRAME, PCB_BASE_FRAME, CVPCB_MAINFRAME, LIB_EDIT_FRAME, SCH_EDIT_FRAME, SIM_PLOT_FRAME, PL_EDITOR_FRAME, FOOTPRINT_WIZARD_FRAME, EDA_3D_VIEWER, BM2CMP_FRAME, KICAD_MANAGER_FRAME, FOOTPRINT_VIEWER_FRAME, SCH_BASE_FRAME, LIB_VIEW_FRAME, PCB_CALCULATOR_FRAME, FOOTPRINT_EDIT_FRAME, and DISPLAY_FOOTPRINTS_FRAME.

Definition at line 505 of file eda_base_frame.cpp.

506 {
508 
509  // Get file history size from common settings
510  int fileHistorySize = Pgm().GetCommonSettings()->m_System.file_history_size;
511 
512  // Load the recently used files into the history menu
513  m_fileHistory = new FILE_HISTORY( (unsigned) std::max( 0, fileHistorySize ),
515  m_fileHistory->Load( *aCfg );
516 }
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:104
void Load(const APP_SETTINGS_BASE &aSettings)
Loads history from a JSON settings object.
Definition: filehistory.cpp:45
This class implements a file history object to store a list of files, that can then be added to a men...
Definition: filehistory.h:42
virtual WINDOW_SETTINGS * GetWindowSettings(APP_SETTINGS_BASE *aCfg)
Returns a pointer to the window settings for this frame.
void LoadWindowSettings(WINDOW_SETTINGS *aCfg)
Loads window settings from the given settings object Normally called by LoadSettings unless the windo...
Definition: id.h:87
FILE_HISTORY * m_fileHistory

References EDA_BASE_FRAME::GetWindowSettings(), ID_FILE1, ID_FILE_LIST_CLEAR, FILE_HISTORY::Load(), EDA_BASE_FRAME::LoadWindowSettings(), EDA_BASE_FRAME::m_fileHistory, and Pgm().

Referenced by PCB_CALCULATOR_FRAME::LoadSettings(), KICAD_MANAGER_FRAME::LoadSettings(), BM2CMP_FRAME::LoadSettings(), EDA_3D_VIEWER::LoadSettings(), SIM_PLOT_FRAME::LoadSettings(), CVPCB_MAINFRAME::LoadSettings(), and EDA_DRAW_FRAME::LoadSettings().

◆ LoadWindowSettings()

void EDA_BASE_FRAME::LoadWindowSettings ( WINDOW_SETTINGS aCfg)
inherited

Loads window settings from the given settings object Normally called by LoadSettings unless the window in question is a child window that stores its settings somewhere other than APP_SETTINGS_BASE::m_Window.

Definition at line 349 of file eda_base_frame.cpp.

350 {
351  m_FramePos.x = aCfg->pos_x;
352  m_FramePos.y = aCfg->pos_y;
353  m_FrameSize.x = aCfg->size_x;
354  m_FrameSize.y = aCfg->size_y;
355 
356  wxLogTrace( traceDisplayLocation, "Config position (%d, %d) with size (%d, %d)",
358 
359  // Ensure minimum size is set if the stored config was zero-initialized
361  {
364 
365  wxLogTrace( traceDisplayLocation, "Using minimum size (%d, %d)", m_FrameSize.x, m_FrameSize.y );
366  }
367 
368  wxLogTrace( traceDisplayLocation, "Number of displays: %d", wxDisplay::GetCount() );
369 
370  if( aCfg->display >= wxDisplay::GetCount() )
371  {
372  wxLogTrace( traceDisplayLocation, "Previous display not found" );
373 
374  // If it isn't attached, use the first display
375  // Warning wxDisplay has 2 ctor variants. the parameter needs a type:
376  const unsigned int index = 0;
377  wxDisplay display( index );
378  wxRect clientSize = display.GetClientArea();
379 
380  wxLogDebug( "Client size (%d, %d)", clientSize.width, clientSize.height );
381 
382  m_FramePos = wxDefaultPosition;
383 
384  // Ensure the window fits on the display, since the other one could have been larger
385  if( m_FrameSize.x > clientSize.width )
386  m_FrameSize.x = clientSize.width;
387 
388  if( m_FrameSize.y > clientSize.height )
389  m_FrameSize.y = clientSize.height;
390  }
391  else
392  {
393  wxPoint upperRight( m_FramePos.x + m_FrameSize.x, m_FramePos.y );
394  wxPoint upperLeft( m_FramePos.x, m_FramePos.y );
395 
396  wxDisplay display( aCfg->display );
397  wxRect clientSize = display.GetClientArea();
398 
399 // The percentage size (represented in decimal) of the region around the screen's border where
400 // an upper corner is not allowed
401 #define SCREEN_BORDER_REGION 0.10
402 
403  int yLim = clientSize.y + ( clientSize.height * ( 1.0 - SCREEN_BORDER_REGION ) );
404  int xLimLeft = clientSize.x + ( clientSize.width * SCREEN_BORDER_REGION );
405  int xLimRight = clientSize.x + ( clientSize.width * ( 1.0 - SCREEN_BORDER_REGION ) );
406 
407  if( upperLeft.x > xLimRight || // Upper left corner too close to right edge of screen
408  upperRight.x < xLimLeft || // Upper right corner too close to left edge of screen
409  upperRight.y > yLim ) // Upper corner too close to the bottom of the screen
410  {
411  m_FramePos = wxDefaultPosition;
412  wxLogTrace( traceDisplayLocation, "Resetting to default position" );
413  }
414  }
415 
416  // Ensure Window title bar is visible
417 #if defined( __WXOSX__ )
418  // for macOSX, the window must be below system (macOSX) toolbar
419  int Ypos_min = 20;
420 #else
421  int Ypos_min = 0;
422 #endif
423  if( m_FramePos.y < Ypos_min )
424  m_FramePos.y = Ypos_min;
425 
426  wxLogTrace( traceDisplayLocation, "Final window position (%d, %d) with size (%d, %d)",
428 
429  SetSize( m_FramePos.x, m_FramePos.y, m_FrameSize.x, m_FrameSize.y );
430 
431  // Center the window if we reset to default
432  if( m_FramePos.x == -1 )
433  {
434  wxLogTrace( traceDisplayLocation, "Centering window" );
435  Center();
436  m_FramePos = GetPosition();
437  }
438 
439  // Record the frame sizes in an un-maximized state
442 
443  // Maximize if we were maximized before
444  if( aCfg->maximized )
445  {
446  wxLogTrace( traceDisplayLocation, "Maximizing window" );
447  Maximize();
448  }
449 
450  if( m_hasAutoSave )
451  m_autoSaveInterval = Pgm().GetCommonSettings()->m_System.autosave_interval;
452 
453  m_perspective = aCfg->perspective;
454  m_mruPath = aCfg->mru_path;
455 
456  TOOLS_HOLDER::CommonSettingsChanged( false, false );
457 }
wxString mru_path
Definition: app_settings.h:71
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:104
wxString m_mruPath
const wxChar *const traceDisplayLocation
Flag to enable debug output of display positioning logic.
wxString m_perspective
wxSize m_NormalFrameSize
#define SCREEN_BORDER_REGION
wxString perspective
Definition: app_settings.h:74
virtual void CommonSettingsChanged(bool aEnvVarsChanged, bool aTextVarsChanged)
Notification event that some of the common (suite-wide) settings have changed.
static const int s_minsize_x
static const int s_minsize_y
wxPoint m_NormalFramePos
unsigned int display
Definition: app_settings.h:77

References PCAD2KICAD::Center, TOOLS_HOLDER::CommonSettingsChanged(), WINDOW_SETTINGS::display, EDA_BASE_FRAME::m_autoSaveInterval, EDA_BASE_FRAME::m_FramePos, EDA_BASE_FRAME::m_FrameSize, EDA_BASE_FRAME::m_hasAutoSave, EDA_BASE_FRAME::m_mruPath, EDA_BASE_FRAME::m_NormalFramePos, EDA_BASE_FRAME::m_NormalFrameSize, EDA_BASE_FRAME::m_perspective, WINDOW_SETTINGS::maximized, WINDOW_SETTINGS::mru_path, WINDOW_SETTINGS::perspective, Pgm(), WINDOW_SETTINGS::pos_x, WINDOW_SETTINGS::pos_y, s_minsize_x, s_minsize_y, SCREEN_BORDER_REGION, WINDOW_SETTINGS::size_x, WINDOW_SETTINGS::size_y, traceDisplayLocation, wxPoint::x, and wxPoint::y.

Referenced by EDA_BASE_FRAME::LoadSettings().

◆ m_splitterLeftRightOnIdle()

void SIM_PLOT_FRAME_BASE::m_splitterLeftRightOnIdle ( wxIdleEvent &  )
inline

Definition at line 123 of file sim_plot_frame_base.h.

124  {
125  m_splitterLeftRight->SetSashPosition( 700 );
126  m_splitterLeftRight->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterLeftRightOnIdle ), NULL, this );
127  }
void m_splitterLeftRightOnIdle(wxIdleEvent &)
#define NULL
wxSplitterWindow * m_splitterLeftRight

References m_splitterLeftRight, and NULL.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_splitterPlotAndConsoleOnIdle()

void SIM_PLOT_FRAME_BASE::m_splitterPlotAndConsoleOnIdle ( wxIdleEvent &  )
inline

Definition at line 129 of file sim_plot_frame_base.h.

130  {
131  m_splitterPlotAndConsole->SetSashPosition( 500 );
132  m_splitterPlotAndConsole->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterPlotAndConsoleOnIdle ), NULL, this );
133  }
#define NULL
void m_splitterPlotAndConsoleOnIdle(wxIdleEvent &)
wxSplitterWindow * m_splitterPlotAndConsole

References m_splitterPlotAndConsole, and NULL.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_splitterSignalsOnIdle()

void SIM_PLOT_FRAME_BASE::m_splitterSignalsOnIdle ( wxIdleEvent &  )
inline

Definition at line 135 of file sim_plot_frame_base.h.

136  {
137  m_splitterSignals->SetSashPosition( 0 );
138  m_splitterSignals->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterSignalsOnIdle ), NULL, this );
139  }
wxSplitterWindow * m_splitterSignals
void m_splitterSignalsOnIdle(wxIdleEvent &)
#define NULL

References m_splitterSignals, and NULL.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_splitterTuneValuesOnIdle()

void SIM_PLOT_FRAME_BASE::m_splitterTuneValuesOnIdle ( wxIdleEvent &  )
inline

Definition at line 141 of file sim_plot_frame_base.h.

142  {
143  m_splitterTuneValues->SetSashPosition( 0 );
144  m_splitterTuneValues->Disconnect( wxEVT_IDLE, wxIdleEventHandler( SIM_PLOT_FRAME_BASE::m_splitterTuneValuesOnIdle ), NULL, this );
145  }
wxSplitterWindow * m_splitterTuneValues
#define NULL
void m_splitterTuneValuesOnIdle(wxIdleEvent &)

References m_splitterTuneValues, and NULL.

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuExit()

virtual void SIM_PLOT_FRAME_BASE::menuExit ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 99 of file sim_plot_frame_base.h.

99 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuNewPlot()

virtual void SIM_PLOT_FRAME_BASE::menuNewPlot ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 94 of file sim_plot_frame_base.h.

94 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuOpenWorkbook()

virtual void SIM_PLOT_FRAME_BASE::menuOpenWorkbook ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 95 of file sim_plot_frame_base.h.

95 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuSaveCsv()

virtual void SIM_PLOT_FRAME_BASE::menuSaveCsv ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 98 of file sim_plot_frame_base.h.

98 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuSaveImage()

virtual void SIM_PLOT_FRAME_BASE::menuSaveImage ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 97 of file sim_plot_frame_base.h.

97 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuSaveWorkbook()

virtual void SIM_PLOT_FRAME_BASE::menuSaveWorkbook ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 96 of file sim_plot_frame_base.h.

96 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuShowDotted()

virtual void SIM_PLOT_FRAME_BASE::menuShowDotted ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 107 of file sim_plot_frame_base.h.

107 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuShowDottedUpdate()

virtual void SIM_PLOT_FRAME_BASE::menuShowDottedUpdate ( wxUpdateUIEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 108 of file sim_plot_frame_base.h.

108 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ menuShowGrid()

virtual void SIM_PLOT_FRAME_BASE::menuShowGrid ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 103 of file sim_plot_frame_base.h.

103 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuShowGridUpdate()

virtual void SIM_PLOT_FRAME_BASE::menuShowGridUpdate ( wxUpdateUIEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 104 of file sim_plot_frame_base.h.

104 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ menuShowLegend()

virtual void SIM_PLOT_FRAME_BASE::menuShowLegend ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 105 of file sim_plot_frame_base.h.

105 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuShowLegendUpdate()

virtual void SIM_PLOT_FRAME_BASE::menuShowLegendUpdate ( wxUpdateUIEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 106 of file sim_plot_frame_base.h.

106 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ menuShowWhiteBackgroundUpdate()

virtual void SIM_PLOT_FRAME_BASE::menuShowWhiteBackgroundUpdate ( wxUpdateUIEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 110 of file sim_plot_frame_base.h.

110 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ menuWhiteBackground()

virtual void SIM_PLOT_FRAME_BASE::menuWhiteBackground ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 109 of file sim_plot_frame_base.h.

109 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuZoomFit()

virtual void SIM_PLOT_FRAME_BASE::menuZoomFit ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 102 of file sim_plot_frame_base.h.

102 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuZoomIn()

virtual void SIM_PLOT_FRAME_BASE::menuZoomIn ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 100 of file sim_plot_frame_base.h.

100 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ menuZoomOut()

virtual void SIM_PLOT_FRAME_BASE::menuZoomOut ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 101 of file sim_plot_frame_base.h.

101 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE().

◆ onAutoSaveTimer()

void EDA_BASE_FRAME::onAutoSaveTimer ( wxTimerEvent &  aEvent)
protectedinherited

Handle the auto save timer event.

Definition at line 262 of file eda_base_frame.cpp.

263 {
264  if( !doAutoSave() )
265  m_autoSaveTimer->Start( m_autoSaveInterval * 1000, wxTIMER_ONE_SHOT );
266 }
virtual bool doAutoSave()
This should be overridden by the derived class to handle the auto save feature.
wxTimer * m_autoSaveTimer

References EDA_BASE_FRAME::doAutoSave(), EDA_BASE_FRAME::m_autoSaveInterval, and EDA_BASE_FRAME::m_autoSaveTimer.

Referenced by EDA_BASE_FRAME::EDA_BASE_FRAME().

◆ OnCharHook()

void EDA_BASE_FRAME::OnCharHook ( wxKeyEvent &  event)
virtualinherited

Capture the key event before it is sent to the GUI.

The basic frame does not capture this event. Editor frames should override this event function to capture and filter these keys when they are used as hotkeys, and skip it if the key is not used as hotkey (otherwise the key events will be not sent to menus).

Reimplemented in FOOTPRINT_VIEWER_FRAME.

Definition at line 275 of file eda_base_frame.cpp.

276 {
277  wxLogTrace( kicadTraceKeyEvent, "EDA_BASE_FRAME::OnCharHook %s", dump( event ) );
278  // Key events can be filtered here.
279  // Currently no filtering is made.
280  event.Skip();
281 }
wxString dump(const wxArrayString &aArray)
Debug helper for printing wxArrayString contents.
const wxChar *const kicadTraceKeyEvent
Flag to enable wxKeyEvent debug tracing.

References dump(), and kicadTraceKeyEvent.

◆ OnKicadAbout()

void EDA_BASE_FRAME::OnKicadAbout ( wxCommandEvent &  event)
inherited

Definition at line 644 of file eda_base_frame.cpp.

645 {
646  void ShowAboutDialog(EDA_BASE_FRAME * aParent); // See AboutDialog_main.cpp
647  ShowAboutDialog( this );
648 }
void ShowAboutDialog(EDA_BASE_FRAME *aParent)
The base frame for deriving all KiCad main window classes.

References ShowAboutDialog().

◆ OnMaximize()

void EDA_BASE_FRAME::OnMaximize ( wxMaximizeEvent &  aEvent)
inherited

Definition at line 841 of file eda_base_frame.cpp.

842 {
843  // When we maximize the window, we want to save the old information
844  // so that we can add it to the settings on next window load.
845  // Contrary to the documentation, this event seems to be generated
846  // when the window is also being unmaximized on OSX, so we only
847  // capture the size information when we maximize the window when on OSX.
848 #ifdef __WXOSX__
849  if( !IsMaximized() )
850 #endif
851  {
853  m_NormalFramePos = GetPosition();
854  wxLogTrace( traceDisplayLocation, "Maximizing window - Saving position (%d, %d) with size (%d, %d)",
856  }
857 
858  // Skip event to actually maximize the window
859  aEvent.Skip();
860 }
const wxChar *const traceDisplayLocation
Flag to enable debug output of display positioning logic.
wxSize m_NormalFrameSize
wxSize GetWindowSize()
Get the undecorated window size that can be used for restoring the window size.
wxPoint m_NormalFramePos

References EDA_BASE_FRAME::GetWindowSize(), EDA_BASE_FRAME::m_NormalFramePos, EDA_BASE_FRAME::m_NormalFrameSize, traceDisplayLocation, wxPoint::x, and wxPoint::y.

◆ OnMenuEvent()

void EDA_BASE_FRAME::OnMenuEvent ( wxMenuEvent &  event)
inherited

The TOOL_DISPATCHER needs these to work around some issues in wxWidgets where the menu events aren't captured by the menus themselves.

Definition at line 284 of file eda_base_frame.cpp.

285 {
286  if( !m_toolDispatcher )
287  aEvent.Skip();
288  else
290 }
virtual void DispatchWxEvent(wxEvent &aEvent)
Function DispatchWxEvent() Processes wxEvents (mostly UI events), translates them to TOOL_EVENTs,...
TOOL_DISPATCHER * m_toolDispatcher
Definition: tools_holder.h:50

References TOOL_DISPATCHER::DispatchWxEvent(), and TOOLS_HOLDER::m_toolDispatcher.

◆ OnMove()

virtual void EDA_BASE_FRAME::OnMove ( wxMoveEvent &  aEvent)
inlinevirtualinherited

Reimplemented in EDA_DRAW_FRAME.

Definition at line 261 of file eda_base_frame.h.

262  {
263  aEvent.Skip();
264  }

◆ onPlotChanged()

virtual void SIM_PLOT_FRAME_BASE::onPlotChanged ( wxAuiNotebookEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 111 of file sim_plot_frame_base.h.

111 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ onPlotClose()

virtual void SIM_PLOT_FRAME_BASE::onPlotClose ( wxAuiNotebookEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 112 of file sim_plot_frame_base.h.

112 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ OnPreferences()

void EDA_BASE_FRAME::OnPreferences ( wxCommandEvent &  event)
inherited

Definition at line 651 of file eda_base_frame.cpp.

652 {
653  PAGED_DIALOG dlg( this, _( "Preferences" ), true );
654  wxTreebook* book = dlg.GetTreebook();
655 
656  book->AddPage( new PANEL_COMMON_SETTINGS( &dlg, book ), _( "Common" ) );
657 
658  book->AddPage( new PANEL_MOUSE_SETTINGS( &dlg, book ), _( "Mouse and Touchpad" ) );
659 
660  PANEL_HOTKEYS_EDITOR* hotkeysPanel = new PANEL_HOTKEYS_EDITOR( this, book, false );
661  book->AddPage( hotkeysPanel, _( "Hotkeys" ) );
662 
663  for( unsigned i = 0; i < KIWAY_PLAYER_COUNT; ++i )
664  {
665  KIWAY_PLAYER* frame = dlg.Kiway().Player( (FRAME_T) i, false );
666 
667  if( frame )
668  frame->InstallPreferences( &dlg, hotkeysPanel );
669  }
670 
671  // The Kicad manager frame is not a player so we have to add it by hand
672  wxWindow* manager = wxFindWindowByName( KICAD_MANAGER_FRAME_NAME );
673 
674  if( manager )
675  static_cast<EDA_BASE_FRAME*>( manager )->InstallPreferences( &dlg, hotkeysPanel );
676 
677  for( size_t i = 0; i < book->GetPageCount(); ++i )
678  book->GetPage( i )->Layout();
679 
680  if( dlg.ShowModal() == wxID_OK )
681  dlg.Kiway().CommonSettingsChanged( false, false );
682 }
KIWAY_PLAYER is a wxFrame capable of the OpenProjectFiles function, meaning it can load a portion of ...
Definition: kiway_player.h:59
KIWAY & Kiway() const
Function Kiway returns a reference to the KIWAY that this object has an opportunity to participate in...
Definition: kiway_holder.h:56
FRAME_T
Enum FRAME_T is the set of EDA_BASE_FRAME derivatives, typically stored in EDA_BASE_FRAME::m_Ident.
Definition: frame_type.h:34
VTBL_ENTRY KIWAY_PLAYER * Player(FRAME_T aFrameType, bool doCreate=true, wxTopLevelWindow *aParent=NULL)
Function Player returns the KIWAY_PLAYER* given a FRAME_T.
Definition: kiway.cpp:342
#define KICAD_MANAGER_FRAME_NAME
#define _(s)
Definition: 3d_actions.cpp:33
virtual void InstallPreferences(PAGED_DIALOG *, PANEL_HOTKEYS_EDITOR *)
Function InstallPreferences Allow a frame to load its preference panels (if any) into the preferences...

References _, KIWAY::CommonSettingsChanged(), PAGED_DIALOG::GetTreebook(), EDA_BASE_FRAME::InstallPreferences(), KICAD_MANAGER_FRAME_NAME, KIWAY_HOLDER::Kiway(), KIWAY_PLAYER_COUNT, and KIWAY::Player().

◆ onSignalDblClick()

virtual void SIM_PLOT_FRAME_BASE::onSignalDblClick ( wxMouseEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 113 of file sim_plot_frame_base.h.

113 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ onSignalRClick()

virtual void SIM_PLOT_FRAME_BASE::onSignalRClick ( wxListEvent &  event)
inlineprotectedvirtual

Reimplemented in SIM_PLOT_FRAME.

Definition at line 114 of file sim_plot_frame_base.h.

114 { event.Skip(); }

Referenced by SIM_PLOT_FRAME_BASE(), and ~SIM_PLOT_FRAME_BASE().

◆ OpenProjectFiles()

virtual bool KIWAY_PLAYER::OpenProjectFiles ( const std::vector< wxString > &  aFileList,
int  aCtl = 0 
)
inlinevirtualinherited

Function OpenProjectFiles is abstract, and opens a project or set of files given by aFileList.

This is generalized in the direction of worst case. In a typical case aFileList will only hold a single file, like "myboard.kicad_pcb", because any KIWAY_PLAYER is only in one KIWAY and the KIWAY owns the PROJECT. Therefore opening files from multiple projects into the same KIWAY_PLAYER is precluded.

Each derived class should handle this in a way specific to its needs. No filename prompting is done inside here for any file or project. There should be no need to call this with aFileList which is empty. However, calling it with a single filename which does not exist should indicate to the implementor that a new session is being started and that the given name is the desired name for the data file at time of save.

This function does not support "appending". Use a different function for that. Any prior project data tree should be cleared before loading the new stuff.

Therefore, one of the first things an implementation should do is test for existence of the first file in the list, and if it does not exist, treat it as a new session, possibly with a UI notification to that effect.

After loading the window should update its Title as part of this operation. If the KIWAY_PLAYER needs to, it can load the *.pro file as part of this operation.

If the KIWAY_PLAYER cannot load any of the file(s) in the list, then it should say why through some GUI interface, and return false.

Parameters
aFileListincludes files that this frame should open according to the knowledge in the derived wxFrame. In almost every case, the list will have only a single file in it.
aCtlis a set of bit flags ORed together from the set of KICTL_* #defined above.
Returns
bool - true if all requested files were opened OK, else false.

Reimplemented in PCB_EDIT_FRAME, SCH_EDIT_FRAME, FOOTPRINT_EDIT_FRAME, GERBVIEW_FRAME, BM2CMP_FRAME, CVPCB_MAINFRAME, and PL_EDITOR_FRAME.

Definition at line 118 of file kiway_player.h.

119  {
120  // overload me for your wxFrame type.
121 
122  // Any overload should probably do this also:
123  // Prj().MaybeLoadProjectSettings();
124 
125  // Then update the window title.
126 
127  return false;
128  }

Referenced by BACK_ANNOTATE::FetchNetlistFromPCB(), PCB_EDIT_FRAME::FetchNetlistFromSchematic(), PGM_TEST_FRAME::MacOpenFile(), PGM_SINGLE_TOP::MacOpenFile(), PGM_MOCK_EESCHEMA_FRAME::MacOpenFile(), SCH_EDIT_FRAME::OnOpenPcbnew(), PGM_SINGLE_TOP::OnPgmInit(), SCH_EDIT_FRAME::OnUpdatePCB(), and PCB_EDIT_FRAME::RunEeschema().

◆ ParseArgs()

virtual void KIWAY_PLAYER::ParseArgs ( wxCmdLineParser &  aParser)
inlinevirtualinherited

Handles command-line arguments in a frame-specific way.

The given argument parser has already been initialized with the command line and any options/switches that are handled by the top-level launcher before passing control to the child frame.

Parameters
aParseris the argument parser created by the top-level launcher.

Definition at line 138 of file kiway_player.h.

139  {
140  WXUNUSED( aParser );
141  }

Referenced by PGM_SINGLE_TOP::OnPgmInit().

◆ PopCommandFromRedoList()

PICKED_ITEMS_LIST * EDA_BASE_FRAME::PopCommandFromRedoList ( )
virtualinherited

PopCommandFromRedoList return the last command to undo and remove it from list nothing is deleted.

Definition at line 825 of file eda_base_frame.cpp.

826 {
827  return m_redoList.PopCommand();
828 }
PICKED_ITEMS_LIST * PopCommand()
UNDO_REDO_CONTAINER m_redoList

References EDA_BASE_FRAME::m_redoList, and UNDO_REDO_CONTAINER::PopCommand().

Referenced by LIB_EDIT_FRAME::GetComponentFromRedoList(), PL_EDITOR_FRAME::GetLayoutFromRedoList(), and SCH_EDITOR_CONTROL::Redo().

◆ PopCommandFromUndoList()

PICKED_ITEMS_LIST * EDA_BASE_FRAME::PopCommandFromUndoList ( )
virtualinherited

◆ PopTool()

void TOOLS_HOLDER::PopTool ( const std::string &  actionName)
virtualinherited

Definition at line 61 of file tools_holder.cpp.

62 {
63  // Push/pop events can get out of order (such as when they're generated by the Simulator
64  // frame but not processed until the mouse is back in the Schematic frame), so make sure
65  // we're popping the right stack frame.
66 
67  for( int i = (int) m_toolStack.size() - 1; i >= 0; --i )
68  {
69  if( m_toolStack[ i ] == actionName )
70  {
71  m_toolStack.erase( m_toolStack.begin() + i );
72 
73  // If there's something underneath us, and it's now the top of the stack, then
74  // re-activate it
75  if( ( --i ) >= 0 && i == (int)m_toolStack.size() - 1 )
76  {
77  std::string back = m_toolStack[ i ];
79 
80  if( action )
81  {
82  // Pop the action as running it will push it back onto the stack
83  m_toolStack.pop_back();
84 
85  TOOL_EVENT evt = action->MakeEvent();
86  evt.SetHasPosition( false );
87  GetToolManager()->PostEvent( evt );
88  }
89  }
90  else
92 
93  return;
94  }
95  }
96 }
virtual void DisplayToolMsg(const wxString &msg)
Definition: tools_holder.h:89
TOOL_ACTION * FindAction(const std::string &aActionName) const
Function FindAction() Finds an action with a given name (if there is one available).
TOOL_EVENT.
Definition: tool_event.h:171
TOOL_MANAGER * m_toolManager
Definition: tools_holder.h:48
std::vector< std::string > m_toolStack
Definition: tools_holder.h:52
ACTION_MANAGER * GetActionManager()
Definition: tool_manager.h:194
TOOL_ACTION.
Definition: tool_action.h:46
TOOL_EVENT MakeEvent() const
Function MakeEvent() Returns the event associated with the action (i.e.
Definition: tool_action.h:107
TOOL_MANAGER * GetToolManager() const
Return the MVC controller.
Definition: tools_holder.h:74
void PostEvent(const TOOL_EVENT &aEvent)
Puts an event to the event queue to be processed at the end of event processing cycle.
Definition: tool_manager.h:268
static TOOL_ACTION selectionTool
Definition: actions.h:147
void SetHasPosition(bool aHasPosition)
Definition: tool_event.h:261

References TOOLS_HOLDER::DisplayToolMsg(), ACTION_MANAGER::FindAction(), TOOL_MANAGER::GetActionManager(), TOOLS_HOLDER::GetToolManager(), TOOLS_HOLDER::m_toolManager, TOOLS_HOLDER::m_toolStack, TOOL_ACTION::MakeEvent(), TOOL_MANAGER::PostEvent(), ACTIONS::selectionTool, and TOOL_EVENT::SetHasPosition().

Referenced by SCH_LINE_WIRE_BUS_TOOL::doDrawSegments(), PCB_TOOL_BASE::doInteractiveItemPlacement(), EDIT_TOOL::doMoveSelection(), DRAWING_TOOL::drawArc(), DRAWING_TOOL::DrawDimension(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::drawSegment(), LIB_DRAWING_TOOLS::DrawShape(), PL_DRAWING_TOOLS::DrawShape(), SCH_DRAWING_TOOLS::DrawSheet(), DRAWING_TOOL::DrawZone(), PAD_TOOL::EnumeratePads(), ZOOM_TOOL::Main(), PL_EDIT_TOOL::Main(), LIB_MOVE_TOOL::Main(), SCH_MOVE_TOOL::Main(), PCBNEW_PICKER_TOOL::Main(), PICKER_TOOL::Main(), ROUTER_TOOL::MainLoop(), LENGTH_TUNER_TOOL::MainLoop(), PCB_VIEWER_TOOLS::MeasureTool(), GERBVIEW_SELECTION_TOOL::MeasureTool(), LIB_DRAWING_TOOLS::PlaceAnchor(), SCH_DRAWING_TOOLS::PlaceComponent(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceImportedGraphics(), PL_DRAWING_TOOLS::PlaceItem(), PCB_EDITOR_CONTROL::PlaceModule(), PCB_EDITOR_CONTROL::PlaceTarget(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::SetAnchor(), SCH_DRAWING_TOOLS::SingleClickPlace(), LIB_DRAWING_TOOLS::TwoClickPlace(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SCH_LINE_WIRE_BUS_TOOL::UnfoldBus().

◆ PrintMsg()

void EDA_BASE_FRAME::PrintMsg ( const wxString &  text)
inherited

Definition at line 562 of file eda_base_frame.cpp.

563 {
564  SetStatusText( text );
565 }

◆ Prj()

PROJECT & KIWAY_HOLDER::Prj ( ) const
inherited

Function Prj returns a reference to the PROJECT "associated with" this KIWAY.

Definition at line 35 of file kiway_holder.cpp.

36 {
37  return Kiway().Prj();
38 }
KIWAY & Kiway() const
Function Kiway returns a reference to the KIWAY that this object has an opportunity to participate in...
Definition: kiway_holder.h:56
VTBL_ENTRY PROJECT & Prj() const
Function Prj returns the PROJECT associated with this KIWAY.
Definition: kiway.cpp:172

References KIWAY_HOLDER::Kiway(), and KIWAY::Prj().

Referenced by PCB_BASE_EDIT_FRAME::AddLibrary(), LIB_MANAGER::addLibrary(), SCH_EDIT_FRAME::AppendSchematic(), PCB_EDIT_FRAME::ArchiveModulesOnBoard(), DIALOG_SYMBOL_REMAP::backupProject(), CVPCB_MAINFRAME::buildEquivalenceList(), CVPCB_MAINFRAME::BuildLIBRARY_LISTBOX(), DIALOG_FOOTPRINT_FP_EDITOR::Cfg3DPath(), DIALOG_FOOTPRINT_BOARD_EDITOR::Cfg3DPath(), DIALOG_GEN_FOOTPRINT_POSITION::CreateGerberFiles(), PCB_BASE_EDIT_FRAME::CreateNewLibrary(), DIALOG_PLOT_SCHEMATIC::createPlotFileName(), DIALOG_SYMBOL_REMAP::createProjectSymbolLibTable(), SCH_EDIT_FRAME::CreateScreens(), FOOTPRINT_EDIT_FRAME::DeleteModuleFromLibrary(), DIALOG_BOARD_SETUP::DIALOG_BOARD_SETUP(), DIALOG_BOARD_STATISTICS::DIALOG_BOARD_STATISTICS(), DIALOG_CHOOSE_COMPONENT::DIALOG_CHOOSE_COMPONENT(), DIALOG_CHOOSE_FOOTPRINT::DIALOG_CHOOSE_FOOTPRINT(), DIALOG_CONFIG_EQUFILES::DIALOG_CONFIG_EQUFILES(), DIALOG_FOOTPRINT_BOARD_EDITOR::DIALOG_FOOTPRINT_BOARD_EDITOR(), DIALOG_FOOTPRINT_FP_EDITOR::DIALOG_FOOTPRINT_FP_EDITOR(), DIALOG_PAGES_SETTINGS::DIALOG_PAGES_SETTINGS(), DIALOG_SCHEMATIC_SETUP::DIALOG_SCHEMATIC_SETUP(), DIALOG_SYMBOL_REMAP::DIALOG_SYMBOL_REMAP(), LIB_VIEW_FRAME::DisplayLibInfos(), CVPCB_MAINFRAME::DisplayStatus(), PL_DRAW_PANEL_GAL::DisplayWorksheet(), PCB_EDIT_FRAME::doAutoSave(), FIELDS_GRID_TRICKS::doPopupSelection(), FIELDS_EDITOR_GRID_TRICKS::doPopupSelection(), KICAD_MANAGER_CONTROL::Execute(), PCB_EDIT_FRAME::Export_IDF3(), DIALOG_EXPORT_SVG::ExportSVGFile(), LIB_CONTROL::ExportSymbolAsSVG(), LIB_CONTROL::ExportView(), PCB_EDIT_FRAME::ExportVRML_File(), BACK_ANNOTATE::FetchNetlistFromPCB(), PCB_EDIT_FRAME::Files_io_from_id(), PCB_EDIT_FRAME::GenD356File(), DIALOG_GENDRILL::GenDrillAndMapFiles(), FOOTPRINT_VIEWER_FRAME::getCurFootprintName(), LIB_EDIT_FRAME::GetCurLib(), FOOTPRINT_VIEWER_FRAME::getCurNickname(), SCH_BASE_FRAME::GetLibPart(), DIALOG_SYMBOL_REMAP::getLibsNotInGlobalSymbolLibTable(), DISPLAY_FOOTPRINTS_FRAME::GetModule(), KICAD_MANAGER_FRAME::GetProjectFileName(), LIB_VIEW_FRAME::GetSelectedSymbol(), FP_THREAD_IFACE::GetTable(), PCB_EDIT_FRAME::importFile(), SCH_EDIT_FRAME::importFile(), SCH_EDITOR_CONTROL::ImportFPAssignments(), DIALOG_CONFIG_EQUFILES::Init(), FOOTPRINT_EDIT_FRAME::initLibraryTree(), SCH_EDIT_FRAME::KiwayMailIn(), LIB_EDIT_FRAME::KiwayMailIn(), EDA_DRAW_FRAME::LibraryFileBrowser(), LIB_EDIT_FRAME::LoadComponentFromCurrentLib(), CVPCB_MAINFRAME::LoadFootprintFiles(), DIALOG_SPICE_MODEL::loadLibrary(), LIB_EDIT_FRAME::LoadOneSymbol(), KICAD_MANAGER_FRAME::LoadProject(), SCH_EDIT_FRAME::LoadProject(), SCH_EDIT_FRAME::LoadProjectSettings(), PCB_EDIT_FRAME::LoadProjectSettings(), DRC::LoadRules(), SCH_EDIT_FRAME::LoadSheetFromFile(), DIALOG_FOOTPRINT_FP_EDITOR::On3DModelCellChanged(), DIALOG_FOOTPRINT_BOARD_EDITOR::On3DModelCellChanged(), FOOTPRINT_VIEWER_FRAME::OnActivate(), DIALOG_FOOTPRINT_FP_EDITOR::OnAdd3DModel(), DIALOG_FOOTPRINT_BOARD_EDITOR::OnAdd3DModel(), KICAD_MANAGER_FRAME::OnBrowseInFileExplorer(), TEXT_BUTTON_URL::OnButtonClick(), TEXT_BUTTON_FILE_BROWSER::OnButtonClick(), DIALOG_EDIT_COMPONENTS_LIBID::onClickOrphansButton(), SCH_EDIT_FRAME::OnCloseWindow(), DIALOG_GENDRILL::OnGenReportFile(), SCH_EDIT_FRAME::OnImportProject(), DIALOG_CHOOSE_COMPONENT::OnInitDialog(), DIALOG_CONFIG_EQUFILES::OnOkClick(), SCH_EDIT_FRAME::OnOpenCvpcb(), KICAD_MANAGER_FRAME::OnOpenFileInTextEditor(), DIALOG_NETLIST::OnOpenNetlistClick(), SCH_EDIT_FRAME::OnOpenPcbnew(), DIALOG_EXPORT_SVG::OnOutputDirectoryBrowseClicked(), DIALOG_PLOT::OnOutputDirectoryBrowseClicked(), DIALOG_PLOT_SCHEMATIC::OnOutputDirectoryBrowseClicked(), DIALOG_GEN_FOOTPRINT_POSITION::OnOutputDirectoryBrowseClicked(), DIALOG_GENDRILL::OnOutputDirectoryBrowseClicked(), DIALOG_SYMBOL_REMAP::OnRemapSymbols(), DIALOG_BOM::OnRunGenerator(), FOOTPRINT_EDIT_FRAME::OnSaveFootprintAsPng(), DIALOG_ERC::OnSaveReport(), DIALOG_DRC::OnSaveReport(), PROPERTIES_FRAME::onScintillaCharAdded(), DIALOG_LABEL_EDITOR::onScintillaCharAdded(), DIALOG_SCH_EDIT_ONE_FIELD::onScintillaCharAdded(), DIALOG_SPICE_MODEL::onSelectLibrary(), LIB_VIEW_FRAME::OnSelectSymbol(), KICAD_MANAGER_FRAME::OnUnarchiveFiles(), SCH_EDIT_FRAME::OnUpdatePCB(), SCH_EDIT_FRAME::OpenProjectFiles(), PCB_EDIT_FRAME::OpenProjectFiles(), PANEL_PREV_3D::PANEL_PREV_3D(), SCH_EDITOR_CONTROL::Paste(), FOOTPRINT_EDITOR_TOOLS::PasteFootprint(), PCB_BASE_EDIT_FRAME::PCB_BASE_EDIT_FRAME(), DIALOG_PLOT::Plot(), DIALOG_PLOT_SCHEMATIC::Plot_1_Page_HPGL(), DIALOG_PLOT_SCHEMATIC::PlotOneSheetDXF(), DIALOG_CHOOSE_COMPONENT::PopulateFootprintSelector(), SCH_EDITOR_CONTROL::Print(), SCH_EDIT_FRAME::PrintPage(), EDA_DRAW_FRAME::PrintWorkSheet(), CVPCB_MAINFRAME::ReadNetListAndFpFiles(), PCB_EDIT_FRAME::RecreateCmpFileFromBoard(), FOOTPRINT_VIEWER_FRAME::ReCreateFootprintList(), FOOTPRINT_VIEWER_FRAME::ReCreateLibraryList(), LIB_VIEW_FRAME::ReCreateListCmp(), LIB_VIEW_FRAME::ReCreateListLib(), SCH_EDIT_TOOL::RefreshSymbolFromLibrary(), EDA_3D_VIEWER::ReloadRequest(), DIALOG_SYMBOL_REMAP::remapSymbolToLibTable(), SCH_EDITOR_CONTROL::RescueLegacyProject(), SCH_EDITOR_CONTROL::RescueSymbolLibTableProject(), FOOTPRINT_EDIT_FRAME::restoreLastFootprint(), FOOTPRINT_EDIT_FRAME::retainLastFootprint(), SCH_EDIT_FRAME::SaveEEFile(), FOOTPRINT_EDIT_FRAME::SaveFootprint(), FOOTPRINT_EDIT_FRAME::SaveFootprintAs(), FOOTPRINT_EDIT_FRAME::SaveFootprintInLibrary(), LIB_EDIT_FRAME::saveLibrary(), LIB_EDIT_FRAME::SaveOneSymbol(), LIB_EDIT_FRAME::savePartAs(), PCB_EDIT_FRAME::SavePcbFile(), SCH_EDIT_FRAME::SaveProject(), PCB_EDIT_FRAME::SaveProjectSettings(), DIALOG_BOARD_STATISTICS::saveReportClicked(), SCH_BASE_FRAME::saveSymbolLibTables(), FOOTPRINT_VIEWER_FRAME::SelectAndViewFootprint(), SCH_BASE_FRAME::SelectCompFromLibTree(), PCB_BASE_FRAME::SelectLibrary(), LIB_EDIT_FRAME::SelectLibraryFromList(), LIB_EDIT_FRAME::selectSymLibTable(), FOOTPRINT_VIEWER_FRAME::setCurFootprintName(), LIB_EDIT_FRAME::SetCurLib(), FOOTPRINT_VIEWER_FRAME::setCurNickname(), LIB_EDIT_FRAME::SetCurPart(), GERBVIEW_FRAME::SetPageSettings(), EE_INSPECTION_TOOL::ShowDatasheet(), DIALOG_CHOOSE_COMPONENT::ShowFootprintFor(), COMMON_CONTROL::ShowHelp(), LIB_VIEW_FRAME::ShowModal(), FOOTPRINT_VIEWER_FRAME::ShowModal(), SCH_EDIT_FRAME::ShowSchematicSetupDialog(), SIM_PLOT_FRAME::SIM_PLOT_FRAME(), LIB_MANAGER::symTable(), SYMBOL_TREE_SYNCHRONIZING_ADAPTER::Sync(), FOOTPRINT_EDIT_FRAME::SyncLibraryTree(), EDA_3D_VIEWER::takeScreenshot(), PANEL_SETUP_RULES::TransferDataFromWindow(), DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::TransferDataFromWindow(), NETLIST_DIALOG::TransferDataFromWindow(), DIALOG_EDIT_COMPONENTS_LIBID::TransferDataFromWindow(), PANEL_SETUP_RULES::TransferDataToWindow(), DIALOG_FOOTPRINT_FP_EDITOR::TransferDataToWindow(), DIALOG_FOOTPRINT_BOARD_EDITOR::TransferDataToWindow(), DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::UpdateFieldsFromLibrary(), DIALOG_PAGES_SETTINGS::UpdatePageLayoutExample(), FOOTPRINT_VIEWER_FRAME::UpdateTitle(), FOOTPRINT_EDIT_FRAME::updateTitle(), SCH_EDIT_FRAME::UpdateTitle(), DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::Validate(), SCH_EDIT_FRAME::WriteNetListFile(), DIALOG_FOOTPRINT_BOARD_EDITOR::~DIALOG_FOOTPRINT_BOARD_EDITOR(), DIALOG_FOOTPRINT_FP_EDITOR::~DIALOG_FOOTPRINT_FP_EDITOR(), and PCB_BASE_EDIT_FRAME::~PCB_BASE_EDIT_FRAME().

◆ ProcessEvent()

bool EDA_BASE_FRAME::ProcessEvent ( wxEvent &  aEvent)
overrideinherited

Override the default process event handler to implement the auto save feature.

Warning
If you override this function in a derived class, make sure you call down to this or the auto save feature will be disabled.

Definition at line 204 of file eda_base_frame.cpp.

205 {
206 #ifdef __WXMAC__
207  // Apple in its infinite wisdom will raise a disabled window before even passing
208  // us the event, so we have no way to stop it. Instead, we have to catch an
209  // improperly ordered disabled window and quasi-modal dialog here and reorder
210  // them.
211  if( !IsEnabled() && IsActive() )
212  {
213  wxWindow* dlg = findQuasiModalDialog();
214  if( dlg )
215  dlg->Raise();
216  }
217 #endif
218 
219  if( !wxFrame::ProcessEvent( aEvent ) )
220  return false;
221 
222  if( IsShown() && m_hasAutoSave && IsActive() &&
224  {
225  if( !m_autoSaveState )
226  {
227  wxLogTrace( traceAutoSave, wxT( "Starting auto save timer." ) );
228  m_autoSaveTimer->Start( m_autoSaveInterval * 1000, wxTIMER_ONE_SHOT );
229  m_autoSaveState = true;
230  }
231  else if( m_autoSaveTimer->IsRunning() )
232  {
233  wxLogTrace( traceAutoSave, wxT( "Stopping auto save timer." ) );
234  m_autoSaveTimer->Stop();
235  m_autoSaveState = false;
236  }
237  }
238 
239  return true;
240 }
const wxChar *const traceAutoSave
Flag to enable auto save feature debug tracing.
virtual bool isAutoSaveRequired() const
Return the auto save status of the application.
wxTimer * m_autoSaveTimer
wxWindow * findQuasiModalDialog()

References EDA_BASE_FRAME::findQuasiModalDialog(), EDA_BASE_FRAME::isAutoSaveRequired(), EDA_BASE_FRAME::m_autoSaveInterval, EDA_BASE_FRAME::m_autoSaveState, EDA_BASE_FRAME::m_autoSaveTimer, EDA_BASE_FRAME::m_hasAutoSave, and traceAutoSave.

Referenced by COMMON_TOOLS::GridProperties(), LIB_VIEW_FRAME::onSelectNextSymbol(), LIB_VIEW_FRAME::onSelectPreviousSymbol(), KIWAY::ProcessEvent(), and LIB_VIEW_FRAME::ReCreateListCmp().

◆ PushCommandToRedoList()

void EDA_BASE_FRAME::PushCommandToRedoList ( PICKED_ITEMS_LIST aItem)
virtualinherited

Function PushCommandToRedoList add a command to redo in redo list delete the very old commands when the max count of redo commands is reached ( using ClearUndoORRedoList)

Definition at line 804 of file eda_base_frame.cpp.

805 {
806  m_redoList.PushCommand( aNewitem );
807 
808  // Delete the extra items, if count max reached
809  if( m_UndoRedoCountMax > 0 )
810  {
811  int extraitems = GetRedoCommandCount() - m_UndoRedoCountMax;
812 
813  if( extraitems > 0 )
814  ClearUndoORRedoList( REDO_LIST, extraitems );
815  }
816 }
int GetRedoCommandCount() const
virtual void ClearUndoORRedoList(UNDO_REDO_LIST aList, int aItemCount=-1)
void PushCommand(PICKED_ITEMS_LIST *aCommand)
UNDO_REDO_CONTAINER m_redoList

References EDA_BASE_FRAME::ClearUndoORRedoList(), EDA_BASE_FRAME::GetRedoCommandCount(), EDA_BASE_FRAME::m_redoList, EDA_BASE_FRAME::m_UndoRedoCountMax, UNDO_REDO_CONTAINER::PushCommand(), and EDA_BASE_FRAME::REDO_LIST.

Referenced by LIB_EDIT_FRAME::GetComponentFromUndoList(), PL_EDITOR_FRAME::GetLayoutFromUndoList(), and SCH_EDITOR_CONTROL::Undo().

◆ PushCommandToUndoList()

void EDA_BASE_FRAME::PushCommandToUndoList ( PICKED_ITEMS_LIST aItem)
virtualinherited

Function PushCommandToUndoList add a command to undo in undo list delete the very old commands when the max count of undo commands is reached ( using ClearUndoORRedoList)

Definition at line 789 of file eda_base_frame.cpp.

790 {
791  m_undoList.PushCommand( aNewitem );
792 
793  // Delete the extra items, if count max reached
794  if( m_UndoRedoCountMax > 0 )
795  {
796  int extraitems = GetUndoCommandCount() - m_UndoRedoCountMax;
797 
798  if( extraitems > 0 )
799  ClearUndoORRedoList( UNDO_LIST, extraitems );
800  }
801 }
UNDO_REDO_CONTAINER m_undoList
int GetUndoCommandCount() const
virtual void ClearUndoORRedoList(UNDO_REDO_LIST aList, int aItemCount=-1)
void PushCommand(PICKED_ITEMS_LIST *aCommand)

References EDA_BASE_FRAME::ClearUndoORRedoList(), EDA_BASE_FRAME::GetUndoCommandCount(), EDA_BASE_FRAME::m_undoList, EDA_BASE_FRAME::m_UndoRedoCountMax, UNDO_REDO_CONTAINER::PushCommand(), and EDA_BASE_FRAME::UNDO_LIST.

Referenced by LIB_EDIT_FRAME::GetComponentFromRedoList(), PL_EDITOR_FRAME::GetLayoutFromRedoList(), SCH_EDITOR_CONTROL::Redo(), PL_EDITOR_FRAME::SaveCopyInUndoList(), LIB_EDIT_FRAME::SaveCopyInUndoList(), and SCH_EDIT_FRAME::SaveCopyInUndoList().

◆ PushTool()

void TOOLS_HOLDER::PushTool ( const std::string &  actionName)
virtualinherited

NB: the definition of "tool" is different at the user level.

The implementation uses a single TOOL_BASE derived class to implement several user "tools", such as rectangle and circle, or wire and bus. So each user-level tool is actually a TOOL_ACTION.

Definition at line 44 of file tools_holder.cpp.

45 {
46  m_toolStack.push_back( actionName );
47 
48  // Human cognitive stacking is very shallow; deeper tool stacks just get annoying
49  if( m_toolStack.size() > 3 )
50  m_toolStack.erase( m_toolStack.begin() );
51 
52  TOOL_ACTION* action = m_toolManager->GetActionManager()->FindAction( actionName );
53 
54  if( action )
55  DisplayToolMsg( action->GetLabel() );
56  else
57  DisplayToolMsg( actionName );
58 }
virtual void DisplayToolMsg(const wxString &msg)
Definition: tools_holder.h:89
TOOL_ACTION * FindAction(const std::string &aActionName) const
Function FindAction() Finds an action with a given name (if there is one available).
wxString GetLabel() const
Definition: tool_action.cpp:69
TOOL_MANAGER * m_toolManager
Definition: tools_holder.h:48
std::vector< std::string > m_toolStack
Definition: tools_holder.h:52
ACTION_MANAGER * GetActionManager()
Definition: tool_manager.h:194
TOOL_ACTION.
Definition: tool_action.h:46

References TOOLS_HOLDER::DisplayToolMsg(), ACTION_MANAGER::FindAction(), TOOL_MANAGER::GetActionManager(), TOOL_ACTION::GetLabel(), TOOLS_HOLDER::m_toolManager, and TOOLS_HOLDER::m_toolStack.

Referenced by PCB_TOOL_BASE::doInteractiveItemPlacement(), EDIT_TOOL::doMoveSelection(), DRAWING_TOOL::DrawArc(), DRAWING_TOOL::DrawCircle(), DRAWING_TOOL::DrawDimension(), DRAWING_TOOL::DrawLine(), MICROWAVE_TOOL::drawMicrowaveInductor(), DRAWING_TOOL::DrawRectangle(), SCH_LINE_WIRE_BUS_TOOL::DrawSegments(), LIB_DRAWING_TOOLS::DrawShape(), PL_DRAWING_TOOLS::DrawShape(), SCH_DRAWING_TOOLS::DrawSheet(), DRAWING_TOOL::DrawZone(), PAD_TOOL::EnumeratePads(), ZOOM_TOOL::Main(), PL_EDIT_TOOL::Main(), LIB_MOVE_TOOL::Main(), SCH_MOVE_TOOL::Main(), PCBNEW_PICKER_TOOL::Main(), PICKER_TOOL::Main(), ROUTER_TOOL::MainLoop(), LENGTH_TUNER_TOOL::MainLoop(), PCB_VIEWER_TOOLS::MeasureTool(), GERBVIEW_SELECTION_TOOL::MeasureTool(), LIB_DRAWING_TOOLS::PlaceAnchor(), SCH_DRAWING_TOOLS::PlaceComponent(), SCH_DRAWING_TOOLS::PlaceImage(), DRAWING_TOOL::PlaceImportedGraphics(), PL_DRAWING_TOOLS::PlaceItem(), PCB_EDITOR_CONTROL::PlaceModule(), PCB_EDITOR_CONTROL::PlaceTarget(), DRAWING_TOOL::PlaceText(), DRAWING_TOOL::SetAnchor(), SCH_DRAWING_TOOLS::SingleClickPlace(), LIB_DRAWING_TOOLS::TwoClickPlace(), SCH_DRAWING_TOOLS::TwoClickPlace(), and SCH_LINE_WIRE_BUS_TOOL::UnfoldBus().

◆ ReCreateMenuBar()

◆ RefreshCanvas()

virtual void TOOLS_HOLDER::RefreshCanvas ( )
inlinevirtualinherited

Reimplemented in EDA_DRAW_FRAME.

Definition at line 119 of file tools_holder.h.

119 { }

Referenced by TOOL_MANAGER::ProcessEvent().

◆ RemoveShutdownBlockReason()

void EDA_BASE_FRAME::RemoveShutdownBlockReason ( )
inherited

Removes any shutdown block reason set.

Definition at line 177 of file eda_base_frame.cpp.

178 {
179 #if defined( _WIN32 )
180  // Windows: Destroys any block reason that may have existed
181  ShutdownBlockReasonDestroy( GetHandle() );
182 #endif
183 }

Referenced by EDA_BASE_FRAME::~EDA_BASE_FRAME().

◆ SaveProjectSettings()

virtual void EDA_BASE_FRAME::SaveProjectSettings ( )
inlinevirtualinherited

Save changes to the project settings to the project (.pro) file.

The method is virtual so you can override it to call the suitable save method. The base method do nothing

Parameters
aAskForSave= true to open a dialog before saving the settings

Reimplemented in PCB_EDIT_FRAME, and SCH_EDIT_FRAME.

Definition at line 361 of file eda_base_frame.h.

361 {};

Referenced by DIALOG_PAGES_SETTINGS::OnOkClick().

◆ SaveSettings()

void EDA_BASE_FRAME::SaveSettings ( APP_SETTINGS_BASE aCfg)
virtualinherited

Saves common frame parameters to a configuration data file.

Don't forget to call the base class's SaveSettings() from your derived SaveSettings() otherwise the frames won't remember their positions and sizes.

Reimplemented in EDA_DRAW_FRAME, GERBVIEW_FRAME, PCB_EDIT_FRAME, PCB_BASE_FRAME, CVPCB_MAINFRAME, LIB_EDIT_FRAME, SCH_EDIT_FRAME, SIM_PLOT_FRAME, PL_EDITOR_FRAME, FOOTPRINT_WIZARD_FRAME, EDA_3D_VIEWER, BM2CMP_FRAME, KICAD_MANAGER_FRAME, FOOTPRINT_VIEWER_FRAME, SCH_BASE_FRAME, LIB_VIEW_FRAME, PCB_CALCULATOR_FRAME, FOOTPRINT_EDIT_FRAME, and DISPLAY_FOOTPRINTS_FRAME.

Definition at line 519 of file eda_base_frame.cpp.

520 {
522 
523  // Save the recently used files list
524  if( m_fileHistory )
525  {
526  // Save the currently opened file in the file history
527  wxString currentlyOpenedFile = GetCurrentFileName();
528 
529  if( !currentlyOpenedFile.IsEmpty() )
530  UpdateFileHistory( currentlyOpenedFile );
531 
532  m_fileHistory->Save( *aCfg );
533  }
534 }
void SaveWindowSettings(WINDOW_SETTINGS *aCfg)
Saves window settings to the given settings object Normally called by SaveSettings unless the window ...
void Save(APP_SETTINGS_BASE &aSettings)
Saves history into a JSON settings object.
Definition: filehistory.cpp:65
void UpdateFileHistory(const wxString &FullFileName, FILE_HISTORY *aFileHistory=nullptr)
Update the list of recently opened files.
virtual WINDOW_SETTINGS * GetWindowSettings(APP_SETTINGS_BASE *aCfg)
Returns a pointer to the window settings for this frame.
virtual wxString GetCurrentFileName() const
Get the full filename + path of the currently opened file in the frame.
FILE_HISTORY * m_fileHistory

References EDA_BASE_FRAME::GetCurrentFileName(), EDA_BASE_FRAME::GetWindowSettings(), EDA_BASE_FRAME::m_fileHistory, FILE_HISTORY::Save(), EDA_BASE_FRAME::SaveWindowSettings(), and EDA_BASE_FRAME::UpdateFileHistory().

Referenced by PCB_CALCULATOR_FRAME::SaveSettings(), KICAD_MANAGER_FRAME::SaveSettings(), BM2CMP_FRAME::SaveSettings(), EDA_3D_VIEWER::SaveSettings(), SIM_PLOT_FRAME::SaveSettings(), CVPCB_MAINFRAME::SaveSettings(), EDA_DRAW_FRAME::SaveSettings(), and EDA_BASE_FRAME::windowClosing().

◆ SaveWindowSettings()

void EDA_BASE_FRAME::SaveWindowSettings ( WINDOW_SETTINGS aCfg)
inherited

Saves window settings to the given settings object Normally called by SaveSettings unless the window in question is a child window that stores its settings somewhere other than APP_SETTINGS_BASE::m_Window.

Definition at line 460 of file eda_base_frame.cpp.

461 {
462  wxString text;
463 
464  if( IsIconized() )
465  return;
466 
467  wxString baseCfgName = ConfigBaseName();
468 
469  // If the window is maximized, we use the saved window size from before it was maximized
470  if( IsMaximized() )
471  {
474  }
475  else
476  {
478  m_FramePos = GetPosition();
479  }
480 
481  aCfg->pos_x = m_FramePos.x;
482  aCfg->pos_y = m_FramePos.y;
483  aCfg->size_x = m_FrameSize.x;
484  aCfg->size_y = m_FrameSize.y;
485  aCfg->maximized = IsMaximized();
486  aCfg->display = wxDisplay::GetFromWindow( this );
487 
488  wxLogTrace( traceDisplayLocation, "Saving window maximized: %s", IsMaximized() ? "true" : "false" );
489  wxLogTrace( traceDisplayLocation, "Saving config position (%d, %d) with size (%d, %d)",
491 
492  // TODO(JE) should auto-save in common settings be overwritten by every app?
493  if( m_hasAutoSave )
494  Pgm().GetCommonSettings()->m_System.autosave_interval = m_autoSaveInterval;
495 
496  // Once this is fully implemented, wxAuiManager will be used to maintain
497  // the persistance of the main frame and all it's managed windows and
498  // all of the legacy frame persistence position code can be removed.
499  aCfg->perspective = m_auimgr.SavePerspective().ToStdString();
500 
501  aCfg->mru_path = m_mruPath;
502 }
wxString mru_path
Definition: app_settings.h:71
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:104
wxString m_mruPath
const wxChar *const traceDisplayLocation
Flag to enable debug output of display positioning logic.
wxAuiManager m_auimgr
wxSize m_NormalFrameSize
wxString perspective
Definition: app_settings.h:74
wxSize GetWindowSize()
Get the undecorated window size that can be used for restoring the window size.
wxString ConfigBaseName() override
wxPoint m_NormalFramePos
unsigned int display
Definition: app_settings.h:77

References EDA_BASE_FRAME::ConfigBaseName(), WINDOW_SETTINGS::display, EDA_BASE_FRAME::GetWindowSize(), EDA_BASE_FRAME::m_auimgr, EDA_BASE_FRAME::m_autoSaveInterval, EDA_BASE_FRAME::m_FramePos, EDA_BASE_FRAME::m_FrameSize, EDA_BASE_FRAME::m_hasAutoSave, EDA_BASE_FRAME::m_mruPath, EDA_BASE_FRAME::m_NormalFramePos, EDA_BASE_FRAME::m_NormalFrameSize, WINDOW_SETTINGS::maximized, WINDOW_SETTINGS::mru_path, WINDOW_SETTINGS::perspective, Pgm(), WINDOW_SETTINGS::pos_x, WINDOW_SETTINGS::pos_y, WINDOW_SETTINGS::size_x, WINDOW_SETTINGS::size_y, traceDisplayLocation, wxPoint::x, and wxPoint::y.

Referenced by EDA_BASE_FRAME::SaveSettings().

◆ SetAutoSaveInterval()

void EDA_BASE_FRAME::SetAutoSaveInterval ( int  aInterval)
inherited

Definition at line 243 of file eda_base_frame.cpp.

244 {
245  m_autoSaveInterval = aInterval;
246 
247  if( m_autoSaveTimer->IsRunning() )
248  {
249  if( m_autoSaveInterval > 0 )
250  {
251  m_autoSaveTimer->Start( m_autoSaveInterval * 1000, wxTIMER_ONE_SHOT );
252  }
253  else
254  {
255  m_autoSaveTimer->Stop();
256  m_autoSaveState = false;
257  }
258  }
259 }
wxTimer * m_autoSaveTimer

References EDA_BASE_FRAME::m_autoSaveInterval, EDA_BASE_FRAME::m_autoSaveState, and EDA_BASE_FRAME::m_autoSaveTimer.

Referenced by EDA_DRAW_FRAME::CommonSettingsChanged().

◆ SetKiway()

void KIWAY_HOLDER::SetKiway ( wxWindow *  aDest,
KIWAY aKiway 
)
inherited

Function SetKiway.

Parameters
aDestis the recipient of aKiway pointer. It is only used for debugging, since "this" is not a wxWindow*. "this" is a KIWAY_HOLDER mix-in.
aKiwayis often from a parent window, or from KIFACE::CreateWindow().

Definition at line 42 of file kiway_holder.cpp.

43 {
44 #if defined(DEBUG)
45  // offer a trap point for debugging most any window
46  wxASSERT( aDest );
47  if( !strcmp( typeid(aDest).name(), "DIALOG_EDIT_LIBENTRY_FIELDS_IN_LIB" ) )
48  {
49  int breakhere=1;
50  (void) breakhere;
51  }
52 #endif
53 
54  (void) aDest;
55 
56  m_kiway = aKiway;
57 }
KIWAY * m_kiway
Definition: kiway_holder.h:81
const char * name
Definition: DXF_plotter.cpp:60

References KIWAY_HOLDER::m_kiway, and name.

Referenced by BM2CMP_FRAME::BM2CMP_FRAME(), PCB::IFACE::CreateWindow(), InvokePcbLibTableEditor(), PCB_CALCULATOR_FRAME::PCB_CALCULATOR_FRAME(), and SIM_PLOT_FRAME::SIM_PLOT_FRAME().

◆ SetModal()

void KIWAY_PLAYER::SetModal ( bool  aIsModal)
inlineinherited

Definition at line 177 of file kiway_player.h.

177 { m_modal = aIsModal; }

References KIWAY_PLAYER::m_modal.

Referenced by FOOTPRINT_VIEWER_FRAME::FOOTPRINT_VIEWER_FRAME(), and LIB_VIEW_FRAME::LIB_VIEW_FRAME().

◆ SetMruPath()

void EDA_BASE_FRAME::SetMruPath ( const wxString &  aPath)
inlineinherited

Definition at line 419 of file eda_base_frame.h.

419 { m_mruPath = aPath; }
wxString m_mruPath

References EDA_BASE_FRAME::m_mruPath.

Referenced by PANEL_HOTKEYS_EDITOR::ImportHotKeys(), and KICAD_MANAGER_FRAME::LoadProject().

◆ SetShutdownBlockReason()

void EDA_BASE_FRAME::SetShutdownBlockReason ( const wxString &  reason)
inherited

Sets the block reason why the window/application is preventing OS shutdown.

This should be set far ahead of any close event.

This is mainly intended for Windows platforms where this is a native feature.

Definition at line 186 of file eda_base_frame.cpp.

187 {
188 #if defined( _WIN32 )
189  // Windows: sets up the pretty message on the shutdown page on why it's being "blocked"
190  // This is used in conjunction with handling WM_QUERYENDSESSION (wxCloseEvent)
191  // ShutdownBlockReasonCreate does not block by itself
192 
193  ShutdownBlockReasonDestroy( GetHandle() ); // Destroys any existing or nonexisting reason
194 
195  if( !ShutdownBlockReasonCreate( GetHandle(), aReason.wc_str() ) )
196  {
197  // Nothing bad happens if this fails, at worst it uses a generic application is preventing shutdown message
198  wxLogDebug( wxT( "ShutdownBlockReasonCreate failed to set reason: %s" ), aReason );
199  }
200 #endif
201 }

Referenced by CVPCB_MAINFRAME::CVPCB_MAINFRAME(), PL_EDITOR_FRAME::OnNewPageLayout(), and SCH_EDIT_FRAME::OpenProjectFiles().

◆ SetUserUnits()

◆ ShowChangedLanguage()

void EDA_BASE_FRAME::ShowChangedLanguage ( )
virtualinherited

◆ ShowModal()

bool KIWAY_PLAYER::ShowModal ( wxString *  aResult = NULL,
wxWindow *  aResultantFocusWindow = NULL 
)
virtualinherited

Function ShowModal puts up this wxFrame as if it were a modal dialog, with all other instantiated wxFrames disabled until this KIWAY_PLAYER derivative calls DismissModal().

That is, behavior is similar to a modal dialog window. Not all KIWAY_PLAYERs use this interface, so don't call this unless the implementation knows how to call DismissModal() on a button click or double click or some special event which ends the modal behavior.

Parameters
aResultif not NULL, indicates a place to put a resultant string.
aResultantFocusWindowif not NULL, indicates what window to pass focus to on return.
Returns
bool - true if frame implementation called KIWAY_PLAYER::DismissModal() with aRetVal of true.

Reimplemented in FOOTPRINT_VIEWER_FRAME, and LIB_VIEW_FRAME.

Definition at line 75 of file kiway_player.cpp.

76 {
77  wxASSERT_MSG( IsModal(), wxT( "ShowModal() shouldn't be called on non-modal frame" ) );
78 
79  /*
80  This function has a nice interface but a necessarily unsightly implementation.
81  Now the implementation is encapsulated, localizing future changes.
82 
83  It works in tandem with DismissModal(). But only ShowModal() is in the
84  vtable and therefore cross-module capable.
85  */
86 
87  // This is an exception safe way to zero a pointer before returning.
88  // Yes, even though DismissModal() clears this first normally, this is
89  // here in case there's an exception before the dialog is dismissed.
90  struct NULLER
91  {
92  void*& m_what;
93  NULLER( void*& aPtr ) : m_what( aPtr ) {}
94  ~NULLER() { m_what = 0; } // indeed, set it to NULL on destruction
95  } clear_this( (void*&) m_modal_loop );
96 
97 
98  m_modal_resultant_parent = aResultantFocusWindow;
99 
100  Show( true );
101  Raise(); // Needed on some Window managers to always display the frame
102 
103  SetFocus();
104 
105  {
106  // We have to disable all frames but the the modal one.
107  // wxWindowDisabler does that, but it also disables all top level windows
108  // We do not want to disable top level windows which are child of the modal one,
109  // if they are enabled.
110  // An example is an aui toolbar which was moved
111  // or a dialog or another frame or miniframe opened by the modal one.
112  wxWindowList wlist = GetChildren();
113  std::vector<wxWindow*> enabledTopLevelWindows;
114 
115  for( unsigned ii = 0; ii < wlist.size(); ii++ )
116  if( wlist[ii]->IsTopLevel() && wlist[ii]->IsEnabled() )
117  enabledTopLevelWindows.push_back( wlist[ii] );
118 
119  // exception safe way to disable all top level windows except the modal one,
120  // re-enables only those that were disabled on exit
121  wxWindowDisabler toggle( this );
122 
123  for( unsigned ii = 0; ii < enabledTopLevelWindows.size(); ii++ )
124  enabledTopLevelWindows[ii]->Enable( true );
125 
126  WX_EVENT_LOOP event_loop;
127  m_modal_loop = &event_loop;
128  event_loop.Run();
129 
130  } // End of scope for some variables.
131  // End nesting before setting focus below.
132 
133  if( aResult )
134  *aResult = m_modal_string;
135 
136  if( aResultantFocusWindow )
137  {
138  aResultantFocusWindow->Raise();
139 
140  // have the final say, after wxWindowDisabler reenables my parent and
141  // the events settle down, set the focus
142  wxSafeYield();
143  aResultantFocusWindow->SetFocus();
144  }
145 
146  return m_modal_ret_val;
147 }
bool m_modal_ret_val
Definition: kiway_player.h:205
#define WX_EVENT_LOOP
Definition: kiway_player.h:41
wxWindow * m_modal_resultant_parent
Definition: kiway_player.h:203
wxString m_modal_string
Definition: kiway_player.h:204
bool IsModal() const
Definition: kiway_player.h:176
WX_EVENT_LOOP * m_modal_loop
Definition: kiway_player.h:202

References KIWAY_PLAYER::IsModal(), KIWAY_PLAYER::m_modal_loop, KIWAY_PLAYER::m_modal_resultant_parent, KIWAY_PLAYER::m_modal_ret_val, KIWAY_PLAYER::m_modal_string, and WX_EVENT_LOOP.

Referenced by FIELDS_GRID_TRICKS::doPopupSelection(), FIELDS_EDITOR_GRID_TRICKS::doPopupSelection(), TEXT_BUTTON_SYMBOL_CHOOSER::OnButtonClick(), TEXT_BUTTON_FP_CHOOSER::OnButtonClick(), DIALOG_EDIT_ONE_FIELD::OnTextValueSelectButtonClick(), LIB_VIEW_FRAME::ShowModal(), FOOTPRINT_VIEWER_FRAME::ShowModal(), and DIALOG_EXCHANGE_FOOTPRINTS::ViewAndSelectFootprint().

◆ SupportsShutdownBlockReason()

bool EDA_BASE_FRAME::SupportsShutdownBlockReason ( )
inherited

Whether or not the window supports setting a shutdown block reason.

Definition at line 167 of file eda_base_frame.cpp.

168 {
169 #if defined( _WIN32 )
170  return true;
171 #else
172  return false;
173 #endif
174 }

Referenced by FOOTPRINT_EDIT_FRAME::OnCloseWindow(), PL_EDITOR_FRAME::OnCloseWindow(), SCH_EDIT_FRAME::OnCloseWindow(), CVPCB_MAINFRAME::OnCloseWindow(), LIB_EDIT_FRAME::OnCloseWindow(), and EDA_BASE_FRAME::~EDA_BASE_FRAME().

◆ SyncToolbars()

virtual void EDA_BASE_FRAME::SyncToolbars ( )
inlinevirtualinherited

◆ sys_search()

const SEARCH_STACK & EDA_BASE_FRAME::sys_search ( )
virtualinherited

Return a SEARCH_STACK pertaining to entire program.

This is overloaded in KICAD_MANAGER_FRAME

Reimplemented in KICAD_MANAGER_FRAME.

Definition at line 550 of file eda_base_frame.cpp.

551 {
552  return Kiface().KifaceSearch();
553 }
SEARCH_STACK & KifaceSearch()
Only for DSO specific 'non-library' files.
Definition: kiface_i.h:127
KIFACE_I & Kiface()
Global KIFACE_I "get" accessor.

References Kiface(), and KIFACE_I::KifaceSearch().

Referenced by COMMON_CONTROL::ShowHelp().

◆ ToggleUserUnits()

virtual void EDA_BASE_FRAME::ToggleUserUnits ( )
inlinevirtualinherited

Reimplemented in EDA_DRAW_FRAME.

Definition at line 232 of file eda_base_frame.h.

232 { }

Referenced by DIALOG_SHIM::OnCharHook().

◆ ToolStackIsEmpty()

◆ unitsChangeRefresh()

virtual void EDA_BASE_FRAME::unitsChangeRefresh ( )
inlineprotectedvirtualinherited

Called when when the units setting has changed to allow for any derived classes to handle refreshing and controls that have units based measurements in them.

The default version only updates the status bar. Don't forget to call the default in your derived class or the status bar will not get updated properly.

Reimplemented in PCB_BASE_EDIT_FRAME, GERBVIEW_FRAME, EDA_DRAW_FRAME, and PCB_BASE_FRAME.

Definition at line 206 of file eda_base_frame.h.

206 { }

Referenced by EDA_BASE_FRAME::ChangeUserUnits().

◆ UpdateFileHistory()

void EDA_BASE_FRAME::UpdateFileHistory ( const wxString &  FullFileName,
FILE_HISTORY aFileHistory = nullptr 
)
inherited

Update the list of recently opened files.

The menu is also updated, if FILE_HISTORY::UseMenu was called at init time.

Parameters
FullFileNameThe full file name including the path.
aFileHistoryThe FILE_HISTORY in use. If NULL, the main application file history is used.

Definition at line 568 of file eda_base_frame.cpp.

569 {
570  if( !aFileHistory )
571  aFileHistory = m_fileHistory;
572 
573  wxASSERT( aFileHistory );
574 
575  aFileHistory->AddFileToHistory( FullFileName );
576 
577  // Update the menubar to update the file history menu
578  if( GetMenuBar() )
579  {
580  ReCreateMenuBar();
581  GetMenuBar()->Refresh();
582  }
583 }
void AddFileToHistory(const wxString &aFile) override
Adds a file to the history.
Definition: filehistory.cpp:94
FILE_HISTORY * m_fileHistory
virtual void ReCreateMenuBar()
Recreates the menu bar.

References FILE_HISTORY::AddFileToHistory(), EDA_BASE_FRAME::m_fileHistory, and EDA_BASE_FRAME::ReCreateMenuBar().

Referenced by KICAD_MANAGER_FRAME::CreateNewProject(), SCH_EDIT_FRAME::importFile(), GERBVIEW_FRAME::LoadExcellonFiles(), GERBVIEW_FRAME::LoadGerberJobFile(), GERBVIEW_FRAME::loadListOfGerberAndDrillFiles(), PL_EDITOR_FRAME::LoadPageLayoutDescrFile(), KICAD_MANAGER_FRAME::LoadProject(), SCH_EDIT_FRAME::OnCloseWindow(), SCH_EDIT_FRAME::OpenProjectFiles(), PCB_EDIT_FRAME::OpenProjectFiles(), PCB_EDIT_FRAME::SavePcbFile(), SCH_EDIT_FRAME::SaveProject(), EDA_BASE_FRAME::SaveSettings(), and GERBVIEW_FRAME::unarchiveFiles().

◆ UpdateStatusBar()

virtual void EDA_BASE_FRAME::UpdateStatusBar ( )
inlinevirtualinherited

Update the status bar information.

The status bar can draw itself. This is not a drawing function per se, but rather updates lines of text held by the components within the status bar which is owned by the wxFrame.

Reimplemented in EDA_DRAW_FRAME, GERBVIEW_FRAME, PCB_BASE_FRAME, SCH_BASE_FRAME, and PL_EDITOR_FRAME.

Definition at line 480 of file eda_base_frame.h.

480 { }

Referenced by TOOL_MANAGER::UpdateUI().

Member Data Documentation

◆ KICAD_AUI_TB_STYLE

◆ m_AboutTitle

wxString EDA_BASE_FRAME::m_AboutTitle
protectedinherited

◆ m_actions

◆ m_addSignals

wxMenuItem* SIM_PLOT_FRAME_BASE::m_addSignals
protected

Definition at line 60 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_auimgr

◆ m_autoSaveInterval

◆ m_autoSaveState

bool EDA_BASE_FRAME::m_autoSaveState
protectedinherited

◆ m_autoSaveTimer

wxTimer* EDA_BASE_FRAME::m_autoSaveTimer
protectedinherited

◆ m_configName

wxString EDA_BASE_FRAME::m_configName
protectedinherited

◆ m_cursors

wxListCtrl* SIM_PLOT_FRAME_BASE::m_cursors
protected

Definition at line 88 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::onCursorUpdate(), and SIM_PLOT_FRAME_BASE().

◆ m_dragSelects

bool TOOLS_HOLDER::m_dragSelects
protectedinherited

◆ m_fileHistory

◆ m_fileMenu

wxMenu* SIM_PLOT_FRAME_BASE::m_fileMenu
protected

Definition at line 57 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_FlagModified

bool EDA_BASE_FRAME::m_FlagModified
protectedinherited

Definition at line 151 of file eda_base_frame.h.

◆ m_FlagSave

bool EDA_BASE_FRAME::m_FlagSave
protectedinherited

Definition at line 152 of file eda_base_frame.h.

◆ m_FramePos

◆ m_FrameSize

◆ m_hasAutoSave

bool EDA_BASE_FRAME::m_hasAutoSave
protectedinherited

◆ m_Ident

FRAME_T EDA_BASE_FRAME::m_Ident
protectedinherited

◆ m_immediateActions

bool TOOLS_HOLDER::m_immediateActions
protectedinherited

◆ m_infoBar

◆ m_mainMenu

wxMenuBar* SIM_PLOT_FRAME_BASE::m_mainMenu
protected

◆ m_modal

bool KIWAY_PLAYER::m_modal
protectedinherited

Definition at line 201 of file kiway_player.h.

Referenced by KIWAY_PLAYER::IsModal(), and KIWAY_PLAYER::SetModal().

◆ m_modal_loop

WX_EVENT_LOOP* KIWAY_PLAYER::m_modal_loop
protectedinherited

◆ m_modal_resultant_parent

wxWindow* KIWAY_PLAYER::m_modal_resultant_parent
protectedinherited

Definition at line 203 of file kiway_player.h.

Referenced by KIWAY_PLAYER::ShowModal().

◆ m_modal_ret_val

bool KIWAY_PLAYER::m_modal_ret_val
protectedinherited

◆ m_modal_string

wxString KIWAY_PLAYER::m_modal_string
protectedinherited

Definition at line 204 of file kiway_player.h.

Referenced by KIWAY_PLAYER::DismissModal(), and KIWAY_PLAYER::ShowModal().

◆ m_moveWarpsCursor

bool TOOLS_HOLDER::m_moveWarpsCursor
protectedinherited

◆ m_mruPath

◆ m_NormalFramePos

wxPoint EDA_BASE_FRAME::m_NormalFramePos
protectedinherited

◆ m_NormalFrameSize

wxSize EDA_BASE_FRAME::m_NormalFrameSize
protectedinherited

◆ m_panelConsole

wxPanel* SIM_PLOT_FRAME_BASE::m_panelConsole
protected

Definition at line 75 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_panelCursors

wxPanel* SIM_PLOT_FRAME_BASE::m_panelCursors
protected

Definition at line 86 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_panelCursorsAndTune

wxPanel* SIM_PLOT_FRAME_BASE::m_panelCursorsAndTune
protected

Definition at line 84 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_panelLeft

wxPanel* SIM_PLOT_FRAME_BASE::m_panelLeft
protected

Definition at line 69 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_panelSignals

wxPanel* SIM_PLOT_FRAME_BASE::m_panelSignals
protected

Definition at line 81 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_perspective

wxString EDA_BASE_FRAME::m_perspective
protectedinherited

Definition at line 135 of file eda_base_frame.h.

Referenced by EDA_BASE_FRAME::LoadWindowSettings().

◆ m_plotNotebook

◆ m_plotPanel

wxPanel* SIM_PLOT_FRAME_BASE::m_plotPanel
protected

Definition at line 72 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_probeSignals

wxMenuItem* SIM_PLOT_FRAME_BASE::m_probeSignals
protected

Definition at line 61 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_redoList

◆ m_runSimulation

wxMenuItem* SIM_PLOT_FRAME_BASE::m_runSimulation
protected

Definition at line 59 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_settings

wxMenuItem* SIM_PLOT_FRAME_BASE::m_settings
protected

Definition at line 64 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_settingsManager

SETTINGS_MANAGER* EDA_BASE_FRAME::m_settingsManager
protectedinherited

Definition at line 142 of file eda_base_frame.h.

Referenced by EDA_BASE_FRAME::GetSettingsManager().

◆ m_showNetlist

wxMenuItem* SIM_PLOT_FRAME_BASE::m_showNetlist
protected

Definition at line 63 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_sidePanel

wxPanel* SIM_PLOT_FRAME_BASE::m_sidePanel
protected

Definition at line 78 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_sideSizer

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_sideSizer
protected

Definition at line 79 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_signals

◆ m_simConsole

◆ m_simulationMenu

wxMenu* SIM_PLOT_FRAME_BASE::m_simulationMenu
protected

Definition at line 58 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_sizer11

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_sizer11
protected

Definition at line 70 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_sizerConsole

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_sizerConsole
protected

Definition at line 76 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_sizerMain

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_sizerMain
protected

Definition at line 66 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_sizerPlot

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_sizerPlot
protected

Definition at line 73 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_splitterLeftRight

wxSplitterWindow* SIM_PLOT_FRAME_BASE::m_splitterLeftRight
protected

◆ m_splitterPlotAndConsole

wxSplitterWindow* SIM_PLOT_FRAME_BASE::m_splitterPlotAndConsole
protected

◆ m_splitterSignals

wxSplitterWindow* SIM_PLOT_FRAME_BASE::m_splitterSignals
protected

◆ m_splitterTuneValues

wxSplitterWindow* SIM_PLOT_FRAME_BASE::m_splitterTuneValues
protected

◆ m_staticTextCursors

wxStaticText* SIM_PLOT_FRAME_BASE::m_staticTextCursors
protected

Definition at line 87 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_staticTextSignals

wxStaticText* SIM_PLOT_FRAME_BASE::m_staticTextSignals
protected

Definition at line 82 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_staticTextTune

wxStaticText* SIM_PLOT_FRAME_BASE::m_staticTextTune
protected

Definition at line 90 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().

◆ m_toolBar

wxToolBar* SIM_PLOT_FRAME_BASE::m_toolBar
protected

◆ m_toolDispatcher

◆ m_toolManager

TOOL_MANAGER* TOOLS_HOLDER::m_toolManager
protectedinherited

Definition at line 48 of file tools_holder.h.

Referenced by PCB_BASE_FRAME::ActivateGalCanvas(), GERBVIEW_FRAME::ActivateGalCanvas(), SCH_EDIT_FRAME::AddJunction(), EDA_BASE_FRAME::AddStandardHelpMenu(), EDA_DRAW_FRAME::AddStandardSubMenus(), SCH_EDIT_FRAME::AppendSchematic(), GERBVIEW_FRAME::Clear_DrawLayers(), SCH_EDIT_FRAME::ConvertPart(), EDA_3D_VIEWER::CreateMenuBar(), LIB_EDIT_FRAME::CreateNewPart(), CVPCB_MAINFRAME::CVPCB_MAINFRAME(), LIB_VIEW_FRAME::DClickOnCmpList(), SCH_EDIT_FRAME::DeleteJunction(), SCH_EDIT_FRAME::DisplayCurrentSheet(), LIB_EDIT_FRAME::emptyScreen(), GERBVIEW_FRAME::Erase_Current_DrawLayer(), SCH_EDIT_FRAME::ExecuteRemoteCommand(), PCB_EDIT_FRAME::ExecuteRemoteCommand(), FOOTPRINT_VIEWER_FRAME::FOOTPRINT_VIEWER_FRAME(), LIB_EDIT_FRAME::GetComponentFromRedoList(), LIB_EDIT_FRAME::GetComponentFromUndoList(), TOOLS_HOLDER::GetToolManager(), PL_EDITOR_FRAME::HardRedraw(), LIB_EDIT_FRAME::HardRedraw(), SCH_EDIT_FRAME::importFile(), PCB_BASE_FRAME::InstallPadOptionsFrame(), SCH_EDIT_FRAME::KiwayMailIn(), PCB_EDIT_FRAME::KiwayMailIn(), LIB_EDIT_FRAME::LoadComponentFromCurrentLib(), LIB_EDIT_FRAME::LoadOneLibraryPartAux(), LIB_EDIT_FRAME::LoadOneSymbol(), SCH_EDIT_FRAME::OnCloseWindow(), GERBVIEW_FRAME::OnCloseWindow(), LIB_EDIT_FRAME::OnExportBody(), LIB_EDIT_FRAME::OnImportBody(), PL_EDITOR_FRAME::OnNewPageLayout(), KICAD_MANAGER_FRAME::OnOpenFileInTextEditor(), EDA_DRAW_FRAME::OnSelectGrid(), LIB_EDIT_FRAME::OnSelectUnit(), EDA_DRAW_FRAME::OnSelectZoom(), SCH_EDIT_FRAME::OpenProjectFiles(), PANEL_PREV_3D::PANEL_PREV_3D(), TOOLS_HOLDER::PopTool(), TOOLS_HOLDER::PushTool(), SCH_EDIT_FRAME::PutDataInPreviousState(), LIB_VIEW_FRAME::ReCreateMenuBar(), KICAD_MANAGER_FRAME::ReCreateMenuBar(), FOOTPRINT_EDIT_FRAME::ReCreateMenuBar(), FOOTPRINT_VIEWER_FRAME::ReCreateMenuBar(), LIB_EDIT_FRAME::ReCreateMenuBar(), PL_EDITOR_FRAME::ReCreateMenuBar(), CVPCB_MAINFRAME::ReCreateMenuBar(), SCH_EDIT_FRAME::ReCreateMenuBar(), GERBVIEW_FRAME::ReCreateMenuBar(), PCB_EDIT_FRAME::ReCreateMenuBar(), PCB_EDIT_FRAME::ReCreateVToolbar(), CVPCB_MAINFRAME::refreshAfterComponentSearch(), SCH_BASE_FRAME::RefreshSelection(), FOOTPRINT_WIZARD_FRAME::ReloadFootprint(), LIB_EDIT_FRAME::RollbackPartFromUndo(), FOOTPRINT_EDIT_FRAME::SaveFootprintToBoard(), LIB_EDIT_FRAME::saveLibrary(), SCH_EDIT_FRAME::SchematicCleanUp(), GERBVIEW_FRAME::SetActiveLayer(), PCB_BASE_EDIT_FRAME::SetBoard(), LIB_EDIT_FRAME::SetCurPart(), LIB_VIEW_FRAME::SetSelectedComponent(), PL_EDITOR_FRAME::setupTools(), FOOTPRINT_EDIT_FRAME::setupTools(), LIB_VIEW_FRAME::setupTools(), GERBVIEW_FRAME::setupTools(), LIB_EDIT_FRAME::setupTools(), CVPCB_MAINFRAME::setupTools(), SCH_EDIT_FRAME::setupTools(), PCB_BASE_FRAME::unitsChangeRefresh(), DISPLAY_FOOTPRINTS_FRAME::updateView(), FOOTPRINT_WIZARD_FRAME::updateView(), FOOTPRINT_VIEWER_FRAME::updateView(), FOOTPRINT_EDIT_FRAME::updateView(), EDA_DRAW_FRAME::Zoom_Automatique(), CVPCB_MAINFRAME::~CVPCB_MAINFRAME(), DISPLAY_FOOTPRINTS_FRAME::~DISPLAY_FOOTPRINTS_FRAME(), EDA_DRAW_FRAME::~EDA_DRAW_FRAME(), FOOTPRINT_EDIT_FRAME::~FOOTPRINT_EDIT_FRAME(), FOOTPRINT_VIEWER_FRAME::~FOOTPRINT_VIEWER_FRAME(), FOOTPRINT_WIZARD_FRAME::~FOOTPRINT_WIZARD_FRAME(), GERBVIEW_FRAME::~GERBVIEW_FRAME(), KICAD_MANAGER_FRAME::~KICAD_MANAGER_FRAME(), LIB_EDIT_FRAME::~LIB_EDIT_FRAME(), LIB_VIEW_FRAME::~LIB_VIEW_FRAME(), PL_EDITOR_FRAME::~PL_EDITOR_FRAME(), and SCH_EDIT_FRAME::~SCH_EDIT_FRAME().

◆ m_toolStack

std::vector<std::string> TOOLS_HOLDER::m_toolStack
protectedinherited

◆ m_tunePanel

wxPanel* SIM_PLOT_FRAME_BASE::m_tunePanel
protected

◆ m_tuneSizer

wxBoxSizer* SIM_PLOT_FRAME_BASE::m_tuneSizer
protected

Definition at line 91 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::AddTuner(), and SIM_PLOT_FRAME_BASE().

◆ m_tuneValue

wxMenuItem* SIM_PLOT_FRAME_BASE::m_tuneValue
protected

Definition at line 62 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME::SIM_PLOT_FRAME(), and SIM_PLOT_FRAME_BASE().

◆ m_undoList

◆ m_UndoRedoCountMax

int EDA_BASE_FRAME::m_UndoRedoCountMax
protectedinherited

◆ m_userUnits

◆ m_viewMenu

wxMenu* SIM_PLOT_FRAME_BASE::m_viewMenu
protected

Definition at line 65 of file sim_plot_frame_base.h.

Referenced by SIM_PLOT_FRAME_BASE().


The documentation for this class was generated from the following files: