KiCAD pcbnew scripting
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
pcbnew.LSET Class Reference
Inheritance diagram for pcbnew.LSET:
Inheritance graph
[legend]

Public Member Functions

def __init__ (self, args)
 
def Name (aLayerId)
 
def InternalCuMask ()
 
def AllCuMask (args)
 
def ExternalCuMask ()
 
def AllNonCuMask ()
 
def AllLayersMask ()
 
def FrontTechMask ()
 
def FrontBoardTechMask ()
 
def BackTechMask ()
 
def BackBoardTechMask ()
 
def AllTechMask ()
 
def AllBoardTechMask ()
 
def FrontMask ()
 
def BackMask ()
 
def UserMask ()
 
def CuStack (self)
 
def Technicals (self, args)
 
def Users (self)
 
def TechAndUserUIOrder (self)
 
def UIOrder (self)
 
def Seq (self, args)
 
def SeqStackupBottom2Top (self)
 
def FmtHex (self)
 
def ParseHex (self, aStart, aCount)
 
def FmtBin (self)
 
def ExtractLayer (self)
 
def addLayer (self, aLayer)
 
def removeLayer (self, aLayer)
 
def addLayerSet (self, aLayerSet)
 
def removeLayerSet (self, aLayerSet)
 
def AddLayer (self, layer)
 
def AddLayerSet (self, layers)
 
def RemoveLayer (self, layer)
 
def RemoveLayerSet (self, layers)
 
- Public Member Functions inherited from pcbnew.BASE_SET
def __init__ (self, args, kwargs)
 

Public Attributes

 this
 

Static Public Attributes

tuple Name = staticmethod(Name)
 
tuple InternalCuMask = staticmethod(InternalCuMask)
 
tuple AllCuMask = staticmethod(AllCuMask)
 
tuple ExternalCuMask = staticmethod(ExternalCuMask)
 
tuple AllNonCuMask = staticmethod(AllNonCuMask)
 
tuple AllLayersMask = staticmethod(AllLayersMask)
 
tuple FrontTechMask = staticmethod(FrontTechMask)
 
tuple FrontBoardTechMask = staticmethod(FrontBoardTechMask)
 
tuple BackTechMask = staticmethod(BackTechMask)
 
tuple BackBoardTechMask = staticmethod(BackBoardTechMask)
 
tuple AllTechMask = staticmethod(AllTechMask)
 
tuple AllBoardTechMask = staticmethod(AllBoardTechMask)
 
tuple FrontMask = staticmethod(FrontMask)
 
tuple BackMask = staticmethod(BackMask)
 
tuple UserMask = staticmethod(UserMask)
 

Detailed Description

Class LSET is a set of PCB_LAYER_IDs.

It can be converted to numerous purpose LSEQs using the various member
functions, most of which are based on Seq(). The advantage of
converting to LSEQ using purposeful code, is it removes any dependency
on order/sequence inherent in this set.

C++ includes: layers_id_colors_and_visibility.h 

Definition at line 33013 of file pcbnew.py.

Constructor & Destructor Documentation

def pcbnew.LSET.__init__ (   self,
  args 
)
__init__(LSET self) -> LSET
__init__(LSET self, BASE_SET aOther) -> LSET
__init__(LSET self, PCB_LAYER_ID aLayer) -> LSET
__init__(LSET self, PCB_LAYER_ID const * aArray, unsigned int aCount) -> LSET
__init__(LSET self, unsigned int aIdCount, int aFirst) -> LSET

LSET::LSET(unsigned aIdCount, int
aFirst,...)

Constructor LSET( unsigned, PCB_LAYER_ID, ...) takes one or more
PCB_LAYER_IDs in the argument list to construct the set.

Typically only used in static construction.

Parameters:
-----------

aIdCount:  is the number of PCB_LAYER_IDs which follow.

aFirst:  is the first included in aIdCount and must always be present,
and can be followed by any number of additional PCB_LAYER_IDs so long
as aIdCount accurately reflects the count.

Parameter is 'int' to avoid va_start undefined behavior. 

Definition at line 33036 of file pcbnew.py.

Member Function Documentation

def pcbnew.LSET.addLayer (   self,
  aLayer 
)
addLayer(LSET self, PCB_LAYER_ID aLayer) -> LSET

Definition at line 33349 of file pcbnew.py.

def pcbnew.LSET.AddLayer (   self,
  layer 
)

Definition at line 33369 of file pcbnew.py.

def pcbnew.LSET.addLayerSet (   self,
  aLayerSet 
)
addLayerSet(LSET self, LSET aLayerSet) -> LSET

Definition at line 33359 of file pcbnew.py.

def pcbnew.LSET.AddLayerSet (   self,
  layers 
)

Definition at line 33372 of file pcbnew.py.

def pcbnew.LSET.AllBoardTechMask ( )
AllBoardTechMask() -> LSET

Definition at line 33160 of file pcbnew.py.

def pcbnew.LSET.AllCuMask (   args)
AllCuMask(int aCuLayerCount) -> LSET
AllCuMask() -> LSET

Definition at line 33085 of file pcbnew.py.

def pcbnew.LSET.AllLayersMask ( )
AllLayersMask() -> LSET

Definition at line 33112 of file pcbnew.py.

def pcbnew.LSET.AllNonCuMask ( )
AllNonCuMask() -> LSET

Definition at line 33104 of file pcbnew.py.

def pcbnew.LSET.AllTechMask ( )
AllTechMask() -> LSET

Definition at line 33152 of file pcbnew.py.

def pcbnew.LSET.BackBoardTechMask ( )
BackBoardTechMask() -> LSET

Definition at line 33144 of file pcbnew.py.

def pcbnew.LSET.BackMask ( )
BackMask() -> LSET

Definition at line 33176 of file pcbnew.py.

def pcbnew.LSET.BackTechMask ( )
BackTechMask() -> LSET

Definition at line 33136 of file pcbnew.py.

def pcbnew.LSET.CuStack (   self)
CuStack(LSET self) -> LSEQ

LSEQ LSET::CuStack() const

Function CuStack returns a sequence of copper layers in starting from
the front/top and extending to the back/bottom.

This specific sequence is depended upon in numerous places. 

Definition at line 33192 of file pcbnew.py.

def pcbnew.LSET.ExternalCuMask ( )
ExternalCuMask() -> LSET

Definition at line 33096 of file pcbnew.py.

def pcbnew.LSET.ExtractLayer (   self)
ExtractLayer(LSET self) -> PCB_LAYER_ID

PCB_LAYER_ID
LSET::ExtractLayer() const

Find the first set PCB_LAYER_ID.

Returns UNDEFINED_LAYER if more than one is set or UNSELECTED_LAYER if
none is set. 

Definition at line 33334 of file pcbnew.py.

def pcbnew.LSET.FmtBin (   self)
FmtBin(LSET self) -> string

std::string LSET::FmtBin() const

Function FmtBin returns a binary string showing contents of this LSEQ.

Definition at line 33322 of file pcbnew.py.

def pcbnew.LSET.FmtHex (   self)
FmtHex(LSET self) -> string

std::string LSET::FmtHex() const

Function FmtHex returns a hex string showing contents of this LSEQ. 

Definition at line 33294 of file pcbnew.py.

Here is the caller graph for this function:

def pcbnew.LSET.FrontBoardTechMask ( )
FrontBoardTechMask() -> LSET

Definition at line 33128 of file pcbnew.py.

def pcbnew.LSET.FrontMask ( )
FrontMask() -> LSET

Definition at line 33168 of file pcbnew.py.

def pcbnew.LSET.FrontTechMask ( )
FrontTechMask() -> LSET

Definition at line 33120 of file pcbnew.py.

def pcbnew.LSET.InternalCuMask ( )
InternalCuMask() -> LSET

Definition at line 33077 of file pcbnew.py.

def pcbnew.LSET.Name (   aLayerId)
Name(PCB_LAYER_ID aLayerId) -> wxChar const *

Definition at line 33069 of file pcbnew.py.

def pcbnew.LSET.ParseHex (   self,
  aStart,
  aCount 
)
ParseHex(LSET self, char const * aStart, int aCount) -> int

int LSET::ParseHex(const char
*aStart, int aCount)

Function ParseHex understands the output of FmtHex() and replaces this
set's values with those given in the input string.

Parsing stops at the first non hex ASCII byte, except that marker
bytes output from FmtHex are not terminators. int - number of bytes
consumed 

Definition at line 33305 of file pcbnew.py.

def pcbnew.LSET.removeLayer (   self,
  aLayer 
)
removeLayer(LSET self, PCB_LAYER_ID aLayer) -> LSET

Definition at line 33354 of file pcbnew.py.

def pcbnew.LSET.RemoveLayer (   self,
  layer 
)

Definition at line 33375 of file pcbnew.py.

def pcbnew.LSET.removeLayerSet (   self,
  aLayerSet 
)
removeLayerSet(LSET self, LSET aLayerSet) -> LSET

Definition at line 33364 of file pcbnew.py.

def pcbnew.LSET.RemoveLayerSet (   self,
  layers 
)

Definition at line 33378 of file pcbnew.py.

def pcbnew.LSET.Seq (   self,
  args 
)
Seq(LSET self, PCB_LAYER_ID const * aWishListSequence, unsigned int aCount) -> LSEQ
Seq(LSET self) -> LSEQ

LSEQ LSET::Seq() const

Function Seq returns a LSEQ from this LSET in ascending PCB_LAYER_ID
order.

Each LSEQ element will be in the same sequence as in PCB_LAYER_ID and
only present in the resultant LSEQ if present in this set. Therefore
the sequence is subject to change, use it only when enumeration and
not order is important. 

Definition at line 33260 of file pcbnew.py.

def pcbnew.LSET.SeqStackupBottom2Top (   self)
SeqStackupBottom2Top(LSET self) -> LSEQ

LSEQ
LSET::SeqStackupBottom2Top() const

Function SeqStackBottom2Top returns the sequence that is typical for a
bottom-to-top stack-up.

For instance, to plot multiple layers in a single image, the top
layers output last. 

Definition at line 33278 of file pcbnew.py.

def pcbnew.LSET.TechAndUserUIOrder (   self)
TechAndUserUIOrder(LSET self) -> LSEQ

LSEQ
LSET::TechAndUserUIOrder() const

Returns the technical and user layers in the order shown in layer
widget. 

Definition at line 33238 of file pcbnew.py.

def pcbnew.LSET.Technicals (   self,
  args 
)
Technicals(LSET self, LSET aSubToOmit) -> LSEQ
Technicals(LSET self) -> LSEQ

LSEQ LSET::Technicals(LSET
aSubToOmit=LSET()) const

Function Technicals returns a sequence of technical layers.

A sequence provides a certain order.

Parameters:
-----------

aSubToOmit:  is the subset of the techical layers to omit, defaults to
none. 

Definition at line 33206 of file pcbnew.py.

def pcbnew.LSET.UIOrder (   self)
UIOrder(LSET self) -> LSEQ

LSEQ LSET::UIOrder() const 

Definition at line 33251 of file pcbnew.py.

def pcbnew.LSET.UserMask ( )
UserMask() -> LSET

Definition at line 33184 of file pcbnew.py.

def pcbnew.LSET.Users (   self)
Users(LSET self) -> LSEQ

LSEQ LSET::Users() const

*_User layers. 

Definition at line 33227 of file pcbnew.py.

Member Data Documentation

tuple pcbnew.LSET.AllBoardTechMask = staticmethod(AllBoardTechMask)
static

Definition at line 33165 of file pcbnew.py.

tuple pcbnew.LSET.AllCuMask = staticmethod(AllCuMask)
static

Definition at line 33093 of file pcbnew.py.

tuple pcbnew.LSET.AllLayersMask = staticmethod(AllLayersMask)
static

Definition at line 33117 of file pcbnew.py.

tuple pcbnew.LSET.AllNonCuMask = staticmethod(AllNonCuMask)
static

Definition at line 33109 of file pcbnew.py.

tuple pcbnew.LSET.AllTechMask = staticmethod(AllTechMask)
static

Definition at line 33157 of file pcbnew.py.

tuple pcbnew.LSET.BackBoardTechMask = staticmethod(BackBoardTechMask)
static

Definition at line 33149 of file pcbnew.py.

tuple pcbnew.LSET.BackMask = staticmethod(BackMask)
static

Definition at line 33181 of file pcbnew.py.

tuple pcbnew.LSET.BackTechMask = staticmethod(BackTechMask)
static

Definition at line 33141 of file pcbnew.py.

tuple pcbnew.LSET.ExternalCuMask = staticmethod(ExternalCuMask)
static

Definition at line 33101 of file pcbnew.py.

tuple pcbnew.LSET.FrontBoardTechMask = staticmethod(FrontBoardTechMask)
static

Definition at line 33133 of file pcbnew.py.

tuple pcbnew.LSET.FrontMask = staticmethod(FrontMask)
static

Definition at line 33173 of file pcbnew.py.

tuple pcbnew.LSET.FrontTechMask = staticmethod(FrontTechMask)
static

Definition at line 33125 of file pcbnew.py.

tuple pcbnew.LSET.InternalCuMask = staticmethod(InternalCuMask)
static

Definition at line 33082 of file pcbnew.py.

tuple pcbnew.LSET.Name = staticmethod(Name)
static

Definition at line 33074 of file pcbnew.py.

pcbnew.LSET.this

Definition at line 33067 of file pcbnew.py.

tuple pcbnew.LSET.UserMask = staticmethod(UserMask)
static

Definition at line 33189 of file pcbnew.py.


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