38 std::vector<LTSPICE_SCHEMATIC::LT_ASC>& outLT_ASCs,
39 const std::vector<wxString>& aAsyFileNames )
45 bbox.
Merge( asc.BoundingBox );
53 int margin =
grid * 10;
57 if( bbox.
GetWidth() > pageSize.
x - margin )
74 ltSubDir.AppendDir( wxS(
"sub" ) );
80 for( wxString& line : wxSplit( lt_text.
Value,
'\n' ) )
82 if( line.StartsWith( wxS(
".include " ) ) || line.StartsWith( wxS(
".inc " ) )
83 || line.StartsWith( wxS(
".lib " ) ) )
85 wxString
path = line.AfterFirst(
' ' );
87 path.Replace(
'\\',
'/' );
88 wxFileName fileName(
path );
90 if( fileName.IsAbsolute() )
92 m_includes[fileName.GetName()] = fileName.GetFullPath();
96 fileName.MakeAbsolute( ltSubDir.GetFullPath() );
97 m_includes[fileName.GetName()] = fileName.GetFullPath();
136 std::vector<LTSPICE_SCHEMATIC::LT_ASC>& outLT_ASCs,
137 const std::vector<wxString>& aAsyFiles )
141 std::vector<LTSPICE_SCHEMATIC::LT_SYMBOL> symbols = lt_asc.Symbols;
142 std::map<wxString, LIB_SYMBOL*> existingSymbol;
143 std::map<wxString, SCH_SYMBOL*> existingSchematicSymbol;
151 if( existingSymbol.count( lt_symbol.Name ) == 0 )
153 lib_symbol =
new LIB_SYMBOL( lt_symbol.Name );
157 existingSymbol.emplace( lt_symbol.Name, lib_symbol );
161 lib_symbol = existingSymbol[lt_symbol.Name];
164 LIB_ID libId( wxS(
"ltspice" ), lt_symbol.Name );
169 for(
int j = 0; j < (int) lt_symbol.Wires.size(); j++ )
179 for(
int j = 0; j < (int) lt_symbol.Lines.size(); j++ )
182 for(
int j = 0; j < (int) lt_symbol.Circles.size(); j++ )
185 for(
int j = 0; j < (int) lt_symbol.Arcs.size(); j++ )
188 for(
int j = 0; j < (int) lt_symbol.Rectangles.size(); j++ )
195 LTSPICE_FILE tempAsyFile( lt_symbol.Name +
".asy", { 0, 0 } );
207 int botRightX = lt_symbol.Offset.x
210 int botRightY = lt_symbol.Offset.y
220 if( wire.
Start == ( pinPos + lt_symbol.Offset ) )
223 if( wire.
End.
x == ( pinPos + lt_symbol.Offset ).x )
225 if( wire.
End.
y <= topLeftY )
227 else if( wire.
End.
y >= botRightY )
229 else if( wire.
End.
y < botRightY && wire.
End.
y > topLeftY )
233 else if( wire.
End.
y == ( pinPos + lt_symbol.Offset ).y )
235 if( wire.
End.
x <= topLeftX )
237 else if( wire.
End.
x >= botRightX )
239 else if( wire.
End.
x < botRightX && wire.
End.
x > topLeftX )
243 else if( wire.
End == ( pinPos + lt_symbol.Offset ) )
246 if( wire.
Start.
x == ( pinPos + lt_symbol.Offset ).x )
248 if( wire.
Start.
y <= topLeftY )
250 else if( wire.
Start.
y > botRightY )
252 else if( wire.
Start.
y < botRightY && wire.
End.
y > topLeftY )
256 else if( wire.
Start.
y == ( pinPos + lt_symbol.Offset ).y )
258 if( wire.
Start.
x <= topLeftX )
260 else if( wire.
Start.
x >= botRightX )
262 else if( wire.
Start.
x < botRightX && wire.
Start.
x > topLeftX )
277 for(
int j = 0; j < (int) aLtSymbol.
Lines.size(); j++ )
285 for(
int j = 0; j < (int) aLtSymbol.
Circles.size(); j++ )
293 for(
int j = 0; j < (int) aLtSymbol.
Arcs.size(); j++ )
301 for(
int j = 0; j < (int) aLtSymbol.
Rectangles.size(); j++ )
309 for(
int j = 0; j < (int) aLtSymbol.
Pins.size(); j++ )
341 if( aLTFontSize == 1 )
return MILS_SIZE( 36 );
342 else if( aLTFontSize == 2 )
return MILS_SIZE( 42 );
343 else if( aLTFontSize == 3 )
return MILS_SIZE( 50 );
344 else if( aLTFontSize == 4 )
return MILS_SIZE( 60 );
345 else if( aLTFontSize == 5 )
return MILS_SIZE( 72 );
346 else if( aLTFontSize == 6 )
return MILS_SIZE( 88 );
347 else if( aLTFontSize == 7 )
return MILS_SIZE( 108 );
452 std::vector<LTSPICE_SCHEMATIC::LT_ASC>& outLT_ASCs )
458 for(
int j = 0; j < (int) lt_asc.Lines.size(); j++ )
461 for(
int j = 0; j < (int) lt_asc.Circles.size(); j++ )
464 for(
int j = 0; j < (int) lt_asc.Arcs.size(); j++ )
467 for(
int j = 0; j < (int) lt_asc.Rectangles.size(); j++ )
470 for(
int j = 0; j < (int) lt_asc.Bustap.size(); j++ )
492 for(
int j = 0; j < (int) lt_asc.Wires.size(); j++ )
493 CreateWire( lt_asc, j, aSheet, SCH_LAYER_ID::LAYER_WIRE );
495 for(
int j = 0; j < (int) lt_asc.Iopins.size(); j++ )
500 if( lt_flag.
Value == wxS(
"0" ) )
503 aSheet, lt_asc.Wires ) );
514 wxString textVal = lt_text.
Value;
517 if( textVal.StartsWith(
".include " ) || textVal.StartsWith(
".inc " )
518 || textVal.StartsWith(
".lib " ) )
520 textVal = wxS(
"* " ) + textVal;
530 lt_flag.Expression, lt_flag.
FontSize, lt_asc.Wires ) );
541 for(
int k = 0; k < (int) aAscfile.
Wires.size(); k++ )
543 if( ( aAscfile.
Wires[k].Start == bustap.
Start )
544 || ( aAscfile.
Wires[k].End == bustap.
Start ) )
546 CreateWire( aAscfile, k, aSheet, SCH_LAYER_ID::LAYER_BUS );
547 aAscfile.
Wires.erase( aAscfile.
Wires.begin() + k );
552 bustap.
Start.
y - 16 } ) );
577 for(
unsigned int k = 0; k < aAscfile.
Flags.size(); k++ )
582 ioPinName = aAscfile.
Flags[k].Value;
583 aAscfile.
Flags.erase( aAscfile.
Flags.begin() + k );
680 default:
return LINE_STYLE::SOLID;
695 switch( aJustification )
734 switch( aJustification )
756 if( wxSplit( aText->
GetText(),
'\n',
'\0' ).size() > 1 )
758 switch( aJustification )
814 const wxString& aValue,
816 std::vector<LTSPICE_SCHEMATIC::WIRE>& aWires )
829 LINE_STYLE::SOLID ) );
836 pin->SetType( ELECTRICAL_PINTYPE::PT_POWER_IN );
839 pin->SetShape( GRAPHIC_PINSHAPE::LINE );
842 LIB_ID libId( wxS(
"ltspice" ), wxS(
"GND" ) );
855 if( aOffset == wire.Start )
857 if( wire.Start.x == wire.End.x )
859 if( wire.Start.y < wire.End.y )
867 if( wire.Start.x < wire.End.x )
869 else if( wire.Start.x > wire.End.x )
873 else if( aOffset == wire.End )
875 if( wire.Start.x == wire.End.x )
877 if( wire.Start.y > wire.End.y )
885 if( wire.Start.x < wire.End.x )
887 else if( wire.Start.x > wire.End.x )
899 const wxString& aValue,
int aFontSize,
900 std::vector<LTSPICE_SCHEMATIC::WIRE>& aWires )
918 SCH_FIELD field( label, FIELD_T::USER, wxS(
"DATAFLAG" ) );
937 std::vector<SPIN_STYLE> preferredSpins;
941 if( aOffset == wire.Start )
943 if( wire.Start.x == wire.End.x )
945 if( wire.Start.y < wire.End.y )
947 else if( wire.Start.y > wire.End.y )
952 if( wire.Start.x < wire.End.x )
954 else if( wire.Start.x > wire.End.x )
958 else if( aOffset == wire.End )
960 if( wire.Start.x == wire.End.x )
962 if( wire.Start.y > wire.End.y )
964 else if( wire.Start.y < wire.End.y )
969 if( wire.Start.x > wire.End.x )
971 else if( wire.Start.x < wire.End.x )
977 if( preferredSpins.size() == 1 )
988 wxString symbolName = aLTSymbol.
Name.Upper();
989 wxString type = aLTSymbol.
SymAttributes[wxS(
"TYPE" )].Upper();
990 wxString prefix = aLTSymbol.
SymAttributes[wxS(
"PREFIX" )].Upper();
991 wxString instName = aLTSymbol.
SymAttributes[wxS(
"INSTNAME" )].Upper();
995 if( value.IsEmpty() )
998 value2 = wxEmptyString;
1002 [&](
const wxString& aFieldName,
const wxString& aFieldValue )
1004 SCH_FIELD newField( aSymbol, FIELD_T::USER, aFieldName );
1006 newField.
SetText( aFieldValue );
1010 aSymbol->
SetRef( aSheet, instName );
1013 if( !value2.IsEmpty() )
1014 addField( wxS(
"Value2" ), value2 );
1016 auto setupNonInferredPassive =
1017 [&](
const wxString& aDevice,
const wxString& aValueKey )
1019 addField( wxS(
"Sim.Device" ), aDevice );
1020 addField( wxS(
"Sim.Params" ), aValueKey + wxS(
"=${VALUE}" ) );
1023 auto setupBehavioral =
1024 [&](
const wxString& aDevice,
const wxString& aType )
1028 addField( wxS(
"Sim.Device" ), aDevice );
1029 addField( wxS(
"Sim.Type" ), aType );
1030 addField( wxS(
"Sim.Params" ), value );
1033 static const std::set<wxString> prefixWithGain = { wxS(
"E" ), wxS(
"F" ), wxS(
"G" ), wxS(
"H" ) };
1035 if( prefix == wxS(
"R" ) )
1037 setupNonInferredPassive( prefix, wxS(
"R" ) );
1039 else if( prefix == wxS(
"C" ) )
1041 setupNonInferredPassive( prefix, wxS(
"C" ) );
1043 else if( prefix == wxS(
"L" ) )
1045 setupNonInferredPassive( prefix, wxS(
"L" ) );
1047 else if( prefixWithGain.count( prefix ) > 0 )
1049 setupNonInferredPassive( prefix, wxS(
"gain" ) );
1051 else if( prefix == wxS(
"B" ) )
1053 if( symbolName.StartsWith( wxS(
"BV" ) ) )
1054 setupBehavioral( wxS(
"V" ), wxS(
"=" ) );
1055 else if( symbolName.StartsWith( wxS(
"BI" ) ) )
1056 setupBehavioral( wxS(
"I" ), wxS(
"=" ) );
1058 else if( prefix == wxS(
"V" ) || symbolName == wxS(
"I" ) )
1060 addField( wxS(
"Sim.Device" ), wxS(
"SPICE" ) );
1063 simParams <<
"type=" <<
'"' << prefix <<
'"' <<
' ';
1065 if( value2.IsEmpty() )
1066 simParams <<
"model=" <<
'"' <<
"${VALUE}" <<
'"' <<
' ';
1068 simParams <<
"model=" <<
'"' <<
"${VALUE} ${VALUE2}" <<
'"' <<
' ';
1070 addField( wxS(
"Sim.Params" ), simParams );
1074 wxString libFile = aLTSymbol.
SymAttributes[wxS(
"MODELFILE" )];
1076 if( prefix == wxS(
"X" ) )
1081 else if( libFile.IsEmpty() )
1083 if( type.IsEmpty() )
1086 if( value ==
"DIODE" )
1087 libFile = libPath + wxS(
"cmp/standard.dio" );
1088 else if( value ==
"NPN" || value ==
"PNP" )
1089 libFile = libPath + wxS(
"cmp/standard.bjt" );
1090 else if( value ==
"NJF" || value ==
"PJF" )
1091 libFile = libPath + wxS(
"cmp/standard.jft" );
1092 else if( value ==
"NMOS" || value ==
"PMOS" )
1093 libFile = libPath + wxS(
"cmp/standard.mos" );
1096 if( libFile.IsEmpty() )
1099 if( !libFile.IsEmpty() )
1100 addField( wxS(
"Sim.Library" ), libFile );
1102 if( type == wxS(
"X" ) )
1103 addField( wxS(
"Sim.Device" ), wxS(
"SUBCKT" ) );
1105 addField( wxS(
"Sim.Device" ), wxS(
"SPICE" ) );
1107 wxString spiceLine = aLTSymbol.
SymAttributes[wxS(
"SPICELINE" )];
1109 if( !spiceLine.IsEmpty() )
1112 addField( wxS(
"Sim.Params" ), spiceLine );
1116 addField( wxS(
"Sim.Params" ),
"model=\"" + value +
"\"" );
1127 case 0: field = aSymbol->
GetField( FIELD_T::REFERENCE );
break;
1130 case 3: field = aSymbol->
GetField( FIELD_T::VALUE );
break;
1140 case 38: field = aSymbol->
GetField( wxS(
"Sim.Name" ) );
break;
1141 case 39: field = aSymbol->
GetField( wxS(
"Sim.Params" ) );
break;
1264 if( aLTSymbol.
SymAttributes[wxS(
"Prefix" )] == wxS(
"X" ) )
1265 aRectangle->
SetFillMode( FILL_T::FILLED_WITH_BG_BODYCOLOR );
1290 wxString device = aLTSymbol.
Name.Lower();
1292 if( aLTSymbol.
Pins.size() == 2 && ( device == wxS(
"res" )
1293 || device == wxS(
"cap" )
1294 || device == wxS(
"ind" ) ) )
1307 aPin->
SetNumber( wxString::Format( wxS(
"%d" ), aIndex + 1 ) );
1308 aPin->
SetType( ELECTRICAL_PINTYPE::PT_PASSIVE );
1311 aPin->
SetShape( GRAPHIC_PINSHAPE::LINE );
constexpr EDA_IU_SCALE schIUScale
constexpr void SetOrigin(const Vec &pos)
constexpr size_type GetWidth() const
constexpr BOX2< Vec > & Merge(const BOX2< Vec > &aRect)
Modify the position and size of the rectangle in order to contain aRect.
constexpr const Vec GetCenter() const
constexpr void SetSize(const SizeVec &size)
constexpr size_type GetHeight() const
constexpr coord_type GetLeft() const
constexpr const Vec & GetOrigin() const
constexpr const SizeVec & GetSize() const
constexpr coord_type GetTop() const
constexpr void Offset(coord_type dx, coord_type dy)
void SetCenter(const VECTOR2I &aCenter)
void SetStart(const VECTOR2I &aStart)
void SetEnd(const VECTOR2I &aEnd)
void SetFillMode(FILL_T aFill)
A mix-in class (via multiple inheritance) that handles texts such as labels, parts,...
int GetTextHeight() const
void SetTextSize(VECTOR2I aNewSize, bool aEnforceMinTextSize=true)
virtual const wxString & GetText() const
Return the string associated with the text object.
void SetVertJustify(GR_TEXT_V_ALIGN_T aType)
void Offset(const VECTOR2I &aOffset)
virtual void SetVisible(bool aVisible)
virtual void SetText(const wxString &aText)
virtual void SetTextAngle(const EDA_ANGLE &aAngle)
void SetMultilineAllowed(bool aAllow)
void SetHorizJustify(GR_TEXT_H_ALIGN_T aType)
A logical library item identifier and consists of various portions much like a URI.
Define a library symbol object.
const BOX2I GetBoundingBox() const override
Return the orthogonal bounding box of this object for display purposes.
void AddDrawItem(SCH_ITEM *aItem, bool aSort=true)
Add a new draw aItem to the draw object list and sort according to aSort.
LT_SYMBOL SymbolBuilder(const wxString &aAscFileName, LT_ASC &aAscFile)
POLARITY
Polarity enum represents polarity of pin.
const wxFileName & GetLTspiceDataDir()
JUSTIFICATION
Defines in what ways the PIN or TEXT can be justified.
const VECTOR2D GetSizeIU(double aIUScale) const
Gets the page size in internal units.
void SetSize(const VECTOR2I &aSize)
Class for a wire to bus entry.
void SetPosition(const VECTOR2I &aPosition) override
void SetText(const wxString &aText) override
int ToLtSpiceCoords(int aCoordinate)
Method converts kicad coordinate(i.e scale) to ltspice coordinates.
void CreateCircle(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting circle from Asc files.
void setTextJustification(EDA_TEXT *aText, LTSPICE_SCHEMATIC::JUSTIFICATION aJustification)
SCH_TEXT * CreateSCH_TEXT(const VECTOR2I &aOffset, const wxString &aText, int aFontSize, LTSPICE_SCHEMATIC::JUSTIFICATION aJustification)
Create schematic text.
void CreateWires(LTSPICE_SCHEMATIC::LT_SYMBOL &aLTSymbol, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting wires.
void Parse(SCH_SHEET_PATH *aSheet, std::vector< LTSPICE_SCHEMATIC::LT_ASC > &outLT_ASCs, const std::vector< wxString > &aAsyFileNames)
Function responsible for loading the .asc and .asy files in intermediate data structure.
STROKE_PARAMS getStroke(const LTSPICE_SCHEMATIC::LINEWIDTH &aLineWidth, const LTSPICE_SCHEMATIC::LINESTYLE &aLineStyle)
void CreateKicadSYMBOLs(SCH_SHEET_PATH *aSheet, std::vector< LTSPICE_SCHEMATIC::LT_ASC > &outLT_ASCs, const std::vector< wxString > &aAsyFiles)
Main Method for loading indermediate data to kicacd object from asy files.
SCH_SYMBOL * CreatePowerSymbol(const VECTOR2I &aOffset, const wxString &aValue, int aFontSize, SCH_SHEET_PATH *aSheet, std::vector< LTSPICE_SCHEMATIC::WIRE > &aWires)
Create a power symbol.
std::map< wxString, wxString > m_includes
void CreateLine(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting Line from Asc files.
int getLineWidth(const LTSPICE_SCHEMATIC::LINEWIDTH &aLineWidth)
void RotateMirror(LTSPICE_SCHEMATIC::LT_SYMBOL &aLTSymbol, SCH_SYMBOL *aSchSymbol)
Methods for rotating and mirroring objects.
void CreateBusEntry(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting Bustap from Asc files.
void CreateRect(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting rectangle from Asc files.
void CreateWire(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet, SCH_LAYER_ID aLayer)
Create a schematic wire.
void CreateLines(LIB_SYMBOL *aSymbol, LTSPICE_SCHEMATIC::LT_SYMBOL &aLTSymbol, int aIndex, SCH_SHAPE *aShape)
Method for plotting Lines from Asy files.
void CreatePin(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting Iopin from Asc files.
void CreateArc(LTSPICE_SCHEMATIC::LT_ASC &aAscfile, int aIndex, SCH_SHEET_PATH *aSheet)
Method for plotting Arc from Asc files.
void readIncludes(std::vector< LTSPICE_SCHEMATIC::LT_ASC > &outLT_ASCs)
LINE_STYLE getLineStyle(const LTSPICE_SCHEMATIC::LINESTYLE &aLineStyle)
LTSPICE_SCHEMATIC * m_lt_schematic
int ToKicadCoords(int aCoordinate)
Method converts ltspice coordinate(i.e scale) to kicad coordinates.
void CreateFields(LTSPICE_SCHEMATIC::LT_SYMBOL &aLTSymbol, SCH_SYMBOL *aSymbol, SCH_SHEET_PATH *aSheet)
void RotateMirrorShape(LTSPICE_SCHEMATIC::LT_SYMBOL &aLTSymbol, SCH_SHAPE *aShape)
SCH_LABEL_BASE * CreateSCH_LABEL(KICAD_T aType, const VECTOR2I &aOffset, const wxString &aValue, int aFontSize, std::vector< LTSPICE_SCHEMATIC::WIRE > &aWires)
Create a label.
void CreateKicadSCH_ITEMs(SCH_SHEET_PATH *aSheet, std::vector< LTSPICE_SCHEMATIC::LT_ASC > &outLT_ASCs)
Main method for loading intermediate data structure from Asc file to kicad.
VECTOR2I ToKicadFontSize(int aLTFontSize)
void CreateSymbol(LTSPICE_SCHEMATIC::LT_SYMBOL &aLtSymbol, LIB_SYMBOL *aLibSymbol)
void SetLayer(SCH_LAYER_ID aLayer)
void Move(const VECTOR2I &aMoveVector) override
Move the item by aMoveVector to a new position.
void AddField(const SCH_FIELD &aField)
void SetShape(LABEL_FLAG_SHAPE aShape)
void SetPosition(const VECTOR2I &aPosition) override
void AutoplaceFields(SCH_SCREEN *aScreen, AUTOPLACE_ALGO aAlgo) override
virtual void SetSpinStyle(SPIN_STYLE aSpinStyle)
Segment description base class to describe items which have 2 end points (track, wire,...
void SetStartPoint(const VECTOR2I &aPosition)
void SetLineWidth(const int aSize)
void SetLineStyle(const LINE_STYLE aStyle)
void Move(const VECTOR2I &aMoveVector) override
Move the item by aMoveVector to a new position.
virtual void SetStroke(const STROKE_PARAMS &aStroke) override
void SetEndPoint(const VECTOR2I &aPosition)
void SetNumber(const wxString &aNumber)
void SetOrientation(PIN_ORIENTATION aOrientation)
void SetName(const wxString &aName)
void SetPosition(const VECTOR2I &aPos) override
void SetLength(int aLength)
void SetShape(GRAPHIC_PINSHAPE aShape)
void SetType(ELECTRICAL_PINTYPE aType)
void SetNameTextSize(int aSize)
const PAGE_INFO & GetPageSettings() const
void Append(SCH_ITEM *aItem, bool aUpdateLibSymbol=true)
void SetPosition(const VECTOR2I &aPos) override
void MirrorHorizontally(int aCenter) override
Mirror item horizontally about aCenter.
void Move(const VECTOR2I &aOffset) override
Move the item by aMoveVector to a new position.
void SetStroke(const STROKE_PARAMS &aStroke) override
void MirrorVertically(int aCenter) override
Mirror item vertically about aCenter.
void AddPoint(const VECTOR2I &aPosition)
void Rotate(const VECTOR2I &aCenter, bool aRotateCCW) override
Rotate the item around aCenter 90 degrees in the clockwise direction.
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
SCH_SCREEN * LastScreen()
void SetValueFieldText(const wxString &aValue)
void Move(const VECTOR2I &aMoveVector) override
Move the item by aMoveVector to a new position.
void SetRef(const SCH_SHEET_PATH *aSheet, const wxString &aReference)
Set the reference for the given sheet path for this symbol.
void SetOrientation(int aOrientation)
Compute the new transform matrix based on aOrientation for the symbol which is applied to the current...
SCH_FIELD * AddField(const SCH_FIELD &aField)
Add a field to the symbol.
SCH_FIELD * GetField(FIELD_T aFieldType)
Return a mandatory field in this symbol.
void Move(const VECTOR2I &aVector) override
Simple container to manage line stroke parameters.
virtual void SetShowPinNumbers(bool aShow)
Set or clear the pin number visibility flag.
static constexpr EDA_ANGLE ANGLE_VERTICAL
static constexpr EDA_ANGLE ANGLE_HORIZONTAL
SCH_LAYER_ID
Eeschema drawing layers.
#define UNIMPLEMENTED_FOR(type)
bool contains(const _Container &__container, _Value __value)
Returns true if the container contains the given value.
LABEL_FLAG_SHAPE getLabelShape(LTSPICE_SCHEMATIC::POLARITY aPolarity)
LINE_STYLE
Dashed line types.
constexpr int IUToMils(int iu) const
constexpr int MilsToIU(int mils) const
The ARC is represented inside a rectangle whose opposite site are given.
The CIRCLE is represented in Ltpsice inside a rectangle whose two opposite points and line style are ...
IOPIN is special contact on symbol used for IO operations.
A struct to hold .asc file definition.
std::vector< CIRCLE > Circles
std::vector< IOPIN > Iopins
std::vector< BUSTAP > Bustap
std::vector< LINE > Lines
std::vector< WIRE > Wires
std::vector< RECTANGLE > Rectangles
std::vector< FLAG > Flags
JUSTIFICATION PinJustification
std::map< wxString, wxString > PinAttribute
A struct to hold SYMBOL definition.
std::map< wxString, wxString > SymAttributes
std::vector< RECTANGLE > Rectangles
std::vector< LT_WINDOW > Windows
std::vector< LT_PIN > Pins
std::vector< WIRE > Wires
ORIENTATION SymbolOrientation
std::vector< CIRCLE > Circles
std::vector< LINE > Lines
JUSTIFICATION Justification
A 4-sided polygon with opposite equal sides, used in representing shapes.
JUSTIFICATION Justification
A metallic connection, used for transfer, between two points or pin.
@ SYM_ROTATE_COUNTERCLOCKWISE
SHAPE_CIRCLE circle(c.m_circle_center, c.m_circle_radius)
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.
T rescale(T aNumerator, T aValue, T aDenominator)
Scale a number (value) by rational (numerator/denominator).
VECTOR2< int32_t > VECTOR2I