KiCad PCB EDA Suite
Loading...
Searching...
No Matches
PYTHON_FOOTPRINT_WIZARD Class Reference

#include <pcbnew_footprint_wizards.h>

Inheritance diagram for PYTHON_FOOTPRINT_WIZARD:
FOOTPRINT_WIZARD

Public Member Functions

 PYTHON_FOOTPRINT_WIZARD (PyObject *wizard)
 
 ~PYTHON_FOOTPRINT_WIZARD ()
 
wxString GetName () override
 
wxString GetImage () override
 
wxString GetDescription () override
 
int GetNumParameterPages () override
 
wxString GetParameterPageName (int aPage) override
 
wxArrayString GetParameterNames (int aPage) override
 
wxArrayString GetParameterTypes (int aPage) override
 
wxArrayString GetParameterValues (int aPage) override
 
wxArrayString GetParameterErrors (int aPage) override
 
wxString SetParameterValues (int aPage, wxArrayString &aValues) override
 
FOOTPRINTGetFootprint (wxString *aMessages) override
 Build the footprint itself and returns it to the caller function.
 
void * GetObject () override
 Get the object from where this wizard constructs.
 
wxArrayString GetParameterHints (int aPage) override
 
wxArrayString GetParameterDesignators (int aPage=0) override
 
void ResetParameters () override
 Reset all wizard parameters to default values.
 
void register_wizard ()
 The standard method of a "FOOTPRINT_WIZARD" to register itself into the FOOTPRINT_WIZARD_LIST singleton manager.
 

Private Member Functions

PyObject * CallMethod (const char *aMethod, PyObject *aArglist=nullptr)
 
wxString CallRetStrMethod (const char *aMethod, PyObject *aArglist=nullptr)
 
wxArrayString CallRetArrayStrMethod (const char *aMethod, PyObject *aArglist=nullptr)
 

Private Attributes

PyObject * m_PyWizard
 

Detailed Description

Definition at line 41 of file pcbnew_footprint_wizards.h.

Constructor & Destructor Documentation

◆ PYTHON_FOOTPRINT_WIZARD()

PYTHON_FOOTPRINT_WIZARD::PYTHON_FOOTPRINT_WIZARD ( PyObject *  wizard)

Definition at line 37 of file pcbnew_footprint_wizards.cpp.

References m_PyWizard.

◆ ~PYTHON_FOOTPRINT_WIZARD()

PYTHON_FOOTPRINT_WIZARD::~PYTHON_FOOTPRINT_WIZARD ( )

Definition at line 46 of file pcbnew_footprint_wizards.cpp.

References m_PyWizard.

Member Function Documentation

◆ CallMethod()

PyObject * PYTHON_FOOTPRINT_WIZARD::CallMethod ( const char *  aMethod,
PyObject *  aArglist = nullptr 
)
private

◆ CallRetArrayStrMethod()

wxArrayString PYTHON_FOOTPRINT_WIZARD::CallRetArrayStrMethod ( const char *  aMethod,
PyObject *  aArglist = nullptr 
)
private

◆ CallRetStrMethod()

wxString PYTHON_FOOTPRINT_WIZARD::CallRetStrMethod ( const char *  aMethod,
PyObject *  aArglist = nullptr 
)
private

◆ GetDescription()

wxString PYTHON_FOOTPRINT_WIZARD::GetDescription ( )
overridevirtual
Returns
a description of the footprint wizard.

Implements FOOTPRINT_WIZARD.

Definition at line 159 of file pcbnew_footprint_wizards.cpp.

References CallRetStrMethod().

◆ GetFootprint()

FOOTPRINT * PYTHON_FOOTPRINT_WIZARD::GetFootprint ( wxString *  aMessage)
overridevirtual

Build the footprint itself and returns it to the caller function.

Parameters
aMessageis storage for messages (if any) generated by the footprint generator.
Returns
a footprint built from the parameters given to the class.

Implements FOOTPRINT_WIZARD.

Definition at line 336 of file pcbnew_footprint_wizards.cpp.

References CallMethod(), CallRetStrMethod(), and PyFootprint_to_FOOTPRINT().

◆ GetImage()

wxString PYTHON_FOOTPRINT_WIZARD::GetImage ( )
overridevirtual
Returns
an svg image of the wizard to be rendered.

Implements FOOTPRINT_WIZARD.

Definition at line 151 of file pcbnew_footprint_wizards.cpp.

References CallRetStrMethod().

◆ GetName()

wxString PYTHON_FOOTPRINT_WIZARD::GetName ( )
overridevirtual
Returns
the name of the wizard.

Implements FOOTPRINT_WIZARD.

Definition at line 143 of file pcbnew_footprint_wizards.cpp.

References CallRetStrMethod().

◆ GetNumParameterPages()

int PYTHON_FOOTPRINT_WIZARD::GetNumParameterPages ( )
overridevirtual
Returns
the number of parameter pages that this wizard will show to the user.

Implements FOOTPRINT_WIZARD.

Definition at line 167 of file pcbnew_footprint_wizards.cpp.

References CallMethod().

◆ GetObject()

void * PYTHON_FOOTPRINT_WIZARD::GetObject ( )
overridevirtual

Get the object from where this wizard constructs.

Returns
it's a void pointer as it could be a PyObject or any other.

Implements FOOTPRINT_WIZARD.

Definition at line 362 of file pcbnew_footprint_wizards.cpp.

References m_PyWizard.

◆ GetParameterDesignators()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterDesignators ( int  aPage = 0)
overridevirtual
Parameters
aPageis the page we want to know the designators of.
Returns
an array of designators (blank strings for no designators.

Implements FOOTPRINT_WIZARD.

Definition at line 288 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ GetParameterErrors()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterErrors ( int  aPage)
overridevirtual
Parameters
aPageis the page we want to know the errors of.
Returns
an array of errors (if any) for the parameters, empty strings for OK parameters.

Implements FOOTPRINT_WIZARD.

Definition at line 264 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ GetParameterHints()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterHints ( int  aPage)
overridevirtual
Parameters
aPageis the page we want to know the hints of.
Returns
an array of hints (if any) for the parameters, empty string for no hints.

Implements FOOTPRINT_WIZARD.

Definition at line 276 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ GetParameterNames()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterNames ( int  aPage)
overridevirtual
Parameters
aPageis the page we want the parameter names of.
Returns
an array string with the parameter names on a certain page.

Implements FOOTPRINT_WIZARD.

Definition at line 212 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ GetParameterPageName()

wxString PYTHON_FOOTPRINT_WIZARD::GetParameterPageName ( int  aPage)
overridevirtual
Parameters
aPageis the page we want the name of.
Returns
a string with the page name.

Implements FOOTPRINT_WIZARD.

Definition at line 188 of file pcbnew_footprint_wizards.cpp.

References CallMethod().

◆ GetParameterTypes()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterTypes ( int  aPage)
overridevirtual
Parameters
aPageis the page we want the parameter types of.
Returns
an array string with the parameter types on a certain page "IU" for internal units, "UNITS" for units (0,1,2,3...,N).

Implements FOOTPRINT_WIZARD.

Definition at line 237 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ GetParameterValues()

wxArrayString PYTHON_FOOTPRINT_WIZARD::GetParameterValues ( int  aPage)
overridevirtual
Parameters
aPageis the page we want the parameter values of.
Returns
an array of parameter values.

Implements FOOTPRINT_WIZARD.

Definition at line 251 of file pcbnew_footprint_wizards.cpp.

References CallRetArrayStrMethod().

◆ register_wizard()

void FOOTPRINT_WIZARD::register_wizard ( )
inherited

The standard method of a "FOOTPRINT_WIZARD" to register itself into the FOOTPRINT_WIZARD_LIST singleton manager.

Definition at line 39 of file footprint_wizard.cpp.

References FOOTPRINT_WIZARD_LIST::register_wizard().

Referenced by PYTHON_FOOTPRINT_WIZARD_LIST::register_wizard().

◆ ResetParameters()

void PYTHON_FOOTPRINT_WIZARD::ResetParameters ( )
overridevirtual

Reset all wizard parameters to default values.

Implements FOOTPRINT_WIZARD.

Definition at line 324 of file pcbnew_footprint_wizards.cpp.

References CallMethod().

◆ SetParameterValues()

wxString PYTHON_FOOTPRINT_WIZARD::SetParameterValues ( int  aPage,
wxArrayString &  aValues 
)
overridevirtual
Parameters
aPageis the page we want to set the parameters in.
aValuesare the values we want to set into the parameters.
Returns
an array of parameter values.

Implements FOOTPRINT_WIZARD.

Definition at line 300 of file pcbnew_footprint_wizards.cpp.

References CallRetStrMethod(), and res.

Member Data Documentation

◆ m_PyWizard

PyObject* PYTHON_FOOTPRINT_WIZARD::m_PyWizard
private

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