37#define TARGET_PIN_RADIUS   schIUScale.MilsToIU( 15 ) 
   52    SCH_PIN( 
LIB_SYMBOL* aParentSymbol, 
const wxString& aName, 
const wxString& aNumber,
 
   54             int aNameTextSize, 
int aNumTextSize, 
int aBodyStyle, 
const VECTOR2I& aPos, 
int aUnit );
 
   65    SCH_PIN( 
SCH_SYMBOL* aParentSymbol, 
const wxString& aNumber, 
const wxString& aAlt,
 
   76        return wxT( 
"SCH_PIN" );
 
 
  116    const wxString& 
GetName() 
const;
 
  118    void SetName( 
const wxString& aName );
 
  152    void SetNumber( 
const wxString& aNumber );
 
  170        return const_cast<std::map<wxString, ALT>&
>(
 
  171                static_cast<const SCH_PIN*
>( this )->GetAlternates() );
 
 
  190    void SetAlt( 
const wxString& aAlt );
 
  201    void Show( 
int nestLevel, std::ostream& os ) 
const override;
 
  204    bool HitTest( 
const VECTOR2I& aPosition, 
int aAccuracy = 0 ) 
const override;
 
  206    bool HitTest( 
const BOX2I& aRect, 
bool aContained, 
int aAccuracy = 0 ) 
const override;
 
  225                          bool aIncludeElectricalType ) 
const;
 
  266    void Rotate( 
const VECTOR2I& aCenter, 
bool aRotateCCW = 
true ) 
override;
 
  282                       int aTextInside, 
bool aDrawPinNum, 
bool aDrawPinName, 
bool aDimmed ) 
const;
 
  285                      bool aDimmed ) 
const;
 
  288               int aUnit, 
int aBodyStyle, 
const VECTOR2I& aOffset, 
bool aDimmed ) 
override;
 
  366    std::ostream& 
operator<<( std::ostream& aStream );
 
  385    int compare( 
const SCH_ITEM& aOther, 
int aCompareFlags = 0 ) 
const override;
 
 
BITMAPS
A list of all bitmap identifiers.
 
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.
 
EDA_ITEM(EDA_ITEM *parent, KICAD_T idType, bool isSCH_ITEM=false, bool isBOARD_ITEM=false)
 
FONT is an abstract base class for both outline and stroke fonts.
 
Define a library symbol object.
 
A pin layout helper is a class that manages the layout of the parts of a pin on a schematic symbol:
 
Base plotter engine class.
 
Base class for any item which can be embedded within the SCHEMATIC container class,...
 
SCH_ITEM(EDA_ITEM *aParent, KICAD_T aType, int aUnit=0, int aBodyStyle=0)
 
void Rotate(const VECTOR2I &aCenter, bool aRotateCCW=true) override
Rotate the item around aCenter 90 degrees in the clockwise direction.
 
std::ostream & operator<<(std::ostream &aStream)
 
void SetAlt(const wxString &aAlt)
Set the name of the alternate pin.
 
void PlotPinTexts(PLOTTER *aPlotter, const VECTOR2I &aPinPos, PIN_ORIENTATION aPinOrient, int aTextInside, bool aDrawPinNum, bool aDrawPinName, bool aDimmed) const
Plot the pin name and number.
 
VECTOR2I GetLocalPosition() const
 
int GetNumberTextSize() const
 
std::optional< bool > m_hidden
 
bool Matches(const EDA_SEARCH_DATA &aSearchData, void *aAuxData) const override
Compare the item against the search criteria in aSearchData.
 
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.
 
std::unique_ptr< PIN_LAYOUT_CACHE > m_layoutCache
The layout cache for this pin.
 
void MirrorVerticallyPin(int aCenter)
 
void validateExtentsCache(KIFONT::FONT *aFont, int aSize, const wxString &aText, EXTENTS_CACHE *aCache) const
 
bool operator>(const SCH_ITEM &aRhs) const
 
const BOX2I ViewBBox() const override
Return the bounding box of the item covering all its layers.
 
std::vector< int > ViewGetLayers() const override
Return the layers the item is drawn on (which may be more than its "home" layer)
 
const std::map< wxString, ALT > & GetAlternates() const
 
void CalcEdit(const VECTOR2I &aPosition) override
Calculate the attributes of an item at aPosition when it is being edited.
 
void SetNumber(const wxString &aNumber)
 
std::optional< int > m_nameTextSize
 
PIN_ORIENTATION PinDrawOrient(const TRANSFORM &aTransform) const
Return the pin real orientation (PIN_UP, PIN_DOWN, PIN_RIGHT, PIN_LEFT), according to its orientation...
 
void SetVisible(bool aVisible)
 
void ChangeLength(int aLength)
Change the length of a pin and adjust its position based on orientation.
 
ALT GetAlt(const wxString &aAlt)
 
bool HasConnectivityChanges(const SCH_ITEM *aItem, const SCH_SHEET_PATH *aInstance=nullptr) const override
Check if aItem has connectivity changes against this object.
 
SCH_PIN & operator=(const SCH_PIN &aPin)
 
wxString GetShownNumber() const
 
std::optional< wxString > GetSmallestLogicalNumber() const
Return the smallest logical pin number if this pin uses stacked notation and it is valid.
 
void Move(const VECTOR2I &aOffset) override
Move the item by aMoveVector to a new position.
 
std::map< const SCH_SHEET_PATH, std::pair< wxString, bool > > m_net_name_map
 
PIN_ORIENTATION m_orientation
 
const wxString & GetOperatingPoint() const
 
void SetOrientation(PIN_ORIENTATION aOrientation)
 
void SetName(const wxString &aName)
 
bool IsGlobalPower() const
Return whether this pin forms a global power connection: i.e., is part of a power symbol and of type ...
 
wxString getItemDescription(ALT *aAlt) const
 
bool ConnectionPropagatesTo(const EDA_ITEM *aItem) const override
Return true if this item should propagate connection info to aItem.
 
std::optional< int > m_numTextSize
 
VECTOR2I GetPinRoot() const
 
bool IsLocalPower() const
Local power pin is the same except that it is sheet-local and it does not support the legacy hidden p...
 
ELECTRICAL_PINTYPE m_type
 
void SetLibPin(SCH_PIN *aLibPin)
 
wxString GetEffectivePadNumber() const
Return the pin number to be used for deterministic operations such as auto‑generated net names.
 
void MirrorVertically(int aCenter) override
Mirror item vertically about aCenter.
 
SCH_PIN * GetLibPin() const
 
void SetPosition(const VECTOR2I &aPos) override
 
double Similarity(const SCH_ITEM &aOther) const override
Return a measure of how likely the other object is to represent the same object.
 
bool IsConnectable() const override
 
void SetIsDangling(bool aIsDangling)
 
wxString GetElectricalTypeName() const
 
std::vector< wxString > GetStackedPinNumbers(bool *aValid=nullptr) const
 
int GetPenWidth() const override
 
std::map< wxString, ALT > m_alternates
 
const wxString & GetName() const
 
wxString GetFriendlyName() const override
 
int GetStackedPinCount(bool *aValid=nullptr) const
Return the count of logical pins represented by this pin's stacked notation.
 
void SetLength(int aLength)
 
bool IsDangling() const override
 
void Plot(PLOTTER *aPlotter, bool aBackground, const SCH_PLOT_OPTS &aPlotOpts, int aUnit, int aBodyStyle, const VECTOR2I &aOffset, bool aDimmed) override
Plot the item to aPlotter.
 
void MirrorHorizontally(int aCenter) override
These transforms have effect only if the pin has a LIB_SYMBOL as parent.
 
std::recursive_mutex m_netmap_mutex
The name that this pin connection will drive onto a net.
 
PIN_ORIENTATION GetOrientation() const
 
wxString GetClass() const override
Return the class name.
 
void SetNumberTextSize(int aSize)
 
void SetShape(GRAPHIC_PINSHAPE aShape)
 
void RotatePin(const VECTOR2I &aCenter, bool aRotateCCW=true)
 
std::map< wxString, ALT > & GetAlternates()
 
VECTOR2I GetPosition() const override
 
wxString GetCanonicalElectricalTypeName() const
 
bool Replace(const EDA_SEARCH_DATA &aSearchData, void *aAuxData) override
Perform a text replace using the find and replace criteria in aSearchData on items that support text ...
 
int GetNameTextSize() const
 
wxString GetItemDescription(UNITS_PROVIDER *aUnitsProvider, bool aFull) const override
Return a user-visible description string of this item.
 
wxString m_operatingPoint
 
int compare(const SCH_ITEM &aOther, int aCompareFlags=0) const override
The pin specific sort order is as follows:
 
wxString GetShownName() const
 
static bool ClassOf(const EDA_ITEM *aItem)
 
void MirrorHorizontallyPin(int aCenter)
These transforms have always effects.
 
bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const override
Test if aPosition is inside or on the boundary of this item.
 
PIN_LAYOUT_CACHE & GetLayoutCache() const
Get the layout cache associated with this pin.
 
void SetOperatingPoint(const wxString &aText)
 
void SetType(ELECTRICAL_PINTYPE aType)
 
const wxString & GetBaseName() const
Get the name without any alternates.
 
void ClearDefaultNetName(const SCH_SHEET_PATH *aPath)
 
SCH_PIN(LIB_SYMBOL *aParentSymbol)
 
bool IsPointClickableAnchor(const VECTOR2I &aPos) const override
 
bool IsStacked(const SCH_PIN *aPin) const
 
const wxString & GetNumber() const
 
EDA_ITEM * Clone() const override
Create a duplicate of this item with linked list members set to NULL.
 
const BOX2I GetBoundingBox() const override
Return the orthogonal bounding box of this object for display purposes.
 
wxString GetDefaultNetName(const SCH_SHEET_PATH &aPath, bool aForceNoConnect=false)
 
std::optional< int > m_length
 
static wxString GetCanonicalElectricalTypeName(ELECTRICAL_PINTYPE aType)
Return a string giving the electrical type of a pin.
 
GRAPHIC_PINSHAPE GetShape() const
 
void PlotPinType(PLOTTER *aPlotter, const VECTOR2I &aPosition, PIN_ORIENTATION aOrientation, bool aDimmed) const
 
bool IsPower() const
Check if the pin is either a global or local power pin.
 
ELECTRICAL_PINTYPE GetType() const
 
BITMAPS GetMenuImage() const override
Return a pointer to an image to be used in menus.
 
void SetNameTextSize(int aSize)
 
Handle access to a stack of flattened SCH_SHEET objects by way of a path for creating a flattened sch...
 
#define SHOW_ELEC_TYPE
Show pin electrical type.
 
ELECTRICAL_PINTYPE
The symbol library pin object electrical types used in ERC tests.
 
PIN_ORIENTATION
The symbol library pin object orientations.
 
ELECTRICAL_PINTYPE m_Type
 
VECTOR2< int32_t > VECTOR2I