KiCad PCB EDA Suite
pad_shapes.h File Reference
#include <string>

Go to the source code of this file.

Enumerations

enum  PAD_SHAPE_T {
  PAD_SHAPE_CIRCLE, PAD_SHAPE_RECT, PAD_SHAPE_OVAL, PAD_SHAPE_TRAPEZOID,
  PAD_SHAPE_ROUNDRECT, PAD_SHAPE_CHAMFERED_RECT, PAD_SHAPE_CUSTOM
}
 Enum PAD_SHAPE_T is the set of pad shapes, used with PAD::{Set,Get}Shape() More...
 
enum  PAD_DRILL_SHAPE_T { PAD_DRILL_SHAPE_CIRCLE, PAD_DRILL_SHAPE_OBLONG }
 Enum PAD_DRILL_SHAPE_T is the set of pad drill shapes, used with PAD::{Set,Get}DrillShape() More...
 
enum  PAD_ATTR_T { PAD_ATTRIB_PTH, PAD_ATTRIB_SMD, PAD_ATTRIB_CONN, PAD_ATTRIB_NPTH }
 Enum PAD_ATTR_T is the set of pad shapes, used with PAD::{Set,Get}Attribute() The double name is for convenience of Python devs. More...
 
enum  PAD_PROP_T {
  PAD_PROP_NONE, PAD_PROP_BGA, PAD_PROP_FIDUCIAL_GLBL, PAD_PROP_FIDUCIAL_LOCAL,
  PAD_PROP_TESTPOINT, PAD_PROP_HEATSINK, PAD_PROP_CASTELLATED
}
 Enum PAD_PROP_T is the set of pad properties used in Gerber files (Draw files, and P&P files) to define some properties in fabrication or test files. More...
 

Functions

static std::string PAD_SHAPE_T_asString (PAD_SHAPE_T a)
 

Enumeration Type Documentation

◆ PAD_ATTR_T

enum PAD_ATTR_T

Enum PAD_ATTR_T is the set of pad shapes, used with PAD::{Set,Get}Attribute() The double name is for convenience of Python devs.

Enumerator
PAD_ATTRIB_PTH 

Plated through hole pad.

PAD_ATTRIB_SMD 

Smd pad, appears on the solder paste layer (default)

PAD_ATTRIB_CONN 

Like smd, does not appear on the solder paste layer (default) note also has a special attribute in Gerber X files Used for edgecard connectors for instance.

PAD_ATTRIB_NPTH 

like PAD_PTH, but not plated mechanical use only, no connection allowed

Definition at line 78 of file pad_shapes.h.

79 {
86 };
Smd pad, appears on the solder paste layer (default)
Definition: pad_shapes.h:81
like PAD_PTH, but not plated mechanical use only, no connection allowed
Definition: pad_shapes.h:85
Like smd, does not appear on the solder paste layer (default) note also has a special attribute in Ge...
Definition: pad_shapes.h:82
Plated through hole pad.
Definition: pad_shapes.h:80

◆ PAD_DRILL_SHAPE_T

Enum PAD_DRILL_SHAPE_T is the set of pad drill shapes, used with PAD::{Set,Get}DrillShape()

Enumerator
PAD_DRILL_SHAPE_CIRCLE 
PAD_DRILL_SHAPE_OBLONG 

Definition at line 66 of file pad_shapes.h.

◆ PAD_PROP_T

enum PAD_PROP_T

Enum PAD_PROP_T is the set of pad properties used in Gerber files (Draw files, and P&P files) to define some properties in fabrication or test files.

Enumerator
PAD_PROP_NONE 

no special fabrication property

PAD_PROP_BGA 

Smd pad, used in BGA footprints.

PAD_PROP_FIDUCIAL_GLBL 

a fiducial (usually a smd) for the full board

PAD_PROP_FIDUCIAL_LOCAL 

a fiducial (usually a smd) local to the parent footprint

PAD_PROP_TESTPOINT 

a test point pad

PAD_PROP_HEATSINK 

a pad used as heat sink, usually in SMD footprints

PAD_PROP_CASTELLATED 

a pad with a castellated through hole

Definition at line 95 of file pad_shapes.h.

96 {
98  PAD_PROP_BGA,
104 };
no special fabrication property
Definition: pad_shapes.h:97
a fiducial (usually a smd) for the full board
Definition: pad_shapes.h:99
Smd pad, used in BGA footprints.
Definition: pad_shapes.h:98
a pad used as heat sink, usually in SMD footprints
Definition: pad_shapes.h:102
a pad with a castellated through hole
Definition: pad_shapes.h:103
a fiducial (usually a smd) local to the parent footprint
Definition: pad_shapes.h:100
a test point pad
Definition: pad_shapes.h:101

◆ PAD_SHAPE_T

Enum PAD_SHAPE_T is the set of pad shapes, used with PAD::{Set,Get}Shape()

Enumerator
PAD_SHAPE_CIRCLE 
PAD_SHAPE_RECT 
PAD_SHAPE_OVAL 
PAD_SHAPE_TRAPEZOID 
PAD_SHAPE_ROUNDRECT 
PAD_SHAPE_CHAMFERED_RECT 
PAD_SHAPE_CUSTOM 

Definition at line 33 of file pad_shapes.h.

34 {
40  PAD_SHAPE_CHAMFERED_RECT, // Rectangle with a champered corner ( and with rounded other corners)
41  PAD_SHAPE_CUSTOM // A shape defined by user, using a set of basic shapes
42  // (thick segments, circles, arcs, polygons
43 };

Function Documentation

◆ PAD_SHAPE_T_asString()

static std::string PAD_SHAPE_T_asString ( PAD_SHAPE_T  a)
inlinestatic

Definition at line 45 of file pad_shapes.h.

46 {
47  switch( a )
48  {
49  case PAD_SHAPE_CIRCLE: return "PAD_SHAPE_CIRCLE";
50  case PAD_SHAPE_RECT: return "PAD_SHAPE_RECT";
51  case PAD_SHAPE_OVAL: return "PAD_SHAPE_OVAL";
52  case PAD_SHAPE_TRAPEZOID: return "PAD_SHAPE_TRAPEZOID";
53  case PAD_SHAPE_ROUNDRECT: return "PAD_SHAPE_ROUNDRECT";
54  case PAD_SHAPE_CHAMFERED_RECT: return "PAD_SHAPE_CHAMFERED_RECT";
55  case PAD_SHAPE_CUSTOM: return "PAD_SHAPE_CUSTOM";
56  }
57 
58  return ""; // Just to quiet GCC.
59 };

References PAD_SHAPE_CHAMFERED_RECT, PAD_SHAPE_CIRCLE, PAD_SHAPE_CUSTOM, PAD_SHAPE_OVAL, PAD_SHAPE_RECT, PAD_SHAPE_ROUNDRECT, and PAD_SHAPE_TRAPEZOID.

Referenced by PAD::BuildEffectiveShapes(), and PAD::TransformShapeWithClearanceToPolygon().