KiCad PCB EDA Suite
pcbnew.h File Reference
#include <fctsys.h>
#include <base_struct.h>
#include <dlist.h>
#include <convert_to_biu.h>
#include <layers_id_colors_and_visibility.h>

Go to the source code of this file.

Macros

#define ARC_APPROX_SEGMENTS_COUNT_LOW_DEF   16
 
#define ARC_APPROX_SEGMENTS_COUNT_HIGHT_DEF   32
 
#define SEGMENT_COUNT_CROSSOVER   24
 
#define CURSEUR_ON_GRILLE   (0 << 0)
 
#define CURSEUR_OFF_GRILLE   (1 << 0)
 
#define IGNORE_LOCKED   (1 << 1)
 if module is locked, do not select for single module operation More...
 
#define MATCH_LAYER   (1 << 2)
 if module not on current layer, do not select More...
 
#define VISIBLE_ONLY   (1 << 3)
 if module not on a visible layer, do not select More...
 
#define DIM_ANCRE_MODULE   3
 
#define TEXTS_MIN_SIZE   Mils2iu( 5 )
 Minimum text size in Pcbnew units value (5 mils) More...
 
#define TEXTS_MAX_SIZE   Mils2iu( 1000 )
 Maximum text size in Pcbnew units value (1 inch) ) More...
 
#define TEXTS_MAX_WIDTH   Mils2iu( 500 )
 Maximum text width in Pcbnew units value (0.5 inches) More...
 
#define FORCE_SKETCH   ( IS_DRAGGED | IN_EDIT )
 
#define g_CurrentTrackSegment   g_CurrentTrackList.GetLast()
 most recently created segment More...
 
#define g_FirstTrackSegment   g_CurrentTrackList.GetFirst()
 first segment created More...
 

Enumerations

enum  ENDPOINT_T { ENDPOINT_START = 0, ENDPOINT_END = 1 }
 Flag used in locate routines (from which endpoint work) More...
 

Functions

void PythonPluginsReloadBase ()
 Helper function PythonPluginsReloadBase Reload Python plugins if they are newer than the already loaded, and load new plugins if any It calls the LoadPlugins(bundlepath) Python method see kicadplugins.i. More...
 

Variables

enum ENDPOINT_T kiface
 
wxString g_DocModulesFileName
 
bool g_Raccord_45_Auto
 
bool g_Alternate_Track_Posture
 
PCB_LAYER_ID g_Route_Layer_TOP
 
PCB_LAYER_ID g_Route_Layer_BOTTOM
 
bool g_TwoSegmentTrackBuild
 
int g_MagneticPadOption
 
int g_MagneticTrackOption
 
wxPoint g_Offset_Module
 
DLIST< TRACKg_CurrentTrackList
 

Macro Definition Documentation

#define ARC_APPROX_SEGMENTS_COUNT_HIGHT_DEF   32
#define ARC_APPROX_SEGMENTS_COUNT_LOW_DEF   16
#define CURSEUR_OFF_GRILLE   (1 << 0)

Definition at line 51 of file pcbnew.h.

Referenced by GERBVIEW_FRAME::OnLeftClick(), and GERBVIEW_FRAME::OnRightClick().

#define CURSEUR_ON_GRILLE   (0 << 0)

Definition at line 50 of file pcbnew.h.

Referenced by GERBVIEW_FRAME::Locate().

#define DIM_ANCRE_MODULE   3

Definition at line 63 of file pcbnew.h.

Referenced by MODULE::Draw().

#define FORCE_SKETCH   ( IS_DRAGGED | IN_EDIT )
#define g_FirstTrackSegment   g_CurrentTrackList.GetFirst()
#define IGNORE_LOCKED   (1 << 1)

if module is locked, do not select for single module operation

Definition at line 53 of file pcbnew.h.

#define MATCH_LAYER   (1 << 2)

if module not on current layer, do not select

Definition at line 54 of file pcbnew.h.

#define SEGMENT_COUNT_CROSSOVER   24
#define TEXTS_MAX_SIZE   Mils2iu( 1000 )

Maximum text size in Pcbnew units value (1 inch) )

Definition at line 67 of file pcbnew.h.

Referenced by BOARD_DESIGN_SETTINGS::AppendConfigs().

#define TEXTS_MAX_WIDTH   Mils2iu( 500 )

Maximum text width in Pcbnew units value (0.5 inches)

Definition at line 68 of file pcbnew.h.

Referenced by BOARD_DESIGN_SETTINGS::AppendConfigs(), and DIALOG_PCB_TEXT_PROPERTIES::TransferDataFromWindow().

#define TEXTS_MIN_SIZE   Mils2iu( 5 )

Minimum text size in Pcbnew units value (5 mils)

Definition at line 66 of file pcbnew.h.

Referenced by BOARD_DESIGN_SETTINGS::AppendConfigs(), DIALOG_EDIT_FPTEXT::TransferDataFromWindow(), and DIALOG_PCB_TEXT_PROPERTIES::TransferDataFromWindow().

#define VISIBLE_ONLY   (1 << 3)

if module not on a visible layer, do not select

Definition at line 55 of file pcbnew.h.

Enumeration Type Documentation

enum ENDPOINT_T

Flag used in locate routines (from which endpoint work)

Enumerator
ENDPOINT_START 
ENDPOINT_END 

Definition at line 58 of file pcbnew.h.

58  {
59  ENDPOINT_START = 0,
60  ENDPOINT_END = 1
61 };

Function Documentation

void PythonPluginsReloadBase ( )

Helper function PythonPluginsReloadBase Reload Python plugins if they are newer than the already loaded, and load new plugins if any It calls the LoadPlugins(bundlepath) Python method see kicadplugins.i.

Definition at line 283 of file pcbnew.cpp.

References PyScriptingPath(), and TO_UTF8.

Referenced by PCB_EDIT_FRAME::PythonPluginsReload(), and FOOTPRINT_WIZARD_FRAME::ReCreateVToolbar().

284 {
285 #if defined(KICAD_SCRIPTING)
286  //Reload plugin list: reload Python plugins if they are newer than
287  // the already loaded, and load new plugins
288  char cmd[1024];
289 
290  snprintf( cmd, sizeof(cmd),
291  "pcbnew.LoadPlugins(\"%s\")", TO_UTF8( PyScriptingPath() ) );
292 
293  PyLOCK lock;
294 
295  // ReRun the Python method pcbnew.LoadPlugins
296  // (already called when starting Pcbnew)
297  PyRun_SimpleString( cmd );
298 #endif
299 }
#define TO_UTF8(wxstring)
Macro TO_UTF8 converts a wxString to a UTF8 encoded C string for all wxWidgets build modes...
Definition: macros.h:47
wxString PyScriptingPath()
Find the Python scripting path.

Variable Documentation

bool g_Alternate_Track_Posture

Definition at line 71 of file pcbnew.cpp.

Referenced by ComputeBreakPoint(), and PCB_EDIT_FRAME::Process_Special_Functions().

wxString g_DocModulesFileName

Definition at line 81 of file pcbnew.cpp.

Referenced by PCB_EDIT_FRAME::Process_Special_Functions().

int g_MagneticPadOption
int g_MagneticTrackOption
bool g_Raccord_45_Auto

Definition at line 72 of file pcbnew.cpp.

Referenced by PCB_EDIT_FRAME::Begin_Route().

bool g_TwoSegmentTrackBuild
enum ENDPOINT_T kiface