KiCad PCB EDA Suite
EDA_SHAPE_DESC Struct Reference

Public Member Functions

 EDA_SHAPE_DESC ()
 

Detailed Description

Definition at line 1601 of file eda_shape.cpp.

Constructor & Destructor Documentation

◆ EDA_SHAPE_DESC()

EDA_SHAPE_DESC::EDA_SHAPE_DESC ( )
inline

Definition at line 1603 of file eda_shape.cpp.

1604  {
1606  .Map( SHAPE_T::SEGMENT, _HKI( "Segment" ) )
1607  .Map( SHAPE_T::RECT, _HKI( "Rectangle" ) )
1608  .Map( SHAPE_T::ARC, _HKI( "Arc" ) )
1609  .Map( SHAPE_T::CIRCLE, _HKI( "Circle" ) )
1610  .Map( SHAPE_T::POLY, _HKI( "Polygon" ) )
1611  .Map( SHAPE_T::BEZIER, _HKI( "Bezier" ) );
1613  .Map( PLOT_DASH_TYPE::DEFAULT, _HKI( "Default" ) )
1614  .Map( PLOT_DASH_TYPE::SOLID, _HKI( "Solid" ) )
1615  .Map( PLOT_DASH_TYPE::DASH, _HKI( "Dashed" ) )
1616  .Map( PLOT_DASH_TYPE::DOT, _HKI( "Dotted" ) )
1617  .Map( PLOT_DASH_TYPE::DASHDOT, _HKI( "Dash-Dot" ) );
1618 
1621  propMgr.AddProperty( new PROPERTY_ENUM<EDA_SHAPE, SHAPE_T>( _HKI( "Shape" ),
1623  propMgr.AddProperty( new PROPERTY<EDA_SHAPE, int>( _HKI( "Start X" ),
1625  propMgr.AddProperty( new PROPERTY<EDA_SHAPE, int>( _HKI( "Start Y" ),
1627  propMgr.AddProperty( new PROPERTY<EDA_SHAPE, int>( _HKI( "End X" ),
1629  propMgr.AddProperty( new PROPERTY<EDA_SHAPE, int>( _HKI( "End Y" ),
1631  // TODO: m_arcCenter, m_bezierC1, m_bezierC2, m_poly
1632  propMgr.AddProperty( new PROPERTY<EDA_SHAPE, int>( _HKI( "Line Width" ),
1634  }
int GetStartY()
Definition: eda_shape.h:98
static PROPERTY_MANAGER & Instance()
Definition: property_mgr.h:65
int GetWidth() const
Definition: eda_shape.h:89
void SetStartY(int y)
Definition: eda_shape.h:107
int GetEndY()
Definition: eda_shape.h:123
static ENUM_MAP< T > & Instance()
Definition: property.h:510
void SetEndY(int y)
Definition: eda_shape.h:132
int GetStartX()
Definition: eda_shape.h:99
#define REGISTER_TYPE(x)
Definition: property_mgr.h:248
int GetEndX()
Definition: eda_shape.h:124
void SetWidth(int aWidth)
Definition: eda_shape.h:88
void SetEndX(int x)
Definition: eda_shape.h:138
void AddProperty(PROPERTY_BASE *aProperty)
Register a property.
void SetShape(SHAPE_T aShape)
Definition: eda_shape.h:91
Provide class metadata.Helper macro to map type hashes to names.
Definition: property_mgr.h:62
SHAPE_T GetShape() const
Definition: eda_shape.h:92
#define _HKI(x)
void SetStartX(int x)
Definition: eda_shape.h:113

References _HKI, PROPERTY_MANAGER::AddProperty(), ARC, BEZIER, CIRCLE, DASH, DASHDOT, DEFAULT, DOT, EDA_SHAPE::GetEndX(), EDA_SHAPE::GetEndY(), EDA_SHAPE::GetShape(), EDA_SHAPE::GetStartX(), EDA_SHAPE::GetStartY(), EDA_SHAPE::GetWidth(), PROPERTY_MANAGER::Instance(), ENUM_MAP< T >::Instance(), POLY, RECT, REGISTER_TYPE, SEGMENT, EDA_SHAPE::SetEndX(), EDA_SHAPE::SetEndY(), EDA_SHAPE::SetShape(), EDA_SHAPE::SetStartX(), EDA_SHAPE::SetStartY(), EDA_SHAPE::SetWidth(), and SOLID.


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