53#define MINIMUM_SELECTION_DISTANCE 2
107 switch ( aItem->
Type() )
155 virtual void EndEdit(
bool aClosed =
false ) {}
181 const TRANSFORM& aTransform,
bool aDimmed );
207 void ViewGetLayers(
int aLayers[],
int& aCount )
const override;
216 bool HitTest(
const BOX2I& aRect,
bool aContained,
int aAccuracy = 0 )
const override;
243 return *
this == *aOther;
304 const TRANSFORM& aTransform,
bool aDimmed )
const = 0;
321 void Show(
int nestLevel, std::ostream& os )
const override { ShowDummy( os ); }
345 virtual int compare(
const LIB_ITEM& aOther,
int aCompareFlags = 0 )
const;
356 const TRANSFORM& aTransform,
bool aDimmed ) = 0;
The base class for create windows for drawing purpose.
A base class for most all the KiCad significant classes used in schematics and boards.
virtual const BOX2I GetBoundingBox() const
Return the orthogonal bounding box of this object for display purposes.
KICAD_T Type() const
Returns the type of object.
virtual bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const
Test if aPosition is inside or on the boundary of this item.
EDA_ITEM * m_parent
Linked list: Link (parent struct)
FONT is an abstract base class for both outline and stroke fonts.
Container for all the knowledge about how graphical objects are drawn on any output surface/device.
int GetDefaultPenWidth() const
int GetMinPenWidth() const
The base class for drawable items used by schematic library symbols.
virtual wxString GetTypeName() const =0
Provide a user-consumable name of the object type.
virtual void Plot(PLOTTER *aPlotter, bool aBackground, const VECTOR2I &aOffset, const TRANSFORM &aTransform, bool aDimmed) const =0
Plot the draw item using the plot object.
virtual void EndEdit(bool aClosed=false)
End an object editing action.
virtual int GetPenWidth() const =0
const wxString & GetDefaultFont() const
virtual void print(const RENDER_SETTINGS *aSettings, const VECTOR2I &aOffset, void *aData, const TRANSFORM &aTransform, bool aDimmed)=0
Print the item to aDC.
bool operator==(const LIB_ITEM &aOther) const
Test LIB_ITEM objects for equivalence.
bool operator==(const LIB_ITEM *aOther) const
virtual void CalcEdit(const VECTOR2I &aPosition)
Calculate the attributes of an item at aPosition when it is being edited.
COMPARE_FLAGS
The list of flags used by the compare function.
int m_convert
Shape identification for alternate body styles.
virtual int compare(const LIB_ITEM &aOther, int aCompareFlags=0) const
Provide the draw object specific comparison called by the == and < operators.
virtual int GetEffectivePenWidth(const RENDER_SETTINGS *aSettings) const
virtual void MirrorHorizontal(const VECTOR2I &aCenter)=0
Mirror the draw object along the horizontal (X) axis about aCenter point.
virtual void Rotate(const VECTOR2I &aCenter, bool aRotateCCW=true)=0
Rotate the object about aCenter point.
LIB_ITEM * Duplicate() const
Create a copy of this LIB_ITEM (with a new Uuid).
virtual void MirrorVertical(const VECTOR2I &aCenter)=0
Mirror the draw object along the MirrorVertical (Y) axis about aCenter point.
virtual void Print(const RENDER_SETTINGS *aSettings, const VECTOR2I &aOffset, void *aData, const TRANSFORM &aTransform, bool aDimmed)
Draw an item.
static bool ClassOf(const EDA_ITEM *aItem)
void SetPrivate(bool aPrivate)
virtual void MoveTo(const VECTOR2I &aPosition)=0
Move a draw object to aPosition.
const KIFONT::METRICS & GetFontMetrics() const
bool m_private
Private items are shown only in the Symbol Editor.
const BOX2I GetBoundingBox() const override
int m_unit
Unit identification for multiple parts per package.
virtual void Offset(const VECTOR2I &aOffset)=0
Set the drawing object by aOffset from the current position.
virtual bool ContinueEdit(const VECTOR2I &aPosition)
Continue an edit in progress at aPosition.
bool operator<(const LIB_ITEM &aOther) const
Test if another draw item is less than this draw object.
void SetPosition(const VECTOR2I &aPosition) override
bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const override
Test if aPosition is inside or on the boundary of this item.
void GetMsgPanelInfo(EDA_DRAW_FRAME *aFrame, std::vector< MSG_PANEL_ITEM > &aList) override
Display basic info (type, part and convert) about the current item in message panel.
LIB_SYMBOL * GetParent() const
void ViewGetLayers(int aLayers[], int &aCount) const override
Return the all the layers within the VIEW the object is painted on.
virtual void BeginEdit(const VECTOR2I &aPosition)
Begin drawing a symbol library draw item at aPosition.
void SetConvert(int aConvert)
Define a library symbol object.
An abstract class from which implementation specific LINE_READERs may be derived to read single lines...
EDA_MSG_PANEL items for displaying messages.
Base plotter engine class.
std::vector< LIB_PIN * > LIB_PINS
Helper for defining a list of pin object pointers.
bool operator()(const LIB_ITEM *aFirst, const LIB_ITEM *aSecond) const
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.