198 FLASHING aFlash = FLASHING::DEFAULT )
const;
213 int aDepth = 0 )
const { }
267 if( aLayers.count() == 1 )
273 wxFAIL_MSG( wxT(
"Attempted to SetLayerSet() on a single-layer object." ) );
344 wxFAIL_MSG( wxT(
"virtual BOARD_ITEM::Move called for " ) +
GetClass() );
414 int aClearance,
int aError,
ERROR_LOC aErrorLoc,
415 bool ignoreLineWidth =
false )
const;
463 return _(
"(Deleted Item)" );
468 return wxT(
"DELETED_BOARD_ITEM" );
487 return (
this == &aItem ) ? 1.0 : 0.0;
492 return (
this == &aBoardItem );
497 return (
this == &aOther );
501 void Show(
int , std::ostream& )
const override {}
ERROR_LOC
When approximating an arc or circle, should the error be placed on the outside or inside of the curve...
ZONE_LAYER_OVERRIDE
Conditionally flashed vias and pads that interact with zones of different priority can be very squirr...
@ ZLO_FORCE_NO_ZONE_CONNECTION
Container for design settings for a BOARD object.
Abstract interface for BOARD_ITEMs capable of storing other items inside.
A base class for any item which can be embedded within the BOARD container class, and therefore insta...
BOARD_ITEM(BOARD_ITEM *aParent, KICAD_T idtype, PCB_LAYER_ID aLayer=F_Cu)
virtual void Mirror(const VECTOR2I &aCentre, FLIP_DIRECTION aFlipDirection)
Mirror this object relative to a given horizontal axis the layer is not changed.
virtual PCB_LAYER_ID GetLayer() const
Return the primary layer this item is on.
virtual void StyleFromSettings(const BOARD_DESIGN_SETTINGS &settings)
void SetParentGroup(PCB_GROUP *aGroup)
virtual void NormalizeForCompare()
Perform any normalization required to compare 2 graphics, especially if the can be rotated and/or fli...
void DeleteStructure()
Delete this object after removing from its parent if it has one.
void SwapItemData(BOARD_ITEM *aImage)
Swap data between aItem and aImage.
virtual STROKE_PARAMS GetStroke() const
virtual bool IsConnected() const
Returns information if the object is derived from BOARD_CONNECTED_ITEM.
virtual void SetLocked(bool aLocked)
virtual int BoardLayerCount() const
Return the total number of layers for the board that this item resides on.
PCB_GROUP * GetParentGroup() const
virtual void SetStroke(const STROKE_PARAMS &aStroke)
virtual void SetLayerSet(const LSET &aLayers)
wxString GetParentAsString() const
For "parent" property.
virtual bool IsKnockout() const
virtual void TransformShapeToPolygon(SHAPE_POLY_SET &aBuffer, PCB_LAYER_ID aLayer, int aClearance, int aError, ERROR_LOC aErrorLoc, bool ignoreLineWidth=false) const
Convert the item shape to a closed polygon.
virtual void Rotate(const VECTOR2I &aRotCentre, const EDA_ANGLE &aAngle)
Rotate this object.
virtual BOARD_ITEM * Duplicate() const
Create a copy of this BOARD_ITEM.
virtual VECTOR2I GetCenter() const
This defaults to the center of the bounding box if not overridden.
virtual void Move(const VECTOR2I &aMoveVector)
Move this object.
virtual bool IsOnLayer(PCB_LAYER_ID aLayer) const
Test to see if this object is on the given layer.
virtual void SetIsKnockout(bool aKnockout)
virtual void SetLayer(PCB_LAYER_ID aLayer)
Set the layer this item is on.
virtual std::vector< int > ViewGetLayers() const override
Return the all the layers within the VIEW the object is painted on.
virtual std::shared_ptr< SHAPE > GetEffectiveShape(PCB_LAYER_ID aLayer=UNDEFINED_LAYER, FLASHING aFlash=FLASHING::DEFAULT) const
Some pad shapes can be complex (rounded/chamfered rectangle), even without considering custom shapes.
virtual const BOARD * GetBoard() const
Return the BOARD in which this BOARD_ITEM resides, or NULL if none.
FOOTPRINT * GetParentFootprint() const
VECTOR2I GetFPRelativePosition() const
virtual LSET BoardLayerSet() const
Return the LSET for the board that this item resides on.
virtual LSET GetLayerSet() const
Return a std::bitset of all layers on which the item physically resides.
virtual bool IsTented(PCB_LAYER_ID aLayer) const
Checks if the given object is tented (its copper shape is covered by solder mask) on a given side of ...
virtual void swapData(BOARD_ITEM *aImage)
const KIFONT::METRICS & GetFontMetrics() const
void SetFPRelativePosition(const VECTOR2I &aPos)
static VECTOR2I ZeroOffset
A value of wxPoint(0,0) which can be passed to the Draw() functions.
virtual bool IsLocked() const
virtual bool operator==(const BOARD_ITEM &aItem) const =0
virtual bool HasDrilledHole() const
BOARD_ITEM_CONTAINER * GetParent() const
bool IsSideSpecific() const
virtual int BoardCopperLayerCount() const
Return the total number of copper layers for the board that this item resides on.
virtual bool IsOnCopperLayer() const
virtual void RunOnDescendants(const std::function< void(BOARD_ITEM *)> &aFunction, int aDepth=0) const
Invoke a function on all descendants.
virtual bool HasLineStroke() const
Check if this item has line stoke properties.
virtual void Normalize()
Perform any normalization required after a user rotate and/or flip.
virtual wxString layerMaskDescribe() const
Return a string (to be shown to the user) describing a layer mask.
wxString GetLayerName() const
Return the name of the PCB layer on which the item resides.
virtual double Similarity(const BOARD_ITEM &aItem) const =0
Return a measure of how likely the other object is to represent the same object.
virtual std::shared_ptr< SHAPE_SEGMENT > GetEffectiveHoleShape() const
virtual void Flip(const VECTOR2I &aCentre, FLIP_DIRECTION aFlipDirection)
Flip this object, i.e.
virtual bool HasHole() const
virtual void RunOnChildren(const std::function< void(BOARD_ITEM *)> &aFunction) const
Invoke a function on all children.
Information pertinent to a Pcbnew printed circuit board.
constexpr const Vec GetCenter() const
A singleton item of this class is returned for a weak reference that no longer exists.
wxString GetItemDescription(UNITS_PROVIDER *aUnitsProvider, bool aFull) const override
Return a user-visible description string of this item.
static DELETED_BOARD_ITEM * GetInstance()
wxString GetClass() const override
Return the class name.
double Similarity(const BOARD_ITEM &aItem) const override
Return a measure of how likely the other object is to represent the same object.
VECTOR2I GetPosition() const override
void SetPosition(const VECTOR2I &) override
bool operator==(const BOARD_ITEM &aBoardItem) const override
bool operator==(const DELETED_BOARD_ITEM &aOther) const
A base class for most all the KiCad significant classes used in schematics and boards.
virtual VECTOR2I GetPosition() const
virtual void SetPosition(const VECTOR2I &aPos)
virtual const BOX2I GetBoundingBox() const
Return the orthogonal bounding box of this object for display purposes.
virtual wxString GetClass() const =0
Return the class name.
EDA_ITEM * m_parent
Linked list: Link (parent struct)
LSET is a set of PCB_LAYER_IDs.
LSEQ Seq(const LSEQ &aSequence) const
Return an LSEQ from the union of this LSET and a desired sequence.
Base PCB main window class for Pcbnew, Gerbview, and CvPcb footprint viewer.
A set of BOARD_ITEMs (i.e., without duplicates).
Represent a set of closed polygons.
An abstract shape on 2D plane.
Simple container to manage line stroke parameters.
FLASHING
Enum used during connectivity building to ensure we do not query connectivity while building the data...
bool IsCopperLayer(int aLayerId)
Tests whether a layer is a copper layer.
PCB_LAYER_ID
A quick note on layer IDs:
#define DECLARE_ENUM_TO_WXANY(type)
bool operator()(const BOARD_ITEM *a, const BOARD_ITEM *b) const
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.
@ NOT_USED
the 3d code uses this value
VECTOR2< int32_t > VECTOR2I