KiCad PCB EDA Suite
Loading...
Searching...
No Matches
pad.h
Go to the documentation of this file.
1/*
2 * This program source code file is part of KiCad, a free EDA CAD application.
3 *
4 * Copyright (C) 2018 Jean-Pierre Charras, jp.charras at wanadoo.fr
5 * Copyright (C) 1992-2024 KiCad Developers, see AUTHORS.txt for contributors.
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, you may find one here:
19 * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
20 * or you may search the http://www.gnu.org website for the version 2 license,
21 * or you may write to the Free Software Foundation, Inc.,
22 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
23 */
24
25#pragma once
26
27#include <mutex>
28#include <array>
29
31#include <core/arraydim.h>
32#include <core/mirror.h>
33#include <geometry/eda_angle.h>
36#include <lset.h>
37#include <padstack.h>
38#include <zones.h>
39
40class PCB_SHAPE;
41class SHAPE;
42class SHAPE_SEGMENT;
43
44class LINE_READER;
45class EDA_3D_CANVAS;
46class FOOTPRINT;
47
48namespace KIGFX
49{
50 class VIEW;
51}
52
54{
55public:
56 PAD( FOOTPRINT* parent );
57
58 // Copy constructor & operator= are needed because the list of basic shapes
59 // must be duplicated in copy.
60 PAD( const PAD& aPad );
61 PAD& operator=( const PAD &aOther );
62
63 void Serialize( google::protobuf::Any &aContainer ) const override;
64 bool Deserialize( const google::protobuf::Any &aContainer ) override;
65
66 /*
67 * Default layers used for pads, according to the pad type.
68 *
69 * This is default values only, they can be changed for a given pad.
70 */
71 static LSET PTHMask();
72 static LSET SMDMask();
73 static LSET ConnSMDMask();
75 static LSET UnplatedHoleMask();
76 static LSET ApertureMask();
77
78 static inline bool ClassOf( const EDA_ITEM* aItem )
79 {
80 return aItem && PCB_PAD_T == aItem->Type();
81 }
82
83 bool IsType( const std::vector<KICAD_T>& aScanTypes ) const override
84 {
85 if( BOARD_CONNECTED_ITEM::IsType( aScanTypes ) )
86 return true;
87
88 for( KICAD_T scanType : aScanTypes )
89 {
90 if( HasHole() )
91 {
92 if( scanType == PCB_LOCATE_HOLE_T )
93 return true;
94 else if( scanType == PCB_LOCATE_PTH_T && m_attribute != PAD_ATTRIB::NPTH )
95 return true;
96 else if( scanType == PCB_LOCATE_NPTH_T && m_attribute == PAD_ATTRIB::NPTH )
97 return true;
98 }
99 }
100
101 return false;
102 }
103
104 bool HasHole() const override
105 {
106 return GetDrillSizeX() > 0 && GetDrillSizeY() > 0;
107 }
108
109 bool HasDrilledHole() const override
110 {
111 return HasHole() && GetDrillSizeX() == GetDrillSizeY();
112 }
113
114 bool IsLocked() const override;
115
123 void ImportSettingsFrom( const PAD& aMasterPad );
124
128 bool IsFlipped() const;
129
133 void SetNumber( const wxString& aNumber ) { m_number = aNumber; }
134 const wxString& GetNumber() const { return m_number; }
135
139 bool CanHaveNumber() const;
140
144 void SetPinFunction( const wxString& aName ) { m_pinFunction = aName; }
145 const wxString& GetPinFunction() const { return m_pinFunction; }
146
150 void SetPinType( const wxString& aType ) { m_pinType = aType; }
151 const wxString& GetPinType() const { return m_pinType; }
152
157 bool SameLogicalPadAs( const PAD* aOther ) const
158 {
159 // hide tricks behind sensible API
160 return GetParentFootprint() == aOther->GetParentFootprint()
161 && !m_number.IsEmpty() && m_number == aOther->m_number;
162 }
163
167 bool SharesNetTieGroup( const PAD* aOther ) const;
168
173 bool IsNoConnectPad() const;
174
179 bool IsFreePad() const;
180
184 void SetShape( PCB_LAYER_ID aLayer, PAD_SHAPE aShape )
185 {
186 m_padStack.SetShape( aShape, aLayer );
187 SetDirty();
188 }
189
193 PAD_SHAPE GetShape( PCB_LAYER_ID aLayer ) const { return m_padStack.Shape( aLayer ); }
194
195 // Used for the properties panel, which does not support padstacks at the moment
197 {
198 m_padStack.SetShape( aShape, F_Cu );
199 SetDirty();
200 }
201
203
204 void SetPosition( const VECTOR2I& aPos ) override
205 {
206 m_pos = aPos;
207 SetDirty();
208 }
209
210 VECTOR2I GetPosition() const override { return m_pos; }
211
216 {
217 return m_padStack.AnchorShape( aLayer );
218 }
219
224 {
226 }
227
234 {
236 }
237
245 {
246 m_padStack.SetAnchorShape( aShape == PAD_SHAPE::RECTANGLE
247 ? PAD_SHAPE::RECTANGLE
248 : PAD_SHAPE::CIRCLE,
249 aLayer );
250 SetDirty();
251 }
252
256 bool IsOnCopperLayer() const override;
257
258 void SetY( int y ) { m_pos.y = y; SetDirty(); }
259 void SetX( int x ) { m_pos.x = x; SetDirty(); }
260
261 void SetSize( PCB_LAYER_ID aLayer, const VECTOR2I& aSize )
262 {
263 m_padStack.SetSize( aSize, aLayer );
264 SetDirty();
265 }
266 const VECTOR2I& GetSize( PCB_LAYER_ID aLayer ) const { return m_padStack.Size( aLayer ); }
267
268 // These accessors are for the properties panel, which does not have the ability to deal with
269 // custom padstacks where the properties can vary by layer. The properties should be disabled
270 // in the GUI when the padstack mode is set to anything other than NORMAL, but so that the code
271 // compiles, these are set up to work with the front layer (in other words, assume the mode is
272 // NORMAL, where F_Cu stores the whole padstack data)
273 void SetSizeX( const int aX )
274 {
275 if( aX > 0 )
276 {
278 SetDirty();
279 }
280 }
281
282 int GetSizeX() const { return m_padStack.Size( PADSTACK::ALL_LAYERS ).x; }
283
284 void SetSizeY( const int aY )
285 {
286 if( aY > 0 )
287 {
289 SetDirty();
290 }
291 }
292
293 int GetSizeY() const { return m_padStack.Size( PADSTACK::ALL_LAYERS ).y; }
294
295 void SetDelta( PCB_LAYER_ID aLayer, const VECTOR2I& aSize )
296 {
297 m_padStack.TrapezoidDeltaSize( aLayer ) = aSize;
298 SetDirty();
299 }
300
301 const VECTOR2I& GetDelta( PCB_LAYER_ID aLayer ) const
302 {
303 return m_padStack.TrapezoidDeltaSize( aLayer );
304 }
305
306 void SetDrillSize( const VECTOR2I& aSize ) { m_padStack.Drill().size = aSize; SetDirty(); }
307 const VECTOR2I& GetDrillSize() const { return m_padStack.Drill().size; }
308 void SetDrillSizeX( const int aX );
309 int GetDrillSizeX() const { return m_padStack.Drill().size.x; }
310 void SetDrillSizeY( const int aY ) { m_padStack.Drill().size.y = aY; SetDirty(); }
311 int GetDrillSizeY() const { return m_padStack.Drill().size.y; }
312
313 void SetOffset( PCB_LAYER_ID aLayer, const VECTOR2I& aOffset )
314 {
315 m_padStack.Offset( aLayer ) = aOffset;
316 SetDirty();
317 }
318
319 const VECTOR2I& GetOffset( PCB_LAYER_ID aLayer ) const { return m_padStack.Offset( aLayer ); }
320
321 VECTOR2I GetCenter() const override { return GetPosition(); }
322
323 const PADSTACK& Padstack() const { return m_padStack; }
325 void SetPadstack( const PADSTACK& aPadstack ) { m_padStack = aPadstack; }
326
338 void AddPrimitivePoly( PCB_LAYER_ID aLayer, const SHAPE_POLY_SET& aPoly, int aThickness,
339 bool aFilled );
340 void AddPrimitivePoly( PCB_LAYER_ID aLayer, const std::vector<VECTOR2I>& aPoly, int aThickness,
341 bool aFilled );
342
355 void MergePrimitivesAsPolygon( PCB_LAYER_ID aLayer, SHAPE_POLY_SET* aMergedPolygon,
356 ERROR_LOC aErrorLoc = ERROR_INSIDE ) const;
357
363
367 const std::vector<std::shared_ptr<PCB_SHAPE>>& GetPrimitives( PCB_LAYER_ID aLayer ) const
368 {
369 return m_padStack.Primitives( aLayer );
370 }
371
372 void Flip( const VECTOR2I& VECTOR2I, FLIP_DIRECTION aFlipDirection ) override;
373
378 void FlipPrimitives( FLIP_DIRECTION aFlipDirection );
379
384 void ReplacePrimitives( PCB_LAYER_ID aLayer,
385 const std::vector<std::shared_ptr<PCB_SHAPE>>& aPrimitivesList );
386
391 void AppendPrimitives( PCB_LAYER_ID aLayer,
392 const std::vector<std::shared_ptr<PCB_SHAPE>>& aPrimitivesList );
393
397 void AddPrimitive( PCB_LAYER_ID aLayer, PCB_SHAPE* aPrimitive );
398
404 void SetOrientation( const EDA_ANGLE& aAngle );
405 void SetFPRelativeOrientation( const EDA_ANGLE& aAngle );
406
412
413 // For property system
414 void SetOrientationDegrees( double aOrientation )
415 {
416 SetOrientation( EDA_ANGLE( aOrientation, DEGREES_T ) );
417 }
419 {
421 }
422
423 void SetDrillShape( PAD_DRILL_SHAPE aShape );
425
426 bool IsDirty() const
427 {
429 }
430
431 void SetDirty()
432 {
433 m_shapesDirty = true;
436 }
437
438 void SetLayerSet( const LSET& aLayers ) override { m_padStack.SetLayerSet( aLayers ); }
439 LSET GetLayerSet() const override { return m_padStack.LayerSet(); }
440
441 void SetAttribute( PAD_ATTRIB aAttribute );
443
444 void SetProperty( PAD_PROP aProperty );
445 PAD_PROP GetProperty() const { return m_property; }
446
447 // We don't currently have an attribute for APERTURE, and adding one will change the file
448 // format, so for now just infer a copper-less pad to be an APERTURE pad.
449 bool IsAperturePad() const
450 {
451 return ( m_padStack.LayerSet() & LSET::AllCuMask() ).none();
452 }
453
454 void SetPadToDieLength( int aLength ) { m_lengthPadToDie = aLength; }
455 int GetPadToDieLength() const { return m_lengthPadToDie; }
456
457 std::optional<int> GetLocalClearance() const override { return m_padStack.Clearance(); }
458 void SetLocalClearance( std::optional<int> aClearance ) { m_padStack.Clearance() = aClearance; }
459
460 std::optional<int> GetLocalSolderMaskMargin() const { return m_padStack.SolderMaskMargin(); }
461 void SetLocalSolderMaskMargin( std::optional<int> aMargin )
462 {
463 m_padStack.SolderMaskMargin() = aMargin;
464 }
465
466 std::optional<int> GetLocalSolderPasteMargin() const { return m_padStack.SolderPasteMargin(); }
467 void SetLocalSolderPasteMargin( std::optional<int> aMargin )
468 {
469 m_padStack.SolderPasteMargin() = aMargin;
470 }
471
472 std::optional<double> GetLocalSolderPasteMarginRatio() const
473 {
475 }
476 void SetLocalSolderPasteMarginRatio( std::optional<double> aRatio )
477 {
479 }
480
483 {
484 return m_padStack.ZoneConnection().value_or( ZONE_CONNECTION::INHERITED );
485 }
486
494 int GetOwnClearance( PCB_LAYER_ID aLayer, wxString* aSource = nullptr ) const override;
495
505 void TransformShapeToPolygon( SHAPE_POLY_SET& aBuffer, PCB_LAYER_ID aLayer, int aClearance,
506 int aMaxError, ERROR_LOC aErrorLoc = ERROR_INSIDE,
507 bool ignoreLineWidth = false ) const override;
508
518 bool TransformHoleToPolygon( SHAPE_POLY_SET& aBuffer, int aClearance, int aError,
519 ERROR_LOC aErrorLoc = ERROR_INSIDE ) const;
520
535 virtual std::shared_ptr<SHAPE>
537 FLASHING flashPTHPads = FLASHING::DEFAULT ) const override;
538
539 const std::shared_ptr<SHAPE_POLY_SET>& GetEffectivePolygon( PCB_LAYER_ID aLayer,
540 ERROR_LOC aErrorLoc = ERROR_INSIDE ) const;
541
545 std::shared_ptr<SHAPE_SEGMENT> GetEffectiveHoleShape() const override;
546
552 int GetBoundingRadius() const;
553
560 std::optional<int> GetLocalClearance( wxString* aSource ) const override;
561
568 std::optional<int> GetClearanceOverrides( wxString* aSource ) const override;
569
580 int GetSolderMaskExpansion( PCB_LAYER_ID aLayer ) const;
581
594
595 ZONE_CONNECTION GetZoneConnectionOverrides( wxString* aSource = nullptr ) const;
596
601 void SetThermalSpokeWidth( int aWidth ) { m_padStack.ThermalSpokeWidth() = aWidth; }
602 int GetThermalSpokeWidth() const { return m_padStack.ThermalSpokeWidth().value_or( 0 ); }
603
604 int GetLocalSpokeWidthOverride( wxString* aSource = nullptr ) const;
605
611 void SetThermalSpokeAngle( const EDA_ANGLE& aAngle )
612 {
614 }
616 {
618 }
619
620 // For property system
621 void SetThermalSpokeAngleDegrees( double aAngle )
622 {
624 }
626 {
628 }
629
630 void SetThermalGap( int aGap ) { m_padStack.ThermalGap() = aGap; }
631 int GetThermalGap() const { return m_padStack.ThermalGap().value_or( 0 ); }
632
633 int GetLocalThermalGapOverride( wxString* aSource = nullptr ) const;
634
640 void SetRoundRectCornerRadius( PCB_LAYER_ID aLayer, double aRadius );
641 int GetRoundRectCornerRadius( PCB_LAYER_ID aLayer ) const;
642
643 VECTOR2I ShapePos( PCB_LAYER_ID aLayer ) const;
644
651 void SetRoundRectRadiusRatio( PCB_LAYER_ID aLayer, double aRadiusScale );
653 {
654 return m_padStack.RoundRectRadiusRatio( aLayer );
655 }
656
657 // For properties panel, which only supports normal padstacks
658 void SetFrontRoundRectRadiusRatio( double aRadiusScale );
660 {
662 }
663
670 void SetChamferRectRatio( PCB_LAYER_ID aLayer, double aChamferScale );
671 double GetChamferRectRatio( PCB_LAYER_ID aLayer ) const
672 {
673 return m_padStack.ChamferRatio( aLayer );
674 }
675
683 void SetChamferPositions( PCB_LAYER_ID aLayer, int aPositions )
684 {
685 m_padStack.SetChamferPositions( aPositions, aLayer );
686 }
687
689 {
690 return m_padStack.ChamferPositions( aLayer );
691 }
692
696 int GetSubRatsnest() const { return m_subRatsnest; }
697 void SetSubRatsnest( int aSubRatsnest ) { m_subRatsnest = aSubRatsnest; }
698
704 void SetRemoveUnconnected( bool aSet )
705 {
709 }
710
712 {
714 }
715
720 void SetKeepTopBottom( bool aSet )
721 {
725 }
726
727 bool GetKeepTopBottom() const
728 {
731 }
732
734 {
736 }
737
739 {
741 }
742
744 {
746 {
748 return false;
749
751 return true;
752
754 {
755 if( aLayer == m_padStack.Drill().start || aLayer == m_padStack.Drill().end )
756 return false;
757 }
758 }
759
760 return true;
761 }
762
763 void GetMsgPanelInfo( EDA_DRAW_FRAME* aFrame, std::vector<MSG_PANEL_ITEM>& aList ) override;
764
765 bool IsOnLayer( PCB_LAYER_ID aLayer ) const override
766 {
767 return m_padStack.LayerSet().test( aLayer );
768 }
769
778 bool FlashLayer( int aLayer, bool aOnlyCheckIfPermitted = false ) const;
779
780 bool CanFlashLayer( int aLayer )
781 {
782 return FlashLayer( aLayer, true );
783 }
784
785 PCB_LAYER_ID GetLayer() const override;
786
791
799 bool FlashLayer( LSET aLayers ) const;
800
801 bool HitTest( const VECTOR2I& aPosition, int aAccuracy = 0 ) const override;
802 bool HitTest( const BOX2I& aRect, bool aContained, int aAccuracy = 0 ) const override;
803
804
812 std::vector<PCB_SHAPE*> Recombine( bool aIsDryRun, int aMaxError );
813
814 wxString GetClass() const override
815 {
816 return wxT( "PAD" );
817 }
818
822 const BOX2I GetBoundingBox() const override;
823
830 static int Compare( const PAD* aPadRef, const PAD* aPadCmp );
831
832 void Move( const VECTOR2I& aMoveVector ) override
833 {
834 m_pos += aMoveVector;
835 SetDirty();
836 }
837
838 void Rotate( const VECTOR2I& aRotCentre, const EDA_ANGLE& aAngle ) override;
839
840 wxString GetItemDescription( UNITS_PROVIDER* aUnitsProvider, bool aFull ) const override;
841
842 BITMAPS GetMenuImage() const override;
843
847 wxString ShowPadShape( PCB_LAYER_ID aLayer ) const;
848
852 wxString ShowPadAttr() const;
853
854 EDA_ITEM* Clone() const override;
855
861 PAD* ClonePad() const
862 {
863 return (PAD*) Clone();
864 }
865
870 void BuildEffectiveShapes() const;
871 void BuildEffectivePolygon( ERROR_LOC aErrorLoc = ERROR_INSIDE ) const;
872
873 virtual std::vector<int> ViewGetLayers() const override;
874
875 double ViewGetLOD( int aLayer, KIGFX::VIEW* aView ) const override;
876
877 virtual const BOX2I ViewBBox() const override;
878
880
882
883 void SetZoneLayerOverride( PCB_LAYER_ID aLayer, ZONE_LAYER_OVERRIDE aOverride );
884
885 void CheckPad( UNITS_PROVIDER* aUnitsProvider,
886 const std::function<void( int aErrorCode,
887 const wxString& aMsg )>& aErrorHandler ) const;
888
889 double Similarity( const BOARD_ITEM& aOther ) const override;
890
891 bool operator==( const PAD& aOther ) const;
892 bool operator==( const BOARD_ITEM& aBoardItem ) const override;
893
894#if defined(DEBUG)
895 virtual void Show( int nestLevel, std::ostream& os ) const override { ShowDummy( os ); }
896#endif
897
898protected:
899 virtual void swapData( BOARD_ITEM* aImage ) override;
900
901private:
902 const SHAPE_COMPOUND& buildEffectiveShape( PCB_LAYER_ID aLayer ) const;
903
904 void addPadPrimitivesToPolygon( PCB_LAYER_ID aLayer, SHAPE_POLY_SET* aMergedPolygon, int aError,
905 ERROR_LOC aErrorLoc ) const;
906
907 void doCheckPad( PCB_LAYER_ID aLayer, UNITS_PROVIDER* aUnitsProvider,
908 const std::function<void( int aErrorCode,
909 const wxString& aMsg )>& aErrorHandler ) const;
910
911private:
912 wxString m_number; // Pad name (pin number in schematic)
913 wxString m_pinFunction; // Pin name in schematic
914 wxString m_pinType; // Pin electrical type in schematic
915
916 VECTOR2I m_pos; // Pad Position on board
917
919
920 // Must be set to true to force rebuild shapes to draw (after geometry change for instance)
921 typedef std::map<PCB_LAYER_ID, std::shared_ptr<SHAPE_COMPOUND>> LAYER_SHAPE_MAP;
922 mutable bool m_shapesDirty;
923 mutable std::mutex m_shapesBuildingLock;
926 mutable std::shared_ptr<SHAPE_SEGMENT> m_effectiveHoleShape;
927
928 typedef std::map<PCB_LAYER_ID, std::array<std::shared_ptr<SHAPE_POLY_SET>, 2>> LAYER_POLYGON_MAP;
929 mutable bool m_polyDirty[2];
930 mutable std::mutex m_polyBuildingLock;
933
934 int m_subRatsnest; // Variable used to handle subnet (block) number in
935 // ratsnest computations
936
937 PAD_ATTRIB m_attribute = PAD_ATTRIB::PTH;
938
939 PAD_PROP m_property; // Property in fab files (BGA, FIDUCIAL, TESTPOINT, etc.)
940
941 int m_lengthPadToDie; // Length net from pad to die, inside the package
942
944 std::map<PCB_LAYER_ID, ZONE_LAYER_OVERRIDE> m_zoneLayerOverrides;
945};
ERROR_LOC
When approximating an arc or circle, should the error be placed on the outside or inside of the curve...
Definition: approximation.h:32
@ ERROR_OUTSIDE
Definition: approximation.h:33
@ ERROR_INSIDE
Definition: approximation.h:34
BITMAPS
A list of all bitmap identifiers.
Definition: bitmaps_list.h:33
ZONE_LAYER_OVERRIDE
Conditionally flashed vias and pads that interact with zones of different priority can be very squirr...
Definition: board_item.h:66
A base class derived from BOARD_ITEM for items that can be connected and have a net,...
A base class for any item which can be embedded within the BOARD container class, and therefore insta...
Definition: board_item.h:79
FOOTPRINT * GetParentFootprint() const
Definition: board_item.cpp:298
Implement a canvas based on a wxGLCanvas.
Definition: eda_3d_canvas.h:49
double AsDegrees() const
Definition: eda_angle.h:113
The base class for create windows for drawing purpose.
A base class for most all the KiCad significant classes used in schematics and boards.
Definition: eda_item.h:89
KICAD_T Type() const
Returns the type of object.
Definition: eda_item.h:101
virtual bool IsType(const std::vector< KICAD_T > &aScanTypes) const
Check whether the item is one of the listed types.
Definition: eda_item.h:176
Hold a (potentially large) number of VIEW_ITEMs and renders them on a graphics device provided by the...
Definition: view.h:68
An abstract class from which implementation specific LINE_READERs may be derived to read single lines...
Definition: richio.h:93
LSET is a set of PCB_LAYER_IDs.
Definition: lset.h:36
static LSET AllCuMask(int aCuLayerCount=MAX_CU_LAYERS)
Return a mask holding the requested number of Cu PCB_LAYER_IDs.
Definition: lset.cpp:676
A PADSTACK defines the characteristics of a single or multi-layer pad, in the IPC sense of the word.
Definition: padstack.h:124
CUSTOM_SHAPE_ZONE_MODE CustomShapeInZoneMode() const
Definition: padstack.h:326
void SetCustomShapeInZoneMode(CUSTOM_SHAPE_ZONE_MODE aM)
Definition: padstack.h:327
std::optional< int > & Clearance(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1162
std::optional< double > & SolderPasteMarginRatio(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1201
void SetThermalSpokeAngle(EDA_ANGLE aAngle, PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1270
void SetUnconnectedLayerMode(UNCONNECTED_LAYER_MODE aMode)
Definition: padstack.h:307
std::optional< int > & ThermalSpokeWidth(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1227
std::optional< int > & SolderPasteMargin(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1188
std::optional< int > & SolderMaskMargin(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1174
const LSET & LayerSet() const
Definition: padstack.h:274
void SetShape(PAD_SHAPE aShape, PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1034
VECTOR2I & TrapezoidDeltaSize(PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1091
VECTOR2I & Offset(PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1067
EDA_ANGLE ThermalSpokeAngle(PCB_LAYER_ID aLayer=F_Cu) const
Definition: padstack.cpp:1262
void SetChamferPositions(int aPositions, PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1156
UNCONNECTED_LAYER_MODE UnconnectedLayerMode() const
Definition: padstack.h:306
std::optional< int > & ThermalGap(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1239
PAD_SHAPE Shape(PCB_LAYER_ID aLayer) const
Definition: padstack.cpp:1028
DRILL_PROPS & Drill()
Definition: padstack.h:300
void SetAnchorShape(PAD_SHAPE aShape, PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1085
CUSTOM_SHAPE_ZONE_MODE
Definition: padstack.h:158
int & ChamferPositions(PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1144
const VECTOR2I & Size(PCB_LAYER_ID aLayer) const
Definition: padstack.cpp:1049
double RoundRectRadiusRatio(PCB_LAYER_ID aLayer) const
Definition: padstack.cpp:1103
UNCONNECTED_LAYER_MODE
! Whether or not to remove the copper shape for unconnected layers
Definition: padstack.h:151
PAD_SHAPE AnchorShape(PCB_LAYER_ID aLayer) const
Definition: padstack.cpp:1079
void SetSize(const VECTOR2I &aSize, PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1040
double ChamferRatio(PCB_LAYER_ID aLayer) const
Definition: padstack.cpp:1132
static constexpr PCB_LAYER_ID ALL_LAYERS
! Temporary layer identifier to identify code that is not padstack-aware
Definition: padstack.h:144
EDA_ANGLE GetOrientation() const
Definition: padstack.h:293
void SetLayerSet(const LSET &aSet)
Definition: padstack.h:276
std::optional< ZONE_CONNECTION > & ZoneConnection(PCB_LAYER_ID aLayer=F_Cu)
Definition: padstack.cpp:1215
std::vector< std::shared_ptr< PCB_SHAPE > > & Primitives(PCB_LAYER_ID aLayer)
Definition: padstack.cpp:1276
Definition: pad.h:54
void SetAnchorPadShape(PCB_LAYER_ID aLayer, PAD_SHAPE aShape)
Set the shape of the anchor pad for custom shaped pads.
Definition: pad.h:244
bool IsAperturePad() const
Definition: pad.h:449
void SetAttribute(PAD_ATTRIB aAttribute)
Definition: pad.cpp:811
int GetOwnClearance(PCB_LAYER_ID aLayer, wxString *aSource=nullptr) const override
Return the pad's "own" clearance in internal units.
Definition: pad.cpp:1056
virtual void swapData(BOARD_ITEM *aImage) override
Definition: pad.cpp:1851
PAD_PROP GetProperty() const
Definition: pad.h:445
bool GetRemoveUnconnected() const
Definition: pad.h:711
void Serialize(google::protobuf::Any &aContainer) const override
Serializes this object to the given Any message.
Definition: pad.cpp:138
double GetFrontRoundRectRadiusRatio() const
Definition: pad.h:659
std::optional< int > GetClearanceOverrides(wxString *aSource) const override
Return any clearance overrides set in the "classic" (ie: pre-rule) system.
Definition: pad.cpp:1044
void SetPinType(const wxString &aType)
Set the pad electrical type.
Definition: pad.h:150
LSET GetLayerSet() const override
Return a std::bitset of all layers on which the item physically resides.
Definition: pad.h:439
const std::vector< std::shared_ptr< PCB_SHAPE > > & GetPrimitives(PCB_LAYER_ID aLayer) const
Accessor to the basic shape list for custom-shaped pads.
Definition: pad.h:367
const ZONE_LAYER_OVERRIDE & GetZoneLayerOverride(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:201
int GetSizeX() const
Definition: pad.h:282
void MergePrimitivesAsPolygon(PCB_LAYER_ID aLayer, SHAPE_POLY_SET *aMergedPolygon, ERROR_LOC aErrorLoc=ERROR_INSIDE) const
Merge all basic shapes to a SHAPE_POLY_SET.
int GetRoundRectCornerRadius(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:441
bool FlashLayer(int aLayer, bool aOnlyCheckIfPermitted=false) const
Check to see whether the pad should be flashed on the specific layer.
Definition: pad.cpp:340
bool IsDirty() const
Definition: pad.h:426
virtual std::shared_ptr< SHAPE > GetEffectiveShape(PCB_LAYER_ID aLayer, FLASHING flashPTHPads=FLASHING::DEFAULT) const override
Some pad shapes can be complex (rounded/chamfered rectangle), even without considering custom shapes.
Definition: pad.cpp:488
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.
Definition: pad.cpp:1229
const BOX2I GetBoundingBox() const override
The bounding box is cached, so this will be efficient most of the time.
Definition: pad.cpp:802
bool IsOnLayer(PCB_LAYER_ID aLayer) const override
Test to see if this object is on the given layer.
Definition: pad.h:765
int GetDrillSizeY() const
Definition: pad.h:311
std::map< PCB_LAYER_ID, std::shared_ptr< SHAPE_COMPOUND > > LAYER_SHAPE_MAP
Definition: pad.h:921
void AddPrimitivePoly(PCB_LAYER_ID aLayer, const SHAPE_POLY_SET &aPoly, int aThickness, bool aFilled)
Has meaning only for custom shape pads.
std::optional< double > GetLocalSolderPasteMarginRatio() const
Definition: pad.h:472
void SetFrontShape(PAD_SHAPE aShape)
Definition: pad.h:196
const wxString & GetPinType() const
Definition: pad.h:151
void SetZoneLayerOverride(PCB_LAYER_ID aLayer, ZONE_LAYER_OVERRIDE aOverride)
Definition: pad.cpp:209
const VECTOR2I & GetDrillSize() const
Definition: pad.h:307
PAD_ATTRIB GetAttribute() const
Definition: pad.h:442
static LSET PTHMask()
layer set for a through hole pad
Definition: pad.cpp:269
static int Compare(const PAD *aPadRef, const PAD *aPadCmp)
Compare two pads and return 0 if they are equal.
Definition: pad.cpp:1444
void SetUnconnectedLayerMode(PADSTACK::UNCONNECTED_LAYER_MODE aMode)
Definition: pad.h:733
void SetRemoveUnconnected(bool aSet)
Definition: pad.h:704
const wxString & GetPinFunction() const
Definition: pad.h:145
std::mutex m_shapesBuildingLock
Definition: pad.h:923
void SetThermalGap(int aGap)
Definition: pad.h:630
bool CanHaveNumber() const
Indicates whether or not the pad can have a number.
Definition: pad.cpp:216
void SetThermalSpokeAngle(const EDA_ANGLE &aAngle)
The orientation of the thermal spokes.
Definition: pad.h:611
wxString m_pinType
Definition: pad.h:914
bool Deserialize(const google::protobuf::Any &aContainer) override
Deserializes the given protobuf message into this object.
Definition: pad.cpp:163
const wxString & GetNumber() const
Definition: pad.h:134
const VECTOR2I & GetDelta(PCB_LAYER_ID aLayer) const
Definition: pad.h:301
void SetFrontRoundRectRadiusRatio(double aRadiusScale)
Definition: pad.cpp:461
void BuildEffectiveShapes() const
Rebuild the effective shape cache (and bounding box and radius) for the pad and clears the dirty bit.
Definition: pad.cpp:563
PAD_SHAPE GetFrontShape() const
Definition: pad.h:202
static bool ClassOf(const EDA_ITEM *aItem)
Definition: pad.h:78
void SetLocalSolderPasteMarginRatio(std::optional< double > aRatio)
Definition: pad.h:476
PAD & operator=(const PAD &aOther)
Definition: pad.cpp:121
void SetShape(PCB_LAYER_ID aLayer, PAD_SHAPE aShape)
Set the new shape of this pad.
Definition: pad.h:184
std::shared_ptr< SHAPE_SEGMENT > m_effectiveHoleShape
Definition: pad.h:926
bool IsLocked() const override
Definition: pad.cpp:230
VECTOR2I GetCenter() const override
This defaults to the center of the bounding box if not overridden.
Definition: pad.h:321
VECTOR2I GetPosition() const override
Definition: pad.h:210
void SetProperty(PAD_PROP aProperty)
Definition: pad.cpp:859
void SetThermalSpokeAngleDegrees(double aAngle)
Definition: pad.h:621
EDA_ANGLE GetThermalSpokeAngle() const
Definition: pad.h:615
std::map< PCB_LAYER_ID, ZONE_LAYER_OVERRIDE > m_zoneLayerOverrides
Definition: pad.h:944
bool ConditionallyFlashed(PCB_LAYER_ID aLayer) const
Definition: pad.h:743
PAD_ATTRIB m_attribute
Definition: pad.h:937
void Flip(const VECTOR2I &VECTOR2I, FLIP_DIRECTION aFlipDirection) override
Flip this object, i.e.
Definition: pad.cpp:892
void Move(const VECTOR2I &aMoveVector) override
Move this object.
Definition: pad.h:832
std::vector< PCB_SHAPE * > Recombine(bool aIsDryRun, int aMaxError)
Recombines the pad with other graphical shapes in the footprint.
Definition: pad.cpp:1983
PCB_LAYER_ID GetPrincipalLayer() const
Definition: pad.cpp:318
void SetDirty()
Definition: pad.h:431
static LSET UnplatedHoleMask()
layer set for a mechanical unplated through hole pad
Definition: pad.cpp:290
void SetDelta(PCB_LAYER_ID aLayer, const VECTOR2I &aSize)
Definition: pad.h:295
EDA_ITEM * Clone() const override
Create a duplicate of this item with linked list members set to NULL.
Definition: pad.cpp:1594
std::map< PCB_LAYER_ID, std::array< std::shared_ptr< SHAPE_POLY_SET >, 2 > > LAYER_POLYGON_MAP
Definition: pad.h:928
double GetOrientationDegrees() const
Definition: pad.h:418
bool SameLogicalPadAs(const PAD *aOther) const
Before we had custom pad shapes it was common to have multiple overlapping pads to represent a more c...
Definition: pad.h:157
void Rotate(const VECTOR2I &aRotCentre, const EDA_ANGLE &aAngle) override
Rotate this object.
Definition: pad.cpp:1459
PADSTACK m_padStack
Definition: pad.h:918
void FlipPrimitives(FLIP_DIRECTION aFlipDirection)
Flip (mirror) the primitives left to right or top to bottom, around the anchor position in custom pad...
Definition: pad.cpp:955
LAYER_SHAPE_MAP m_effectiveShapes
Definition: pad.h:925
bool IsNoConnectPad() const
Definition: pad.cpp:256
int GetDrillSizeX() const
Definition: pad.h:309
PAD_PROP m_property
Definition: pad.h:939
double GetRoundRectRadiusRatio(PCB_LAYER_ID aLayer) const
Definition: pad.h:652
void SetKeepTopBottom(bool aSet)
Definition: pad.h:720
void DeletePrimitivesList(PCB_LAYER_ID aLayer=UNDEFINED_LAYER)
Clear the basic shapes list.
PAD_SHAPE GetShape(PCB_LAYER_ID aLayer) const
Definition: pad.h:193
void TransformShapeToPolygon(SHAPE_POLY_SET &aBuffer, PCB_LAYER_ID aLayer, int aClearance, int aMaxError, ERROR_LOC aErrorLoc=ERROR_INSIDE, bool ignoreLineWidth=false) const override
Convert the pad shape to a closed polygon.
Definition: pad.cpp:1876
PADSTACK & Padstack()
Definition: pad.h:324
void SetNumber(const wxString &aNumber)
Set the pad number (note that it can be alphanumeric, such as the array reference "AA12").
Definition: pad.h:133
int GetLocalThermalGapOverride(wxString *aSource=nullptr) const
Definition: pad.cpp:1220
wxString ShowPadAttr() const
Definition: pad.cpp:1484
wxString m_pinFunction
Definition: pad.h:913
void AddPrimitive(PCB_LAYER_ID aLayer, PCB_SHAPE *aPrimitive)
Add item to the custom shape primitives list.
void SetDrillShape(PAD_DRILL_SHAPE aShape)
Definition: pad.cpp:430
int m_effectiveBoundingRadius
Definition: pad.h:932
void SetLocalSolderMaskMargin(std::optional< int > aMargin)
Definition: pad.h:461
void SetOffset(PCB_LAYER_ID aLayer, const VECTOR2I &aOffset)
Definition: pad.h:313
bool GetKeepTopBottom() const
Definition: pad.h:727
void SetLocalZoneConnection(ZONE_CONNECTION aType)
Definition: pad.h:481
void SetChamferRectRatio(PCB_LAYER_ID aLayer, double aChamferScale)
Has meaning only for chamfered rectangular pads.
Definition: pad.cpp:468
int GetSolderMaskExpansion(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:1082
std::optional< int > GetLocalClearance() const override
Return any local clearances set in the "classic" (ie: pre-rule) system.
Definition: pad.h:457
void ImportSettingsFrom(const PAD &aMasterPad)
Import the pad settings from aMasterPad.
Definition: pad.cpp:1780
double Similarity(const BOARD_ITEM &aOther) const override
Return a measure of how likely the other object is to represent the same object.
Definition: pad.cpp:2419
bool IsOnCopperLayer() const override
Definition: pad.cpp:988
void SetDrillSizeX(const int aX)
Definition: pad.cpp:419
void SetPadstack(const PADSTACK &aPadstack)
Definition: pad.h:325
void SetPosition(const VECTOR2I &aPos) override
Definition: pad.h:204
const SHAPE_COMPOUND & buildEffectiveShape(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:599
const PADSTACK & Padstack() const
Definition: pad.h:323
const VECTOR2I & GetOffset(PCB_LAYER_ID aLayer) const
Definition: pad.h:319
VECTOR2I m_pos
Definition: pad.h:916
void BuildEffectivePolygon(ERROR_LOC aErrorLoc=ERROR_INSIDE) const
Definition: pad.cpp:755
static LSET ConnSMDMask()
layer set for a SMD pad on Front layer used for edge board connectors
Definition: pad.cpp:283
void SetDrillSize(const VECTOR2I &aSize)
Definition: pad.h:306
bool IsFreePad() const
Definition: pad.cpp:262
wxString GetClass() const override
Return the class name.
Definition: pad.h:814
bool CanFlashLayer(int aLayer)
Definition: pad.h:780
int m_subRatsnest
Definition: pad.h:934
EDA_ANGLE GetOrientation() const
Return the rotation angle of the pad.
Definition: pad.h:410
void SetSize(PCB_LAYER_ID aLayer, const VECTOR2I &aSize)
Definition: pad.h:261
PADSTACK::CUSTOM_SHAPE_ZONE_MODE GetCustomShapeInZoneOpt() const
Definition: pad.h:223
PAD_DRILL_SHAPE GetDrillShape() const
Definition: pad.h:424
void ReplacePrimitives(PCB_LAYER_ID aLayer, const std::vector< std::shared_ptr< PCB_SHAPE > > &aPrimitivesList)
Clear the current custom shape primitives list and import a new list.
int GetChamferPositions(PCB_LAYER_ID aLayer) const
Definition: pad.h:688
void SetY(int y)
Definition: pad.h:258
static LSET ApertureMask()
layer set for an aperture pad
Definition: pad.cpp:297
virtual const BOX2I ViewBBox() const override
Return the bounding box of the item covering all its layers.
Definition: pad.cpp:1745
bool m_shapesDirty
Definition: pad.h:922
std::mutex m_polyBuildingLock
Definition: pad.h:930
void SetRoundRectCornerRadius(PCB_LAYER_ID aLayer, double aRadius)
Has meaning only for rounded rectangle pads.
Definition: pad.cpp:447
static LSET SMDMask()
layer set for a SMD pad on Front layer
Definition: pad.cpp:276
std::optional< int > GetLocalSolderPasteMargin() const
Definition: pad.h:466
void CheckPad(UNITS_PROVIDER *aUnitsProvider, const std::function< void(int aErrorCode, const wxString &aMsg)> &aErrorHandler) const
Definition: pad.cpp:2121
const std::shared_ptr< SHAPE_POLY_SET > & GetEffectivePolygon(PCB_LAYER_ID aLayer, ERROR_LOC aErrorLoc=ERROR_INSIDE) const
Definition: pad.cpp:476
void SetX(int x)
Definition: pad.h:259
void SetChamferPositions(PCB_LAYER_ID aLayer, int aPositions)
Has meaning only for chamfered rectangular pads.
Definition: pad.h:683
std::optional< int > GetLocalSolderMaskMargin() const
Definition: pad.h:460
void SetLocalSolderPasteMargin(std::optional< int > aMargin)
Definition: pad.h:467
int GetSizeY() const
Definition: pad.h:293
PCB_LAYER_ID GetLayer() const override
Return the primary layer this item is on.
Definition: pad.cpp:312
void addPadPrimitivesToPolygon(PCB_LAYER_ID aLayer, SHAPE_POLY_SET *aMergedPolygon, int aError, ERROR_LOC aErrorLoc) const
void doCheckPad(PCB_LAYER_ID aLayer, UNITS_PROVIDER *aUnitsProvider, const std::function< void(int aErrorCode, const wxString &aMsg)> &aErrorHandler) const
Definition: pad.cpp:2236
int GetThermalSpokeWidth() const
Definition: pad.h:602
wxString GetItemDescription(UNITS_PROVIDER *aUnitsProvider, bool aFull) const override
Return a user-visible description string of this item.
Definition: pad.cpp:1497
void SetPinFunction(const wxString &aName)
Set the pad function (pin name in schematic)
Definition: pad.h:144
EDA_ANGLE GetFPRelativeOrientation() const
Definition: pad.cpp:883
double GetChamferRectRatio(PCB_LAYER_ID aLayer) const
Definition: pad.h:671
bool m_polyDirty[2]
Definition: pad.h:929
bool HitTest(const VECTOR2I &aPosition, int aAccuracy=0) const override
Test if aPosition is inside or on the boundary of this item.
Definition: pad.cpp:1362
void SetFPRelativeOrientation(const EDA_ANGLE &aAngle)
Definition: pad.cpp:874
void SetCustomShapeInZoneOpt(PADSTACK::CUSTOM_SHAPE_ZONE_MODE aOption)
Set the option for the custom pad shape to use as clearance area in copper zones.
Definition: pad.h:233
int GetBoundingRadius() const
Return the radius of a minimum sized circle which fully encloses this pad.
Definition: pad.cpp:554
void ClearZoneLayerOverrides()
Definition: pad.cpp:192
void SetOrientation(const EDA_ANGLE &aAngle)
Set the rotation angle of the pad.
Definition: pad.cpp:867
std::mutex m_zoneLayerOverridesMutex
Definition: pad.h:943
PADSTACK::UNCONNECTED_LAYER_MODE GetUnconnectedLayerMode() const
Definition: pad.h:738
VECTOR2I GetSolderPasteMargin(PCB_LAYER_ID aLayer) const
Usually < 0 (mask shape smaller than pad)because the margin can be dependent on the pad size,...
Definition: pad.cpp:1128
BITMAPS GetMenuImage() const override
Return a pointer to an image to be used in menus.
Definition: pad.cpp:1588
void AppendPrimitives(PCB_LAYER_ID aLayer, const std::vector< std::shared_ptr< PCB_SHAPE > > &aPrimitivesList)
Import a custom shape primitive list (composed of basic shapes) and add items to the current list.
wxString m_number
Definition: pad.h:912
bool HasDrilledHole() const override
Definition: pad.h:109
LAYER_POLYGON_MAP m_effectivePolygons
Definition: pad.h:931
void SetLocalClearance(std::optional< int > aClearance)
Definition: pad.h:458
int GetSubRatsnest() const
Definition: pad.h:696
void SetSizeX(const int aX)
Definition: pad.h:273
ZONE_CONNECTION GetLocalZoneConnection() const
Definition: pad.h:482
int m_lengthPadToDie
Definition: pad.h:941
void SetThermalSpokeWidth(int aWidth)
Set the width of the thermal spokes connecting the pad to a zone.
Definition: pad.h:601
bool HasHole() const override
Definition: pad.h:104
void SetDrillSizeY(const int aY)
Definition: pad.h:310
double GetThermalSpokeAngleDegrees() const
Definition: pad.h:625
PAD * ClonePad() const
Same as Clone, but returns a PAD item.
Definition: pad.h:861
int GetThermalGap() const
Definition: pad.h:631
VECTOR2I ShapePos(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:973
std::shared_ptr< SHAPE_SEGMENT > GetEffectiveHoleShape() const override
Return a SHAPE_SEGMENT object representing the pad's hole.
Definition: pad.cpp:545
void SetOrientationDegrees(double aOrientation)
Definition: pad.h:414
ZONE_CONNECTION GetZoneConnectionOverrides(wxString *aSource=nullptr) const
Definition: pad.cpp:1191
void SetLayerSet(const LSET &aLayers) override
Definition: pad.h:438
bool SharesNetTieGroup(const PAD *aOther) const
Definition: pad.cpp:239
PAD_SHAPE GetAnchorPadShape(PCB_LAYER_ID aLayer) const
Definition: pad.h:215
void SetRoundRectRadiusRatio(PCB_LAYER_ID aLayer, double aRadiusScale)
Has meaning only for rounded rectangle pads.
Definition: pad.cpp:453
double ViewGetLOD(int aLayer, KIGFX::VIEW *aView) const override
Return the level of detail (LOD) of the item.
Definition: pad.cpp:1679
void SetSubRatsnest(int aSubRatsnest)
Definition: pad.h:697
int GetLocalSpokeWidthOverride(wxString *aSource=nullptr) const
Definition: pad.cpp:1211
bool TransformHoleToPolygon(SHAPE_POLY_SET &aBuffer, int aClearance, int aError, ERROR_LOC aErrorLoc=ERROR_INSIDE) const
Build the corner list of the polygonal drill shape in the board coordinate system.
Definition: pad.cpp:1859
void SetPadToDieLength(int aLength)
Definition: pad.h:454
bool IsFlipped() const
Definition: pad.cpp:304
bool operator==(const PAD &aOther) const
Definition: pad.cpp:2404
bool IsType(const std::vector< KICAD_T > &aScanTypes) const override
Check whether the item is one of the listed types.
Definition: pad.h:83
wxString ShowPadShape(PCB_LAYER_ID aLayer) const
Definition: pad.cpp:1468
void SetSizeY(const int aY)
Definition: pad.h:284
int GetPadToDieLength() const
Definition: pad.h:455
BOX2I m_effectiveBoundingBox
Definition: pad.h:924
const VECTOR2I & GetSize(PCB_LAYER_ID aLayer) const
Definition: pad.h:266
virtual std::vector< int > ViewGetLayers() const override
Return the all the layers within the VIEW the object is painted on.
Definition: pad.cpp:1612
Represent a set of closed polygons.
An abstract shape on 2D plane.
Definition: shape.h:126
@ DEGREES_T
Definition: eda_angle.h:31
FLASHING
Enum used during connectivity building to ensure we do not query connectivity while building the data...
Definition: layer_ids.h:147
PCB_LAYER_ID
A quick note on layer IDs:
Definition: layer_ids.h:60
@ UNDEFINED_LAYER
Definition: layer_ids.h:61
@ F_Cu
Definition: layer_ids.h:64
FLIP_DIRECTION
Definition: mirror.h:27
The Cairo implementation of the graphics abstraction layer.
Definition: color4d.cpp:247
PAD_DRILL_SHAPE
The set of pad drill shapes, used with PAD::{Set,Get}DrillShape()
Definition: padstack.h:69
PAD_ATTRIB
The set of pad shapes, used with PAD::{Set,Get}Attribute().
Definition: padstack.h:81
PAD_SHAPE
The set of pad shapes, used with PAD::{Set,Get}Shape()
Definition: padstack.h:52
PAD_PROP
The set of pad properties used in Gerber files (Draw files, and P&P files) to define some properties ...
Definition: padstack.h:98
PCB_LAYER_ID start
Definition: padstack.h:242
PCB_LAYER_ID end
Definition: padstack.h:243
VECTOR2I size
Drill diameter (x == y) or slot dimensions (x != y)
Definition: padstack.h:240
PAD_DRILL_SHAPE shape
Definition: padstack.h:241
KICAD_T
The set of class identification values stored in EDA_ITEM::m_structType.
Definition: typeinfo.h:78
@ PCB_LOCATE_NPTH_T
Definition: typeinfo.h:129
@ PCB_LOCATE_PTH_T
Definition: typeinfo.h:128
@ PCB_PAD_T
class PAD, a pad in a footprint
Definition: typeinfo.h:87
@ PCB_LOCATE_HOLE_T
Definition: typeinfo.h:127
ZONE_CONNECTION
How pads are covered by copper in zone.
Definition: zones.h:47