KiCad PCB EDA Suite
kicad.cpp File Reference

Main KiCad project manager file. More...

#include <wx/filename.h>
#include <wx/log.h>
#include <wx/app.h>
#include <wx/stdpaths.h>
#include <wx/msgdlg.h>
#include <filehistory.h>
#include <hotkeys_basic.h>
#include <kiway.h>
#include <paths.h>
#include <settings/settings_manager.h>
#include <systemdirsappend.h>
#include <wildcards_and_files_ext.h>
#include <stdexcept>
#include "pgm_kicad.h"
#include "kicad_manager_frame.h"
#include "kicad_settings.h"
#include <kiface_i.h>

Go to the source code of this file.

Classes

struct  APP_KICAD
 Not publicly visible because most of the action is in PGM_KICAD these days. More...
 

Functions

KIFACE_IKiface ()
 Global KIFACE_I "get" accessor. More...
 
PGM_BASEPgm ()
 The global Program "get" accessor. More...
 
PGM_BASEPgmOrNull ()
 similar to PGM_BASE& Pgm(), but return a reference that can be nullptr when running a shared lib from a script, not from a kicad appl More...
 
PGM_KICADPgmTop ()
 
PROJECTPrj ()
 

Variables

static PGM_KICAD program
 

Detailed Description

Main KiCad project manager file.

Definition in file kicad.cpp.

Function Documentation

◆ Kiface()

KIFACE_I& Kiface ( )

Global KIFACE_I "get" accessor.

Definition at line 58 of file kicad.cpp.

59 {
60  // This function should never be called. It is only referenced from
61  // EDA_BASE_FRAME::config() and this is only provided to satisfy the linker,
62  // not to be actually called.
63  wxLogFatalError( wxT( "Unexpected call to Kiface() in kicad/kicad.cpp" ) );
64 
65  throw std::logic_error( "Unexpected call to Kiface() in kicad/kicad.cpp" );
66 }

◆ Pgm()

PGM_BASE& Pgm ( )

The global Program "get" accessor.

Implemented in: 1) common/single_top.cpp, 2) kicad/kicad.cpp, and 3) scripting/kiway.i

Definition at line 72 of file kicad.cpp.

73 {
74  return program;
75 }
static PGM_KICAD program
Definition: kicad.cpp:69

References program.

Referenced by APP_KICAD::FilterEvent().

◆ PgmOrNull()

PGM_BASE* PgmOrNull ( )

similar to PGM_BASE& Pgm(), but return a reference that can be nullptr when running a shared lib from a script, not from a kicad appl

Definition at line 79 of file kicad.cpp.

80 {
81  return &program;
82 }
static PGM_KICAD program
Definition: kicad.cpp:69

References program.

◆ PgmTop()

PGM_KICAD& PgmTop ( )

Definition at line 85 of file kicad.cpp.

86 {
87  return program;
88 }
static PGM_KICAD program
Definition: kicad.cpp:69

References program.

Referenced by KICAD_MANAGER_FRAME::config(), KICAD_MANAGER_FRAME::help_name(), and KICAD_MANAGER_FRAME::sys_search().

◆ Prj()

Variable Documentation

◆ program

PGM_KICAD program
static

Definition at line 69 of file kicad.cpp.

Referenced by APP_KICAD::OnExit(), APP_KICAD::OnInit(), Pgm(), PgmOrNull(), and PgmTop().