KiCad PCB EDA Suite
SCH::IFACE Struct Reference
Inheritance diagram for SCH::IFACE:
KIFACE_I KIFACE

Public Member Functions

 IFACE (const char *aName, KIWAY::FACE_T aType)
 
bool OnKifaceStart (PGM_BASE *aProgram, int aCtlBits) override
 Function OnKifaceStart is called just once shortly after the DSO is loaded. More...
 
void OnKifaceEnd () override
 Function OnKifaceEnd is called just once just before the DSO is to be unloaded. More...
 
wxWindow * CreateWindow (wxWindow *aParent, int aClassId, KIWAY *aKiway, int aCtlBits=0) override
 Function CreateWindow creates a wxWindow for the current project. More...
 
void * IfaceOrAddress (int aDataId) override
 Function IfaceOrAddress return a pointer to the requested object. More...
 
void SaveFileAs (const wxString &aProjectBasePath, const wxString &aProjectName, const wxString &aNewProjectBasePath, const wxString &aNewProjectName, const wxString &aSrcFilePath, wxString &aErrors) override
 Function SaveFileAs Saving a file under a different name is delegated to the various KIFACEs because the project doesn't know the internal format of the various files (which may have paths in them that need updating). More...
 
const wxString Name ()
 
wxConfigBase * KifaceSettings () const
 
int StartFlags () const
 Function StartFlags returns whatever was passed as aCtlBits to OnKifaceStart() More...
 
bool IsSingle () const
 Function IsSingle is this KIFACE_I running under single_top? More...
 
const wxString & GetHelpFileName () const
 Function GetHelpFileName returns just the basename portion of the current help file. More...
 
FILE_HISTORYGetFileHistory ()
 
SEARCH_STACKKifaceSearch ()
 Only for DSO specific 'non-library' files. More...
 

Protected Member Functions

bool start_common (int aCtlBits)
 Common things to do for a top program module, during OnKifaceStart(). More...
 
void end_common ()
 Common things to do for a top program module, during OnKifaceEnd();. More...
 

Detailed Description

Definition at line 55 of file eeschema.cpp.

Constructor & Destructor Documentation

◆ IFACE()

SCH::IFACE::IFACE ( const char *  aName,
KIWAY::FACE_T  aType 
)
inline

Definition at line 59 of file eeschema.cpp.

59  :
60  KIFACE_I( aName, aType )
61  {}
KIFACE_I(const char *aKifaceName, KIWAY::FACE_T aId)
Constructor.
Definition: kiface_i.h:78

Member Function Documentation

◆ CreateWindow()

wxWindow* SCH::IFACE::CreateWindow ( wxWindow *  aParent,
int  aClassId,
KIWAY aKIWAY,
int  aCtlBits = 0 
)
inlineoverridevirtual

Function CreateWindow creates a wxWindow for the current project.

The caller must cast the return value into the known type.

Parameters
aParentmay be NULL, or is otherwise the parent to connect under. If NULL then caller may want to connect the returned wxWindow into some hierarchy after this function returns.
aClassIdidentifies which wxFrame or wxDialog to retrieve, using a value known to the implementing KIFACE.
aKIWAYtells the window which KIWAY (and PROJECT) it is a participant in.
aCtlBitsconsists of bit flags from the set of KFCTL_* #defines above.
Returns
wxWindow* - and if not NULL, should be cast into the known type using and old school cast. dynamic_cast is problematic since it needs typeinfo probably not contained in the caller's link image.

Implements KIFACE_I.

Definition at line 67 of file eeschema.cpp.

68  {
69  switch( aClassId )
70  {
71  case FRAME_SCH:
72  {
73  SCH_EDIT_FRAME* frame = new SCH_EDIT_FRAME( aKiway, aParent );
74 
75  if( Kiface().IsSingle() )
76  {
77  // only run this under single_top, not under a project manager.
79  }
80 
81  return frame;
82  }
83 
85  {
86  LIB_EDIT_FRAME* frame = new LIB_EDIT_FRAME( aKiway, aParent );
87  return frame;
88  }
89 
90 #ifdef KICAD_SPICE
91  case FRAME_SIMULATOR:
92  {
93  SIM_PLOT_FRAME* frame = new SIM_PLOT_FRAME( aKiway, aParent );
94  return frame;
95  }
96 #endif
97  case FRAME_SCH_VIEWER:
99  {
100  LIB_VIEW_FRAME* frame = new LIB_VIEW_FRAME( aKiway, aParent, FRAME_T( aClassId ) );
101  return frame;
102  }
103 
105  InvokeSchEditSymbolLibTable( aKiway, aParent );
106  // Dialog has completed; nothing to return.
107  return nullptr;
108 
109  default:
110  return NULL;
111  }
112  }
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
void InvokeSchEditSymbolLibTable(KIWAY *aKiway, wxWindow *aParent)
Schematic editor (Eeschema) main window.
Symbol library viewer main window.
Definition: viewlib_frame.h:43
#define KICAD_SCH_PORT_SERVICE_NUMBER
Definition: eda_dde.h:42
bool IsSingle() const
Function IsSingle is this KIFACE_I running under single_top?
Definition: kiface_i.h:115
Implementing SIM_PLOT_FRAME_BASE.
The symbol library editor main window.
KIFACE_I & Kiface()
Global KIFACE_I "get" accessor.
Definition: eeschema.cpp:146
void CreateServer(int service, bool local=true)
Definition: eda_dde.cpp:49

References EDA_DRAW_FRAME::CreateServer(), DIALOG_SCH_LIBRARY_TABLE, FRAME_SCH, FRAME_SCH_LIB_EDITOR, FRAME_SCH_VIEWER, FRAME_SCH_VIEWER_MODAL, FRAME_SIMULATOR, InvokeSchEditSymbolLibTable(), KIFACE_I::IsSingle(), KICAD_SCH_PORT_SERVICE_NUMBER, and Kiface().

◆ end_common()

void KIFACE_I::end_common ( )
protectedinherited

Common things to do for a top program module, during OnKifaceEnd();.

Definition at line 100 of file kiface_i.cpp.

101 {
102  m_bm.End();
103 }
BIN_MOD m_bm
Definition: kiface_i.h:132
void End()
Definition: bin_mod.cpp:63

References BIN_MOD::End(), and KIFACE_I::m_bm.

Referenced by CV::IFACE::OnKifaceEnd(), KIFACE_I::OnKifaceEnd(), PGE::IFACE::OnKifaceEnd(), GERBV::IFACE::OnKifaceEnd(), OnKifaceEnd(), and PCB::IFACE::OnKifaceEnd().

◆ GetFileHistory()

◆ GetHelpFileName()

const wxString& KIFACE_I::GetHelpFileName ( ) const
inlineinherited

Function GetHelpFileName returns just the basename portion of the current help file.

Definition at line 121 of file kiface_i.h.

121 { return m_bm.m_help_file; }
BIN_MOD m_bm
Definition: kiface_i.h:132
wxString m_help_file
Definition: bin_mod.h:61

References KIFACE_I::m_bm, and BIN_MOD::m_help_file.

Referenced by EDA_BASE_FRAME::help_name().

◆ IfaceOrAddress()

void* SCH::IFACE::IfaceOrAddress ( int  aDataId)
inlineoverridevirtual

Function IfaceOrAddress return a pointer to the requested object.

The safest way to use this is to retrieve a pointer to a static instance of an interface, similar to how the KIFACE interface is exported. But if you know what you are doing use it to retrieve anything you want.

Parameters
aDataIdidentifies which object you want the address of.
Returns
void* - and must be cast into the know type.

Implements KIFACE_I.

Definition at line 122 of file eeschema.cpp.

123  {
124  return NULL;
125  }

◆ IsSingle()

◆ KifaceSearch()

SEARCH_STACK& KIFACE_I::KifaceSearch ( )
inlineinherited

Only for DSO specific 'non-library' files.

(The library search path is in the PROJECT class.)

Definition at line 127 of file kiface_i.h.

127 { return m_bm.m_search; }
BIN_MOD m_bm
Definition: kiface_i.h:132
SEARCH_STACK m_search
Definition: bin_mod.h:63

References KIFACE_I::m_bm, and BIN_MOD::m_search.

Referenced by CVPCB_MAINFRAME::buildEquivalenceList(), WS_DATA_MODEL::MakeFullFileName(), WS_DATA_MODEL::MakeShortFileName(), and EDA_BASE_FRAME::sys_search().

◆ KifaceSettings()

wxConfigBase* KIFACE_I::KifaceSettings ( ) const
inlineinherited

Definition at line 103 of file kiface_i.h.

103 { return m_bm.m_config.get(); }
BIN_MOD m_bm
Definition: kiface_i.h:132
std::unique_ptr< wxConfigBase > m_config
maybe from $HOME/.${m_name}
Definition: bin_mod.h:59

References KIFACE_I::m_bm, and BIN_MOD::m_config.

Referenced by AUTOPLACER::AUTOPLACER(), EDA_BASE_FRAME::config(), DIALOG_BOM::DIALOG_BOM(), DIALOG_CHOOSE_COMPONENT::DIALOG_CHOOSE_COMPONENT(), DIALOG_CHOOSE_FOOTPRINT::DIALOG_CHOOSE_FOOTPRINT(), DIALOG_CLEANUP_TRACKS_AND_VIAS::DIALOG_CLEANUP_TRACKS_AND_VIAS(), DIALOG_COPPER_ZONE::DIALOG_COPPER_ZONE(), DIALOG_DRC_CONTROL::DIALOG_DRC_CONTROL(), DIALOG_EDIT_COMPONENT_IN_LIBRARY::DIALOG_EDIT_COMPONENT_IN_LIBRARY(), DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::DIALOG_EDIT_COMPONENT_IN_SCHEMATIC(), DIALOG_EXPORT_3DFILE::DIALOG_EXPORT_3DFILE(), DIALOG_EXPORT_IDF3::DIALOG_EXPORT_IDF3(), DIALOG_EXPORT_STEP::DIALOG_EXPORT_STEP(), DIALOG_EXPORT_SVG::DIALOG_EXPORT_SVG(), DIALOG_FOOTPRINT_BOARD_EDITOR::DIALOG_FOOTPRINT_BOARD_EDITOR(), DIALOG_FOOTPRINT_FP_EDITOR::DIALOG_FOOTPRINT_FP_EDITOR(), DIALOG_FOOTPRINT_WIZARD_LIST::DIALOG_FOOTPRINT_WIZARD_LIST(), DIALOG_GENDRILL::DIALOG_GENDRILL(), DIALOG_IMPORT_GFX::DIALOG_IMPORT_GFX(), DIALOG_KEEPOUT_AREA_PROPERTIES::DIALOG_KEEPOUT_AREA_PROPERTIES(), DIALOG_LIB_EDIT_PIN_TABLE::DIALOG_LIB_EDIT_PIN_TABLE(), DIALOG_NETLIST::DIALOG_NETLIST(), DIALOG_PLOT::DIALOG_PLOT(), DIALOG_PLOT_SCHEMATIC::DIALOG_PLOT_SCHEMATIC(), DIALOG_PRINT_GERBVIEW::DIALOG_PRINT_GERBVIEW(), DIALOG_PRINT_PCBNEW::DIALOG_PRINT_PCBNEW(), DIALOG_RESCUE_EACH::DIALOG_RESCUE_EACH(), DIALOG_UPDATE_PCB::DIALOG_UPDATE_PCB(), FOOTPRINT_EDIT_FRAME::Export_Module(), FOOTPRINT_EDIT_FRAME::Import_Module(), DIALOG_PAGES_SETTINGS::initDialog(), DIALOG_GEN_FOOTPRINT_POSITION::initDialog(), DIALOG_ANNOTATE::InitValues(), LIB_TREE_MODEL_ADAPTER::LIB_TREE_MODEL_ADAPTER(), EDA_DRAW_FRAME::LoadCanvasTypeSetting(), NETLIST_DIALOG::NETLIST_DIALOG(), FOOTPRINT_PREVIEW_PANEL::New(), LAYERS_MAP_DIALOG::OnGetSetup(), OnKifaceEnd(), OnKifaceStart(), LAYERS_MAP_DIALOG::OnStoreSetup(), SCH_EDIT_FRAME::OpenProjectFiles(), EDA_DRAW_FRAME::saveCanvasTypeSetting(), DIALOG_NON_COPPER_ZONES_EDITOR::TransferDataFromWindow(), and DIALOG_PAGES_SETTINGS::~DIALOG_PAGES_SETTINGS().

◆ Name()

const wxString KIFACE_I::Name ( )
inlineinherited

Definition at line 101 of file kiface_i.h.

101 { return wxString::FromUTF8( m_bm.m_name ); }
BIN_MOD m_bm
Definition: kiface_i.h:132
const char * m_name
name of this binary module, static C string.
Definition: bin_mod.h:57

References KIFACE_I::m_bm, and BIN_MOD::m_name.

◆ OnKifaceEnd()

void IFACE::OnKifaceEnd ( )
overridevirtual

Function OnKifaceEnd is called just once just before the DSO is to be unloaded.

It is called before static C++ destructors are called. A default implementation is supplied.

Implements KIFACE.

Definition at line 293 of file eeschema.cpp.

294 {
296  end_common();
297 }
wxConfigBase * KifaceSettings() const
Definition: kiface_i.h:103
void end_common()
Common things to do for a top program module, during OnKifaceEnd();.
Definition: kiface_i.cpp:100
static PARAM_CFG_ARRAY & cfg_params()
Definition: eeschema.cpp:187
void wxConfigSaveSetups(wxConfigBase *aCfg, const PARAM_CFG_ARRAY &aList)
Function wxConfigSaveSetups writes aList of PARAM_CFG_ARRAY elements to save configuration values to ...

References cfg_params(), KIFACE_I::end_common(), KIFACE_I::KifaceSettings(), and wxConfigSaveSetups().

◆ OnKifaceStart()

bool IFACE::OnKifaceStart ( PGM_BASE aProgram,
int  aCtlBits 
)
overridevirtual

Function OnKifaceStart is called just once shortly after the DSO is loaded.

It is the second function called, immediately after the KIFACE_GETTER(). However before either of those, static C++ constructors are called. The DSO implementation should do process level initialization here, not project specific since there will be multiple projects open eventually.

Parameters
aProgramis the process block: PGM_BASE*
aCtlBitsconsists of bit flags from the set of KFCTL_* #defines above.
Returns
bool - true if DSO initialized OK, false if not. When returning false, the loader may optionally decide to terminate the process or not, but will not put out any UI because that is the duty of this function to say why it is returning false. Never return false without having reported to the UI why.

Implements KIFACE_I.

Definition at line 241 of file eeschema.cpp.

242 {
243  // This is process-level-initialization, not project-level-initialization of the DSO.
244  // Do nothing in here pertinent to a project!
245 
246  start_common( aCtlBits );
247 
248  // Give a default colour for all layers (actual color will be initialized by config)
249  for( SCH_LAYER_ID ii = SCH_LAYER_ID_START; ii < SCH_LAYER_ID_END; ++ii )
250  SetLayerColor( COLOR4D( DARKGRAY ), ii );
251 
254 
256 
258 
259  if( !fn.FileExists() )
260  {
261  DIALOG_GLOBAL_SYM_LIB_TABLE_CONFIG fpDialog( NULL );
262 
263  fpDialog.ShowModal();
264  }
265  else
266  {
267  try
268  {
269  // The global table is not related to a specific project. All projects
270  // will use the same global table. So the KIFACE::OnKifaceStart() contract
271  // of avoiding anything project specific is not violated here.
273  return false;
274  }
275  catch( const IO_ERROR& ioe )
276  {
277  // if we are here, a incorrect global symbol library table was found.
278  // Incorrect global symbol library table is not a fatal error:
279  // the user just has to edit the (partially) loaded table.
280  wxString msg = _(
281  "An error occurred attempting to load the global symbol library table.\n"
282  "Please edit this global symbol library table in Preferences menu."
283  );
284 
285  DisplayErrorMessage( NULL, msg, ioe.What() );
286  }
287  }
288 
289  return true;
290 }
static SYMBOL_LIB_TABLE & GetGlobalLibTable()
bool start_common(int aCtlBits)
Common things to do for a top program module, during OnKifaceStart().
Definition: kiface_i.cpp:90
void SetLayerColor(COLOR4D aColor, SCH_LAYER_ID aLayer)
Definition: eeschema.cpp:174
void DisplayErrorMessage(wxWindow *aParent, const wxString &aText, const wxString &aExtraInfo)
Display an error message with aMessage.
Definition: confirm.cpp:249
wxConfigBase * KifaceSettings() const
Definition: kiface_i.h:103
static bool LoadGlobalTable(SYMBOL_LIB_TABLE &aTable)
Load the global symbol library table into aTable.
virtual const wxString What() const
A composite of Problem() and Where()
Definition: exceptions.cpp:33
static PARAM_CFG_ARRAY & cfg_params()
Definition: eeschema.cpp:187
SCH_LAYER_ID
Eeschema drawing layers.
#define _(s)
Definition: colors.h:49
Definition: colors.h:45
void wxConfigLoadSetups(wxConfigBase *aCfg, const PARAM_CFG_ARRAY &aList)
Function wxConfigLoadSetups uses aList of PARAM_CFG_ARRAY elements to load configuration values from ...
Struct IO_ERROR is a class used to hold an error message and may be used when throwing exceptions con...
Definition: ki_exception.h:76
static wxString GetGlobalTableFileName()
Fetch the global symbol library table file name.
Class COLOR4D is the color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:39

References _, BLACK, cfg_params(), DARKGRAY, DisplayErrorMessage(), SYMBOL_LIB_TABLE::GetGlobalLibTable(), SYMBOL_LIB_TABLE::GetGlobalTableFileName(), KIFACE_I::KifaceSettings(), LAYER_SCHEMATIC_BACKGROUND, LAYER_SCHEMATIC_CURSOR, SYMBOL_LIB_TABLE::LoadGlobalTable(), SCH_LAYER_ID_END, SCH_LAYER_ID_START, SetLayerColor(), KIFACE_I::start_common(), IO_ERROR::What(), WHITE, and wxConfigLoadSetups().

◆ SaveFileAs()

void IFACE::SaveFileAs ( const wxString &  aProjectBasePath,
const wxString &  aProjectName,
const wxString &  aNewProjectBasePath,
const wxString &  aNewProjectName,
const wxString &  aSrcFilePath,
wxString &  aErrors 
)
override

Function SaveFileAs Saving a file under a different name is delegated to the various KIFACEs because the project doesn't know the internal format of the various files (which may have paths in them that need updating).

Definition at line 312 of file eeschema.cpp.

315 {
316  wxFileName destFile( aSrcFilePath );
317  wxString destPath = destFile.GetPath();
318  wxString ext = destFile.GetExt();
319 
320  if( destPath.StartsWith( aProjectBasePath ) )
321  {
322  destPath.Replace( aProjectBasePath, aNewProjectBasePath, false );
323  destFile.SetPath( destPath );
324  }
325 
326  if( ext == "sch" || ext == "sch-bak" )
327  {
328  if( destFile.GetName() == aProjectName )
329  destFile.SetName( aNewProjectName );
330 
331  // Sheet paths when auto-generated are relative to the root, so those will stay
332  // pointing to whatever they were pointing at.
333  // The author can create their own absolute and relative sheet paths. Absolute
334  // sheet paths aren't an issue, and relative ones will continue to work as long
335  // as the author didn't include any '..'s. If they did, it's still not clear
336  // whether they should be adjusted or not (as the author may be duplicating an
337  // entire tree with several projects within it), so we leave this as an exercise
338  // to the author.
339 
340  CopyFile( aSrcFilePath, destFile.GetFullPath(), aErrors );
341  }
342  else if( ext == "sym" )
343  {
344  // Symbols are not project-specific. Keep their source names.
345  CopyFile( aSrcFilePath, destFile.GetFullPath(), aErrors );
346  }
347  else if( ext == "lib" )
348  {
349  if( destFile.GetName() == aProjectName )
350  destFile.SetName( aNewProjectName );
351  else if( destFile.GetName() == aProjectName + "-cache" )
352  destFile.SetName( aNewProjectName + "-cache" );
353  else if( destFile.GetName() == aProjectName + "-rescue" )
354  destFile.SetName( aNewProjectName + "-rescue" );
355 
356  CopyFile( aSrcFilePath, destFile.GetFullPath(), aErrors );
357  }
358  else if( ext == "net" )
359  {
360  bool success = false;
361 
362  if( destFile.GetName() == aProjectName )
363  destFile.SetName( aNewProjectName );
364 
365  try
366  {
367  SEXPR::PARSER parser;
368  std::unique_ptr<SEXPR::SEXPR> sexpr( parser.ParseFromFile( TO_UTF8( aSrcFilePath ) ) );
369 
370  traverseSEXPR( sexpr.get(), [&]( SEXPR::SEXPR* node )
371  {
372  if( node->IsList() && node->GetNumberOfChildren() > 1
373  && node->GetChild( 0 )->IsSymbol()
374  && node->GetChild( 0 )->GetSymbol() == "source" )
375  {
376  auto pathNode = dynamic_cast<SEXPR::SEXPR_STRING*>( node->GetChild( 1 ) );
377  auto symNode = dynamic_cast<SEXPR::SEXPR_SYMBOL*>( node->GetChild( 1 ) );
378  wxString path;
379 
380  if( pathNode )
381  path = pathNode->m_value;
382  else if( symNode )
383  path = symNode->m_value;
384 
385  if( path == aProjectName + ".sch" )
386  path = aNewProjectName + ".sch";
387  else if( path == aProjectBasePath + "/" + aProjectName + ".sch" )
388  path = aNewProjectBasePath + "/" + aNewProjectName + ".sch";
389  else if( path.StartsWith( aProjectBasePath ) )
390  path.Replace( aProjectBasePath, aNewProjectBasePath, false );
391 
392  if( pathNode )
393  pathNode->m_value = path;
394  else if( symNode )
395  symNode->m_value = path;
396  }
397  } );
398 
399  wxFile destNetList( destFile.GetFullPath(), wxFile::write );
400 
401  if( destNetList.IsOpened() )
402  success = destNetList.Write( sexpr->AsString( 0 ) );
403 
404  // wxFile dtor will close the file
405  }
406  catch( ... )
407  {
408  success = false;
409  }
410 
411  if( !success )
412  {
413  wxString msg;
414 
415  if( !aErrors.empty() )
416  aErrors += "\n";
417 
418  msg.Printf( _( "Cannot copy file \"%s\"." ), destFile.GetFullPath() );
419  aErrors += msg;
420  }
421  }
422  else if( destFile.GetName() == "sym-lib-table" )
423  {
424  SYMBOL_LIB_TABLE symbolLibTable;
425  symbolLibTable.Load( aSrcFilePath );
426 
427  for( unsigned i = 0; i < symbolLibTable.GetCount(); i++ )
428  {
429  LIB_TABLE_ROW& row = symbolLibTable.At( i );
430  wxString uri = row.GetFullURI();
431 
432  uri.Replace( "/" + aProjectName + "-cache.lib", "/" + aNewProjectName + "-cache.lib" );
433  uri.Replace( "/" + aProjectName + "-rescue.lib", "/" + aNewProjectName + "-rescue.lib" );
434  uri.Replace( "/" + aProjectName + ".lib", "/" + aNewProjectName + ".lib" );
435 
436  row.SetFullURI( uri );
437  }
438 
439  try
440  {
441  symbolLibTable.Save( destFile.GetFullPath() );
442  }
443  catch( ... )
444  {
445  wxString msg;
446 
447  if( !aErrors.empty() )
448  aErrors += "\n";
449 
450  msg.Printf( _( "Cannot copy file \"%s\"." ), destFile.GetFullPath() );
451  aErrors += msg;
452  }
453  }
454  else
455  {
456  wxFAIL_MSG( "Unexpected filetype for Eeschema::SaveFileAs()" );
457  }
458 }
static void traverseSEXPR(SEXPR::SEXPR *aNode, const std::function< void(SEXPR::SEXPR *)> &aVisitor)
Definition: eeschema.cpp:299
Hold a record identifying a library accessed by the appropriate plug in object in the LIB_TABLE.
unsigned GetCount() const
Get the number of rows contained in the table.
void CopyFile(const wxString &aSrcPath, const wxString &aDestPath, wxString &aErrors)
Function CopyFile.
Definition: gestfich.cpp:362
const wxString GetFullURI(bool aSubstituted=false) const
Return the full location specifying URI for the LIB, either in original UI form or in environment var...
#define TO_UTF8(wxstring)
Macro TO_UTF8 converts a wxString to a UTF8 encoded C string for all wxWidgets build modes.
Definition: macros.h:48
void Load(const wxString &aFileName)
Load the library table using the path defined by aFileName aFallBackTable.
#define _(s)
void SetFullURI(const wxString &aFullURI)
Change the full URI for the library.
LIB_TABLE_ROW & At(unsigned aIndex)
Get the 'n'th LIB_TABLE_ROW object.
size_t i
Definition: json11.cpp:649
void Save(const wxString &aFileName) const
Write this library table to aFileName in s-expression form.

◆ start_common()

bool KIFACE_I::start_common ( int  aCtlBits)
protectedinherited

Common things to do for a top program module, during OnKifaceStart().

Definition at line 90 of file kiface_i.cpp.

91 {
92  m_start_flags = aCtlBits;
93  m_bm.Init();
95 
96  return true;
97 }
KIWAY::FACE_T m_id
Definition: kiface_i.h:130
void Init()
Definition: bin_mod.cpp:38
BIN_MOD m_bm
Definition: kiface_i.h:132
int m_start_flags
flags provided in OnKifaceStart()
Definition: kiface_i.h:134
SEARCH_STACK m_search
Definition: bin_mod.h:63
static void setSearchPaths(SEARCH_STACK *aDst, KIWAY::FACE_T aId)
Initialize aDst SEARCH_STACK with KIFACE (DSO) specific settings.
Definition: kiface_i.cpp:38

References BIN_MOD::Init(), KIFACE_I::m_bm, KIFACE_I::m_id, BIN_MOD::m_search, KIFACE_I::m_start_flags, and setSearchPaths().

Referenced by CV::IFACE::OnKifaceStart(), PGE::IFACE::OnKifaceStart(), GERBV::IFACE::OnKifaceStart(), OnKifaceStart(), and PCB::IFACE::OnKifaceStart().

◆ StartFlags()

int KIFACE_I::StartFlags ( ) const
inlineinherited

Function StartFlags returns whatever was passed as aCtlBits to OnKifaceStart()

Definition at line 109 of file kiface_i.h.

109 { return m_start_flags; }
int m_start_flags
flags provided in OnKifaceStart()
Definition: kiface_i.h:134

References KIFACE_I::m_start_flags.


The documentation for this struct was generated from the following file: