56 return wxT(
"PCB_SHAPE" );
59 void Serialize( google::protobuf::Any &aContainer )
const override;
60 bool Deserialize(
const google::protobuf::Any &aContainer )
override;
66 bool IsType(
const std::vector<KICAD_T>& aScanTypes )
const override;
95 virtual std::vector<VECTOR2I>
GetCorners()
const;
107 FLASHING aFlash = FLASHING::DEFAULT )
const override;
118 return hitTest( aPosition, aAccuracy );
121 bool HitTest(
const BOX2I& aRect,
bool aContained,
int aAccuracy = 0 )
const override
123 return hitTest( aRect, aContained, aAccuracy );
143 void Scale(
double aScale );
157 bool ignoreLineWidth =
false )
const override;
167 void ViewGetLayers(
int aLayers[],
int& aCount )
const override;
178 void Show(
int nestLevel, std::ostream& os )
const override { ShowDummy( os ); }
ERROR_LOC
When approximating an arc or circle, should the error be placed on the outside or inside of the curve...
BITMAPS
A list of all bitmap identifiers.
A base class derived from BOARD_ITEM for items that can be connected and have a net,...
Container for design settings for a BOARD object.
A base class for any item which can be embedded within the BOARD container class, and therefore insta...
The base class for create windows for drawing purpose.
A base class for most all the KiCad significant classes used in schematics and boards.
KICAD_T Type() const
Returns the type of object.
VECTOR2I getCenter() const
bool hitTest(const VECTOR2I &aPosition, int aAccuracy=0) const
void setPosition(const VECTOR2I &aPos)
const BOX2I getBoundingBox() const
VECTOR2I getPosition() const
wxString getFriendlyName() const
Hold a (potentially large) number of VIEW_ITEMs and renders them on a graphics device provided by the...
An abstract class from which implementation specific LINE_READERs may be derived to read single lines...
EDA_MSG_PANEL items for displaying messages.
const BOX2I GetBoundingBox() const override
Return the orthogonal bounding box of this object for display purposes.
void GetMsgPanelInfo(EDA_DRAW_FRAME *aFrame, std::vector< MSG_PANEL_ITEM > &aList) override
Populate aList of MSG_PANEL_ITEM objects with it's internal state for display purposes.
void swapData(BOARD_ITEM *aImage) override
bool IsConnected() const override
Returns information if the object is derived from BOARD_CONNECTED_ITEM.
VECTOR2I GetCenter() const override
This defaults to the center of the bounding box if not overridden.
void Rotate(const VECTOR2I &aRotCentre, const EDA_ANGLE &aAngle) override
Rotate this object.
BITMAPS GetMenuImage() const override
Return a pointer to an image to be used in menus.
bool HasLineStroke() const override
Check if this item has line stoke properties.
int GetWidth() const override
const BOX2I ViewBBox() const override
Return the bounding box of the item covering all its layers.
bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const override
Test if aPosition is inside or on the boundary of this item.
std::shared_ptr< SHAPE > GetEffectiveShape(PCB_LAYER_ID aLayer=UNDEFINED_LAYER, FLASHING aFlash=FLASHING::DEFAULT) const override
Make a set of SHAPE objects representing the PCB_SHAPE.
void NormalizeForCompare() override
Normalize coordinates to compare 2 similar PCB_SHAPES similat to Normalize(), but also normalize SEGM...
void ViewGetLayers(int aLayers[], int &aCount) const override
void SetPosition(const VECTOR2I &aPos) override
const VECTOR2I GetFocusPosition() const override
Allows items to return their visual center rather than their anchor.
void Flip(const VECTOR2I &aCentre, FLIP_DIRECTION aFlipDirection) override
Flip this object, i.e.
virtual std::vector< VECTOR2I > GetCorners() const
Return 4 corners for a rectangle or rotated rectangle (stored as a poly).
bool IsProxyItem() const override
static bool ClassOf(const EDA_ITEM *aItem)
bool operator==(const PCB_SHAPE &aShape) const
void SetLayer(PCB_LAYER_ID aLayer) override
Set the layer this item is on.
wxString GetFriendlyName() const override
void TransformShapeToPolygon(SHAPE_POLY_SET &aBuffer, PCB_LAYER_ID aLayer, int aClearance, int aError, ERROR_LOC aErrorLoc, bool ignoreLineWidth=false) const override
Convert the shape to a closed polygon.
STROKE_PARAMS GetStroke() const override
void SetIsProxyItem(bool aIsProxy=true) override
void StyleFromSettings(const BOARD_DESIGN_SETTINGS &settings) override
void Move(const VECTOR2I &aMoveVector) override
Move this object.
std::vector< VECTOR2I > GetConnectionPoints() const
bool Deserialize(const google::protobuf::Any &aContainer) override
Deserializes the given protobuf message into this object.
EDA_ITEM * Clone() const override
Create a duplicate of this item with linked list members set to NULL.
double ViewGetLOD(int aLayer, KIGFX::VIEW *aView) const override
Return the level of detail (LOD) of the item.
wxString GetItemDescription(UNITS_PROVIDER *aUnitsProvider, bool aFull) const override
Return a user-visible description string of this item.
void Scale(double aScale)
bool HitTest(const BOX2I &aRect, bool aContained, int aAccuracy=0) const override
Test if aRect intersects this item.
void Serialize(google::protobuf::Any &aContainer) const override
Serializes this object to the given Any message.
void SetStroke(const STROKE_PARAMS &aStroke) override
void Normalize() override
Perform any normalization required after a user rotate and/or flip.
bool IsType(const std::vector< KICAD_T > &aScanTypes) const override
Check whether the item is one of the listed types.
virtual void Mirror(const VECTOR2I &aCentre, FLIP_DIRECTION aFlipDirection)
wxString GetClass() const override
Return the class name.
double Similarity(const BOARD_ITEM &aBoardItem) const override
Return a measure of how likely the other object is to represent the same object.
VECTOR2I GetPosition() const override
PCB_LAYER_ID GetLayer() const override
Return the primary layer this item is on.
Represent a set of closed polygons.
Simple container to manage line stroke parameters.
FLASHING
Enum used during connectivity building to ensure we do not query connectivity while building the data...
PCB_LAYER_ID
A quick note on layer IDs:
bool operator()(const BOARD_ITEM *aFirst, const BOARD_ITEM *aSecond) const
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.
@ PCB_SHAPE_T
class PCB_SHAPE, a segment not on copper layers