KiCad PCB EDA Suite
ASCH_WIRE Struct Reference

#include <altium_parser_sch.h>

Public Member Functions

 ASCH_WIRE (const std::map< wxString, wxString > &aProperties)
 

Public Attributes

int indexinsheet
 
int lineWidth
 
std::vector< wxPoint > points
 

Detailed Description

Definition at line 533 of file altium_parser_sch.h.

Constructor & Destructor Documentation

◆ ASCH_WIRE()

ASCH_WIRE::ASCH_WIRE ( const std::map< wxString, wxString > &  aProperties)
explicit

Definition at line 522 of file altium_parser_sch.cpp.

523 {
524  wxASSERT( PropertiesReadRecord( aProperties ) == ALTIUM_SCH_RECORD::WIRE );
525 
526  /*std::cout << "-----------------------------------" << std::endl;
527  // debug
528  for( auto& property : aProperties )
529  {
530  std::cout << " * '" << property.first << "' = '" << property.second << "'"
531  << std::endl;
532  }*/
533 
534  indexinsheet = ALTIUM_PARSER::PropertiesReadInt( aProperties, "INDEXINSHEET", 0 );
535 
536  int locationcount = ALTIUM_PARSER::PropertiesReadInt( aProperties, "LOCATIONCOUNT", 0 );
537  for( int i = 1; i <= locationcount; i++ )
538  {
539  const wxString si = std::to_string( i );
540  points.emplace_back( PropertiesReadKiCadUnitFrac( aProperties, "X" + si ),
541  -PropertiesReadKiCadUnitFrac( aProperties, "Y" + si ) );
542  }
543 
544  lineWidth = PropertiesReadKiCadUnitFrac( aProperties, "LINEWIDTH" );
545 }
static int PropertiesReadInt(const std::map< wxString, wxString > &aProperties, const wxString &aKey, int aDefault)
int PropertiesReadKiCadUnitFrac(const std::map< wxString, wxString > &aProperties, const wxString &aKey)
std::vector< wxPoint > points
ALTIUM_SCH_RECORD PropertiesReadRecord(const std::map< wxString, wxString > &aProperties)

References indexinsheet, lineWidth, points, ALTIUM_PARSER::PropertiesReadInt(), PropertiesReadKiCadUnitFrac(), PropertiesReadRecord(), and WIRE.

Member Data Documentation

◆ indexinsheet

int ASCH_WIRE::indexinsheet

Definition at line 535 of file altium_parser_sch.h.

Referenced by ASCH_WIRE().

◆ lineWidth

int ASCH_WIRE::lineWidth

Definition at line 536 of file altium_parser_sch.h.

Referenced by ASCH_WIRE(), and SCH_ALTIUM_PLUGIN::ParseWire().

◆ points

std::vector<wxPoint> ASCH_WIRE::points

Definition at line 538 of file altium_parser_sch.h.

Referenced by ASCH_WIRE(), and SCH_ALTIUM_PLUGIN::ParseWire().


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