![]() |
LibrePCB Developers Documentation
|
Helper class to convert EAGLE types to LibrePCB types. More...
#include <eagletypeconverter.h>
Public Member Functions | |
EagleTypeConverter ()=delete | |
EagleTypeConverter (const EagleTypeConverter &other)=delete | |
~EagleTypeConverter ()=delete | |
EagleTypeConverter & | operator= (const EagleTypeConverter &rhs)=delete |
Static Public Member Functions | |
static ElementName | convertElementName (const QString &n) |
Convert an element (e.g. symbol) name. More... | |
static QString | convertElementDescription (const QString &d) |
Convert an element (e.g. symbol) description. More... | |
static ComponentSymbolVariantItemSuffix | convertGateName (const QString &n) |
Convert a component gate name. More... | |
static CircuitIdentifier | convertPinOrPadName (const QString &n) |
Convert a pin or pad name. More... | |
static const Layer & | convertLayer (int id) |
Convert a layer ID. More... | |
static Length | convertLength (double l) |
Convert a length. More... | |
static Point | convertPoint (const parseagle::Point &p) |
Convert a point. More... | |
static Angle | convertAngle (double a) |
Convert an angle. More... | |
static Vertex | convertVertex (const parseagle::Vertex &v) |
Convert a vertex. More... | |
static Path | convertVertices (const QList< parseagle::Vertex > &v, bool close) |
Convert vertices. More... | |
static std::shared_ptr< Polygon > | convertWire (const parseagle::Wire &w) |
Convert a wire. More... | |
static std::shared_ptr< Polygon > | convertRectangle (const parseagle::Rectangle &r, bool isGrabArea) |
Convert a rectangle. More... | |
static std::shared_ptr< Polygon > | convertPolygon (const parseagle::Polygon &p, bool isGrabArea) |
Convert a polygon. More... | |
static std::shared_ptr< Circle > | convertCircle (const parseagle::Circle &c, bool isGrabArea) |
Convert a circle. More... | |
static std::shared_ptr< Hole > | convertHole (const parseagle::Hole &h) |
Convert a hole. More... | |
static QString | convertTextValue (const QString &v) |
Convert a text value. More... | |
static std::shared_ptr< Text > | convertSchematicText (const parseagle::Text &t) |
Convert a schematic/symbol text. More... | |
static std::shared_ptr< StrokeText > | convertBoardText (const parseagle::Text &t) |
Convert a board/footprint text. More... | |
static std::shared_ptr< SymbolPin > | convertSymbolPin (const parseagle::Pin &p) |
Convert a symbol pin. More... | |
static std::pair< std::shared_ptr< PackagePad >, std::shared_ptr< FootprintPad > > | convertThtPad (const parseagle::ThtPad &p) |
Convert a THT pad. More... | |
static std::pair< std::shared_ptr< PackagePad >, std::shared_ptr< FootprintPad > > | convertSmtPad (const parseagle::SmtPad &p) |
Convert an SMT pad. More... | |
Helper class to convert EAGLE types to LibrePCB types.
|
delete |
|
delete |
|
delete |
|
static |
Convert an element (e.g. symbol) name.
Removes all invalid characters from an EAGLe element name and convert it to the corresponding LibrePCB type. If completely invalid, "Unnamed" will be returned (no error).
n | EAGLE element name (e.g. "R-0805") |
|
static |
Convert an element (e.g. symbol) description.
Removes HTML tags and returns only the plain text.
d | EAGLE element description (might contain HTML) |
|
static |
Convert a component gate name.
Removes all invalid characters and returns the gate name as component symbol variant item suffix.
n | EAGLE gate name |
|
static |
Convert a pin or pad name.
Removes all invalid characters and returns the name as a circuit identifier.
n | EAGLE pin or pad name |
|
static |
Convert a layer ID.
id | EAGLE layer ID |
Exception | If the layer is unknown or not supported |
|
static |
Convert a length.
l | EAGLE length [mm] |
|
static |
Convert a point.
p | EAGLE point [mm] |
|
static |
Convert an angle.
a | EAGLE angle [°] |
|
static |
Convert a vertex.
v | EAGLE vertex |
|
static |
Convert vertices.
v | EAGLE vertices |
close | If true, the returned path will always be closed |
|
static |
Convert a wire.
w | EAGLE wire (line segment) |
|
static |
Convert a rectangle.
r | EAGLE rectangle |
isGrabArea | If the returned polygon should be a grab area |
|
static |
Convert a polygon.
p | EAGLE polygon |
isGrabArea | If the returned polygon should be a grab area |
|
static |
Convert a circle.
c | EAGLE circle |
isGrabArea | If the returned circle should be a grab area |
|
static |
Convert a hole.
h | EAGLE hole |
|
static |
Convert a text value.
v | EAGLE text value (e.g. ">NAME") |
|
static |
Convert a schematic/symbol text.
t | EAGLE text |
|
static |
Convert a board/footprint text.
t | EAGLE text |
|
static |
Convert a symbol pin.
p | EAGLE pin |
|
static |
Convert a THT pad.
p | EAGLE pad |
|
static |
Convert an SMT pad.
p | EAGLE pad |
|
delete |