KiCad PCB EDA Suite
eeschema/dialogs/dialog_netlist.cpp File Reference

Dialog box for creating netlists. More...

#include <fctsys.h>
#include <pgm_base.h>
#include <kiface_i.h>
#include <gestfich.h>
#include <schframe.h>
#include <general.h>
#include <netlist.h>
#include <sch_sheet.h>
#include <dialog_helpers.h>
#include <dialogs/dialog_netlist_base.h>
#include <wildcards_and_files_ext.h>
#include <invoke_sch_dialog.h>
#include <netlist_exporters/netlist_exporter_pspice.h>
#include <eeschema_id.h>

Go to the source code of this file.

Classes

class  NETLIST_PAGE_DIALOG
 
class  NETLIST_DIALOG
 
class  NETLIST_DIALOG_ADD_PLUGIN
 

Macros

#define CUSTOMPANEL_COUNTMAX   8
 
#define CUSTOM_NETLIST_TITLE   wxT( "CustomNetlistTitle" )
 
#define CUSTOM_NETLIST_COMMAND   wxT( "CustomNetlistCommand" )
 
#define NETLIST_USE_DEFAULT_NETNAME   wxT( "NetlistUseDefaultNetname" )
 
#define NETLIST_PSPICE_USE_NETNAME   wxT( "SpiceUseNetNames" )
 

Enumerations

enum  panel_netlist_index {
  PANELPCBNEW = 0, PANELORCADPCB2, PANELCADSTAR, PANELSPICE,
  PANELCUSTOMBASE
}
 
enum  id_netlist {
  ID_CREATE_NETLIST = ID_END_EESCHEMA_ID_LIST + 1, ID_CURRENT_FORMAT_IS_DEFAULT, ID_RUN_SIMULATOR, ID_ADD_SUBCIRCUIT_PREFIX,
  ID_USE_NETCODE_AS_NETNAME
}
 

Functions

 EVT_CHECKBOX (ID_CURRENT_FORMAT_IS_DEFAULT, NETLIST_DIALOG::SelectDefaultNetlistType) NETLIST_PAGE_DIALOG
 
int InvokeDialogNetList (SCH_EDIT_FRAME *aCaller)
 

Detailed Description

Dialog box for creating netlists.

Definition in file eeschema/dialogs/dialog_netlist.cpp.

Macro Definition Documentation

#define CUSTOM_NETLIST_COMMAND   wxT( "CustomNetlistCommand" )
#define CUSTOM_NETLIST_TITLE   wxT( "CustomNetlistTitle" )
#define NETLIST_PSPICE_USE_NETNAME   wxT( "SpiceUseNetNames" )

Definition at line 251 of file eeschema/dialogs/dialog_netlist.cpp.

#define NETLIST_USE_DEFAULT_NETNAME   wxT( "NetlistUseDefaultNetname" )

Enumeration Type Documentation

Enumerator
PANELPCBNEW 
PANELORCADPCB2 
PANELCADSTAR 
PANELSPICE 
PANELCUSTOMBASE 

Definition at line 65 of file eeschema/dialogs/dialog_netlist.cpp.

65  {
66  PANELPCBNEW = 0, /* Handle Netlist format Pcbnew */
67  PANELORCADPCB2, /* Handle Netlist format OracdPcb2 */
68  PANELCADSTAR, /* Handle Netlist format CadStar */
69  PANELSPICE, /* Handle Netlist format Pspice */
70  PANELCUSTOMBASE /* First auxiliary panel (custom netlists).
71  * others use PANELCUSTOMBASE+1, PANELCUSTOMBASE+2.. */
72 };

Function Documentation

Definition at line 256 of file eeschema/dialogs/dialog_netlist.cpp.

265  :
266  wxPanel( parent, -1, wxDefaultPosition, wxDefaultSize,
267  wxTAB_TRAVERSAL | wxBORDER_SUNKEN )
268 {
269  m_IdNetType = id_NetType;
270  m_pageNetFmtName = title;
271  m_CommandStringCtrl = NULL;
272  m_TitleStringCtrl = NULL;
273  m_IsCurrentFormat = NULL;
274  m_SpiceAjustPassiveValues = NULL;
275  m_ButtonCancel = NULL;
276 
277  wxString netfmtName = ((NETLIST_DIALOG*)parent->GetParent())->m_NetFmtName;
278 
279  bool selected = m_pageNetFmtName == netfmtName;
280 
281  parent->AddPage( this, title, selected );
282 
283  wxBoxSizer* MainBoxSizer = new wxBoxSizer( wxVERTICAL );
284  SetSizer( MainBoxSizer );
285  wxBoxSizer* UpperBoxSizer = new wxBoxSizer( wxHORIZONTAL );
286  m_LowBoxSizer = new wxBoxSizer( wxVERTICAL );
287  MainBoxSizer->Add( UpperBoxSizer, 0, wxGROW | wxALL, 5 );
288  MainBoxSizer->Add( m_LowBoxSizer, 0, wxGROW | wxALL, 5 );
289 
290  m_LeftBoxSizer = new wxBoxSizer( wxVERTICAL );
291  m_RightBoxSizer = new wxBoxSizer( wxVERTICAL );
292  m_RightOptionsBoxSizer = new wxBoxSizer( wxVERTICAL );
293  UpperBoxSizer->Add( m_LeftBoxSizer, 0, wxGROW | wxALL, 5 );
294  UpperBoxSizer->Add( m_RightBoxSizer, 0, wxALIGN_CENTER_VERTICAL | wxALL, 5 );
295  UpperBoxSizer->Add( m_RightOptionsBoxSizer, 0, wxALIGN_CENTER_VERTICAL | wxALL, 5 );
296 
297  wxStaticText* text = new wxStaticText( this, -1, _( "Options:" ) );
298  m_LeftBoxSizer->Add( text, 0, wxGROW | wxALL, 5 );
299 
300  m_IsCurrentFormat = new wxCheckBox( this, ID_CURRENT_FORMAT_IS_DEFAULT,
301  _( "Default format" ) );
302  m_LeftBoxSizer->Add( m_IsCurrentFormat, 0, wxGROW | wxALL, 5 );
303  m_IsCurrentFormat->SetValue( selected );
304 
305  if( selected )
306  ((NETLIST_DIALOG*)parent->GetParent())->m_asFormatSelected = true;
307 }
int InvokeDialogNetList ( SCH_EDIT_FRAME aCaller)

Definition at line 875 of file eeschema/dialogs/dialog_netlist.cpp.

Referenced by SCH_EDIT_FRAME::OnCreateNetlist().

876 {
877  NETLIST_DIALOG dlg( aCaller );
878 
879  return dlg.ShowModal();
880 }