KiCad Pcbnew Python Scripting
Loading...
Searching...
No Matches
pcbnew.SHAPE Class Reference
Inheritance diagram for pcbnew.SHAPE:

Public Member Functions

 __init__ (self, *args, **kwargs)
 
 Clone (self)
 
 GetClearance (self, aOther)
 
 IsNull (self)
 
 Collide (self, *args)
 
 BBox (self, aClearance=0)
 
 Centre (self)
 
 Distance (self, aP)
 
 SquaredDistance (self, aP, aOutlineOnly=False)
 
 NearestPoints (self, aOther, aPtThis, aPtOther)
 
 PointInside (self, aPt, aAccuracy=0, aUseBBoxCache=False)
 
 TransformToPolygon (self, aBuffer, aError, aErrorLoc)
 
 Rotate (self, *args)
 
 GetStart (self)
 
 GetEnd (self)
 
 GetWidth (self)
 
 SetWidth (self, aWidth)
 
 Move (self, aVector)
 
 IsSolid (self)
 
 Parse (self, aStream)
 
 Format (self, aCplusPlus=True)
 
 Cast (self)
 
- Public Member Functions inherited from pcbnew.SHAPE_BASE
 __init__ (self, aType)
 
 Type (self)
 
 TypeName (self)
 
 HasIndexableSubshapes (self)
 
 GetIndexableSubshapeCount (self)
 
 GetIndexableSubshapes (self, aSubshapes)
 

Static Public Attributes

 MIN_PRECISION_IU = _pcbnew.SHAPE_MIN_PRECISION_IU
 

Properties

 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 
- Properties inherited from pcbnew.SHAPE_BASE
 thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
 

Detailed Description

Proxy of C++ SHAPE class.

Definition at line 6021 of file pcbnew.py.

Constructor & Destructor Documentation

◆ __init__()

pcbnew.SHAPE.__init__ ( self,
* args,
** kwargs )

Definition at line 6026 of file pcbnew.py.

Member Function Documentation

◆ BBox()

pcbnew.SHAPE.BBox ( self,
aClearance = 0 )

◆ Cast()

pcbnew.SHAPE.Cast ( self)

Definition at line 6118 of file pcbnew.py.

◆ Centre()

pcbnew.SHAPE.Centre ( self)
Centre(SHAPE self) -> VECTOR2I

Definition at line 6058 of file pcbnew.py.

◆ Clone()

pcbnew.SHAPE.Clone ( self)
Clone(SHAPE self) -> SHAPE

Reimplemented in pcbnew.SHAPE_COMPOUND.

Definition at line 6033 of file pcbnew.py.

◆ Collide()

pcbnew.SHAPE.Collide ( self,
* args )
    Collide(SHAPE self, VECTOR2I aP, int aClearance=0, int * aActual=None, VECTOR2I aLocation=None) -> bool
    Collide(SHAPE self, SHAPE aShape, int aClearance, VECTOR2I aMTV) -> bool
    Collide(SHAPE self, SHAPE aShape, int aClearance=0, int * aActual=None, VECTOR2I aLocation=None) -> bool
    Collide(SHAPE self, SEG aSeg, int aClearance=0, int * aActual=None, VECTOR2I aLocation=None) -> bool

Reimplemented in pcbnew.SHAPE_ARC, pcbnew.SHAPE_CIRCLE, pcbnew.SHAPE_COMPOUND, pcbnew.SHAPE_LINE_CHAIN, pcbnew.SHAPE_LINE_CHAIN_BASE, pcbnew.SHAPE_POLY_SET, pcbnew.SHAPE_RECT, pcbnew.SHAPE_SEGMENT, and pcbnew.SHAPE_SIMPLE.

Definition at line 6045 of file pcbnew.py.

◆ Distance()

pcbnew.SHAPE.Distance ( self,
aP )
Distance(SHAPE self, VECTOR2I aP) -> int

Reimplemented in pcbnew.SHAPE_COMPOUND, and pcbnew.SHAPE_LINE_CHAIN.

Definition at line 6062 of file pcbnew.py.

◆ Format()

pcbnew.SHAPE.Format ( self,
aCplusPlus = True )
Format(SHAPE self, bool aCplusPlus=True) -> string

Reimplemented in pcbnew.SHAPE_CIRCLE, pcbnew.SHAPE_COMPOUND, pcbnew.SHAPE_LINE_CHAIN, pcbnew.SHAPE_POLY_SET, pcbnew.SHAPE_RECT, and pcbnew.SHAPE_SEGMENT.

Definition at line 6114 of file pcbnew.py.

◆ GetClearance()

pcbnew.SHAPE.GetClearance ( self,
aOther )
GetClearance(SHAPE self, SHAPE aOther) -> int

Definition at line 6037 of file pcbnew.py.

◆ GetEnd()

pcbnew.SHAPE.GetEnd ( self)
GetEnd(SHAPE self) -> VECTOR2I

Definition at line 6090 of file pcbnew.py.

◆ GetStart()

pcbnew.SHAPE.GetStart ( self)
GetStart(SHAPE self) -> VECTOR2I

Definition at line 6086 of file pcbnew.py.

◆ GetWidth()

pcbnew.SHAPE.GetWidth ( self)
GetWidth(SHAPE self) -> int

Definition at line 6094 of file pcbnew.py.

◆ IsNull()

pcbnew.SHAPE.IsNull ( self)
IsNull(SHAPE self) -> bool

Definition at line 6041 of file pcbnew.py.

◆ IsSolid()

pcbnew.SHAPE.IsSolid ( self)
IsSolid(SHAPE self) -> bool

Definition at line 6106 of file pcbnew.py.

◆ Move()

pcbnew.SHAPE.Move ( self,
aVector )
Move(SHAPE self, VECTOR2I aVector)

Definition at line 6102 of file pcbnew.py.

◆ NearestPoints()

pcbnew.SHAPE.NearestPoints ( self,
aOther,
aPtThis,
aPtOther )
NearestPoints(SHAPE self, SHAPE aOther, VECTOR2I aPtThis, VECTOR2I aPtOther) -> bool

Reimplemented in pcbnew.SHAPE_ARC.

Definition at line 6070 of file pcbnew.py.

◆ Parse()

pcbnew.SHAPE.Parse ( self,
aStream )
Parse(SHAPE self, std::stringstream & aStream) -> bool

Definition at line 6110 of file pcbnew.py.

◆ PointInside()

pcbnew.SHAPE.PointInside ( self,
aPt,
aAccuracy = 0,
aUseBBoxCache = False )
PointInside(SHAPE self, VECTOR2I aPt, int aAccuracy=0, bool aUseBBoxCache=False) -> bool

Reimplemented in pcbnew.SHAPE_LINE_CHAIN_BASE, and pcbnew.SHAPE_POLY_SET.

Definition at line 6074 of file pcbnew.py.

◆ Rotate()

pcbnew.SHAPE.Rotate ( self,
* args )
Rotate(SHAPE self, EDA_ANGLE aAngle, VECTOR2I aCenter={ 0, 0 })

Reimplemented in pcbnew.SHAPE_CIRCLE, pcbnew.SHAPE_COMPOUND, pcbnew.SHAPE_LINE_CHAIN, pcbnew.SHAPE_POLY_SET, pcbnew.SHAPE_RECT, pcbnew.SHAPE_SEGMENT, and pcbnew.SHAPE_SIMPLE.

Definition at line 6082 of file pcbnew.py.

◆ SetWidth()

pcbnew.SHAPE.SetWidth ( self,
aWidth )
SetWidth(SHAPE self, int aWidth)

Definition at line 6098 of file pcbnew.py.

◆ SquaredDistance()

pcbnew.SHAPE.SquaredDistance ( self,
aP,
aOutlineOnly = False )
SquaredDistance(SHAPE self, VECTOR2I aP, bool aOutlineOnly=False) -> SEG::ecoord

Reimplemented in pcbnew.SHAPE_LINE_CHAIN_BASE, and pcbnew.SHAPE_POLY_SET.

Definition at line 6066 of file pcbnew.py.

◆ TransformToPolygon()

pcbnew.SHAPE.TransformToPolygon ( self,
aBuffer,
aError,
aErrorLoc )
TransformToPolygon(SHAPE self, SHAPE_POLY_SET aBuffer, int aError, ERROR_LOC aErrorLoc)

Definition at line 6078 of file pcbnew.py.

Member Data Documentation

◆ MIN_PRECISION_IU

pcbnew.SHAPE.MIN_PRECISION_IU = _pcbnew.SHAPE_MIN_PRECISION_IU
static

Definition at line 6029 of file pcbnew.py.

Property Documentation

◆ thisown

pcbnew.SHAPE.thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
static

Definition at line 6024 of file pcbnew.py.


The documentation for this class was generated from the following file: