KiCad PCB EDA Suite
Loading...
Searching...
No Matches
sch_easyeda_parser.cpp File Reference
#include "sch_easyeda_parser.h"
#include <sch_io/sch_io_mgr.h>
#include <schematic.h>
#include <sch_sheet.h>
#include <sch_line.h>
#include <sch_no_connect.h>
#include <sch_label.h>
#include <sch_junction.h>
#include <sch_edit_frame.h>
#include <sch_shape.h>
#include <sch_bitmap.h>
#include <string_utils.h>
#include <bezier_curves.h>
#include <wx/base64.h>
#include <wx/mstream.h>
#include <core/map_helpers.h>
#include <gfx_import_utils.h>
#include <import_gfx/svg_import_plugin.h>
#include <import_gfx/graphics_importer_lib_symbol.h>
#include <import_gfx/graphics_importer_sch.h>

Go to the source code of this file.

Functions

static std::vector< std::vector< wxString > > RegexMatchAll (wxRegEx &aRegex, const wxString &aString)
 
static std::vector< std::pair< wxString, std::vector< double > > > ParseImageTransform (const wxString &transformData)
 EasyEDA image transformations are in the form of:
 
static LIB_ID EasyEdaToKiCadLibID (const wxString &aLibName, const wxString &aLibReference)
 
static LINE_STYLE ConvertStrokeStyle (const wxString &aStyle)
 
static ELECTRICAL_PINTYPE ConvertElecType (const wxString &aType)
 
VECTOR2I HelperGeneratePowerPortGraphics (LIB_SYMBOL *aKsymbol, EASYEDA::POWER_FLAG_STYLE aStyle, REPORTER *aReporter)
 

Variables

static const std::vector< wxString > c_attributesWhitelist
 

Function Documentation

◆ ConvertElecType()

static ELECTRICAL_PINTYPE ConvertElecType ( const wxString &  aType)
static

◆ ConvertStrokeStyle()

static LINE_STYLE ConvertStrokeStyle ( const wxString &  aStyle)
static

◆ EasyEdaToKiCadLibID()

static LIB_ID EasyEdaToKiCadLibID ( const wxString &  aLibName,
const wxString &  aLibReference 
)
static

◆ HelperGeneratePowerPortGraphics()

◆ ParseImageTransform()

static std::vector< std::pair< wxString, std::vector< double > > > ParseImageTransform ( const wxString &  transformData)
static

EasyEDA image transformations are in the form of:

scale(1,-1) translate(-555,1025) rotate(270,425,-785)

Order of operations is from end to start, similar to CSS.

Definition at line 110 of file sch_easyeda_parser.cpp.

References RegexMatchAll().

Referenced by SCH_EASYEDA_PARSER::ParseSchematic().

◆ RegexMatchAll()

static std::vector< std::vector< wxString > > RegexMatchAll ( wxRegEx &  aRegex,
const wxString &  aString 
)
static

Definition at line 74 of file sch_easyeda_parser.cpp.

Referenced by ParseImageTransform().

Variable Documentation

◆ c_attributesWhitelist

const std::vector<wxString> c_attributesWhitelist
static
Initial value:
= { "Datasheet",
"Manufacturer Part",
"Manufacturer",
"BOM_Manufacturer Part",
"BOM_Manufacturer",
"Supplier Part",
"Supplier",
"BOM_Supplier Part",
"BOM_Supplier",
"LCSC Part Name" }

Definition at line 49 of file sch_easyeda_parser.cpp.

Referenced by SCH_EASYEDAPRO_PARSER::ParseSchematic(), SCH_EASYEDAPRO_PARSER::ParseSymbol(), and SCH_EASYEDA_PARSER::ParseSymbol().