KiCAD pcbnew scripting
Public Member Functions | Public Attributes | List of all members
pcbnew.MARKER_PCB Class Reference
Inheritance diagram for pcbnew.MARKER_PCB:
Inheritance graph

Public Member Functions

def __init__ (self, args)
def Move (self, aMoveVector)
def Rotate (self, aRotCentre, aAngle)
def Flip (self, aCentre)
def Draw (self, args)
def GetPosition (self)
def SetPosition (self, aPos)
def SetItem (self, aItem)
def GetItem (self)
def HitTest (self, aPosition)
def IsOnLayer (self, aLayer)
def GetMsgPanelInfo (self, aList)
def GetSelectMenuText (self)
def GetMenuImage (self)
def ViewBBox (self)
def GetBoundingBox (self)
def ViewGetLayers (self, aLayers, aCount)
def GetClass (self)
- Public Member Functions inherited from pcbnew.BOARD_ITEM
def __init__ (self, args, kwargs)
def GetPosition (self)
def GetCenter (self)
def SetPosition (self, aPos)
def IsConnected (self)
def Next (self)
def Back (self)
def GetParent (self)
def GetLayer (self)
def GetLayerSet (self)
def SetLayer (self, aLayer)
def Draw (self, args)
def SwapData (self, aImage)
def IsOnLayer (self, aLayer)
def IsTrack (self)
def IsLocked (self)
def SetLocked (self, aLocked)
def UnLink (self)
def DeleteStructure (self)
def ShowShape (aShape)
def Move (self, aMoveVector)
def Rotate (self, aRotCentre, aAngle)
def Flip (self, aCentre)
def GetBoard (self)
def GetLayerName (self)
def HitTest (self, args)
def FormatAngle (aAngle)
def FormatInternalUnits (args)
def ViewGetLayers (self, aLayers, aCount)
def Cast (self)
def Duplicate (self)
def SetPos (self, p)
def SetStartEnd (self, start, end)
- Public Member Functions inherited from pcbnew.EDA_ITEM
def __init__ (self, args, kwargs)
def Type (self)
def SetTimeStamp (self, aNewTimeStamp)
def GetTimeStamp (self)
def Next (self)
def Back (self)
def GetParent (self)
def GetList (self)
def SetParent (self, aParent)
def SetList (self, aList)
def IsNew (self)
def IsModified (self)
def IsMoving (self)
def IsDragging (self)
def IsWireImage (self)
def IsSelected (self)
def IsResized (self)
def IsHighlighted (self)
def IsBrightened (self)
def SetWireImage (self)
def SetSelected (self)
def SetHighlighted (self)
def SetBrightened (self)
def ClearSelected (self)
def ClearHighlighted (self)
def ClearBrightened (self)
def SetModified (self)
def GetState (self, type)
def SetState (self, type, state)
def GetStatus (self)
def SetStatus (self, aStatus)
def SetFlags (self, aMask)
def ClearFlags
def GetFlags (self)
def SetForceVisible (self, aEnable)
def GetMsgPanelInfo (self, aList)
def HitTest (self, aPosition)
def GetBoundingBox (self)
def Clone (self)
def IterateForward (listStart, inspector, testData, scanTypes)
def Visit (self, inspector, testData, scanTypes)
def GetClass (self)
def GetSelectMenuText (self)
def GetMenuImage (self)
def Matches (self, aSearchData, aAuxData, aFindLocation)
def Replace (self, args)
def IsReplaceable (self)
def __lt__ (self, aItem)
def Sort (aLeft, aRight)
def ViewBBox (self)
def ViewGetLayers (self, aLayers, aCount)
- Public Member Functions inherited from pcbnew.MARKER_BASE
def __init__ (self, args)
def DrawMarker (self, aPanel, aDC, aDrawMode, aOffset)
def GetPos (self)
def SetColor (self, aColor)
def SetErrorLevel (self, aErrorLevel)
def GetErrorLevel (self)
def SetMarkerType (self, aMarkerType)
def GetMarkerType (self)
def SetData (self, args)
def SetAuxiliaryData (self, aAuxiliaryText, aAuxiliaryPos)
def SetShowNoCoordinate (self)
def GetReporter (self)
def DisplayMarkerInfo (self, aFrame)
def HitTestMarker (self, ref_pos)
def GetBoundingBoxMarker (self)

Public Attributes

- Public Attributes inherited from pcbnew.MARKER_BASE

Additional Inherited Members

- Static Public Attributes inherited from pcbnew.BOARD_ITEM
tuple ShowShape = staticmethod(ShowShape)
tuple FormatAngle = staticmethod(FormatAngle)
tuple FormatInternalUnits = staticmethod(FormatInternalUnits)
- Static Public Attributes inherited from pcbnew.EDA_ITEM
tuple IterateForward = staticmethod(IterateForward)
tuple Sort = staticmethod(Sort)
- Static Public Attributes inherited from pcbnew.MARKER_BASE
tuple m_Pos = _swig_property(_pcbnew.MARKER_BASE_m_Pos_get, _pcbnew.MARKER_BASE_m_Pos_set)

Detailed Description

C++ includes: class_marker_pcb.h 

Definition at line 28001 of file

Constructor & Destructor Documentation

def pcbnew.MARKER_PCB.__init__ (   self,
__init__(MARKER_PCB self, BOARD_ITEM aParent) -> MARKER_PCB
__init__(MARKER_PCB self, int aErrorCode, wxPoint aMarkerPos, wxString aText, wxPoint aPos, wxString bText, wxPoint bPos) -> MARKER_PCB
__init__(MARKER_PCB self, int aErrorCode, wxPoint aMarkerPos, wxString aText, wxPoint aPos) -> MARKER_PCB

MARKER_PCB::MARKER_PCB(int aErrorCode, const wxPoint &aMarkerPos,
const wxString &aText, const wxPoint &aPos)



aErrorCode:  The categorizing identifier for an error

aMarkerPos:  The position of the MARKER_PCB on the BOARD

aText:  Text describing the object

aPos:  The position of the object 

Definition at line 28013 of file

Member Function Documentation

def pcbnew.MARKER_PCB.Draw (   self,
Draw(MARKER_PCB self, EDA_DRAW_PANEL * aPanel, wxDC * aDC, GR_DRAWMODE aDrawMode, wxPoint aOffset)
Draw(MARKER_PCB self, EDA_DRAW_PANEL * aPanel, wxDC * aDC, GR_DRAWMODE aDrawMode)

aDrawMode, const wxPoint &aOffset=ZeroOffset) override

Function Draw BOARD_ITEMs have their own color information. 

Definition at line 28098 of file

Here is the caller graph for this function:

def pcbnew.MARKER_PCB.Flip (   self,
Flip(MARKER_PCB self, wxPoint aCentre)

void MARKER_PCB::Flip(const
wxPoint &aCentre) override

Function Flip Flip this object, i.e.

change the board side for this object


aCentre:  - the rotation point. 

Definition at line 28079 of file

def pcbnew.MARKER_PCB.GetBoundingBox (   self)
GetBoundingBox(MARKER_PCB self) -> EDA_RECT

const EDA_RECT
MARKER_PCB::GetBoundingBox() const override

Function GetBoundingBox returns the orthogonal, bounding box of this
object for display purposes.

This box should be an enclosing perimeter for visible components of
this object, and the units should be in the pcb or schematic
coordinate system. It is OK to overestimate the size by a few counts.

Definition at line 28274 of file

def pcbnew.MARKER_PCB.GetClass (   self)
GetClass(MARKER_PCB self) -> wxString

virtual wxString
MARKER_PCB::GetClass() const override

Get class name.

string "MARKER_PCB" 

Definition at line 28317 of file

def pcbnew.MARKER_PCB.GetItem (   self)

MARKER_PCB::GetItem() const 

Definition at line 28142 of file

def pcbnew.MARKER_PCB.GetMenuImage (   self)
GetMenuImage(MARKER_PCB self) -> BITMAP_DEF

MARKER_PCB::GetMenuImage() const override

Function GetMenuImage returns a pointer to an image to be used in

The default version returns the right arrow image. Override this
function to provide object specific menu images. The menu image
associated with the item. 

Definition at line 28242 of file

def pcbnew.MARKER_PCB.GetMsgPanelInfo (   self,
GetMsgPanelInfo(MARKER_PCB self, std::vector< MSG_PANEL_ITEM,std::allocator< MSG_PANEL_ITEM > > & aList)

MARKER_PCB::GetMsgPanelInfo(std::vector< MSG_PANEL_ITEM > &aList)

Function GetMsgPanelInfo populates aList of MSG_PANEL_ITEM objects
with it's internal state for display purposes.

This method replaces DisplayInfo() so that KiCad objects no longer
have any knowledge of wxWidgets UI objects.


aList:  is the list to populate. 

Definition at line 28200 of file

def pcbnew.MARKER_PCB.GetPosition (   self)
GetPosition(MARKER_PCB self) -> wxPoint

const wxPoint&
MARKER_PCB::GetPosition() const override 

Definition at line 28112 of file

def pcbnew.MARKER_PCB.GetSelectMenuText (   self)
GetSelectMenuText(MARKER_PCB self) -> wxString

MARKER_PCB::GetSelectMenuText() const override

Function GetSelectMenuText returns the text to display to be used in
the selection clarification context menu when multiple items are found
at the current cursor position.

The default version of this function raises an assertion in the debug
mode and returns a string to indicate that it was not overridden to
provide the object specific text.

The menu text string. 

Definition at line 28222 of file

def pcbnew.MARKER_PCB.HitTest (   self,
HitTest(MARKER_PCB self, wxPoint aPosition) -> bool

virtual bool
BOARD_ITEM::HitTest(const EDA_RECT &aRect, bool aContained=true, int
aAccuracy=0) const

Function HitTest tests if the aRect intersects or contains this object
(depending on aContained).


aRect:  A reference to an EDA_RECT object containg the area to test.

aContained:  Test if aRect contains this object completly.

aAccuracy:  Increase the item bounding box by this amount.

bool - True if aRect contains this object completly or if aRect
intersects the object and aContained is False, otherwise false. 

Definition at line 28152 of file

def pcbnew.MARKER_PCB.IsOnLayer (   self,
IsOnLayer(MARKER_PCB self, PCB_LAYER_ID aLayer) -> bool

MARKER_PCB::IsOnLayer(PCB_LAYER_ID aLayer) const override

Function IsOnLayer tests to see if this object is on the given layer.

Is virtual so objects like D_PAD, which reside on multiple layers can
do their own form of testing.


aLayer:  The layer to test for.

bool - true if on given layer, else false. 

Definition at line 28178 of file

def pcbnew.MARKER_PCB.Move (   self,
Move(MARKER_PCB self, wxPoint aMoveVector)

void MARKER_PCB::Move(const
wxPoint &aMoveVector) override

Function Move move this object.


aMoveVector:  - the move vector for this object. 

Definition at line 28043 of file

def pcbnew.MARKER_PCB.Rotate (   self,
Rotate(MARKER_PCB self, wxPoint aRotCentre, double aAngle)

MARKER_PCB::Rotate(const wxPoint &aRotCentre, double aAngle) override

Function Rotate Rotate this object.


aRotCentre:  - the rotation point.

aAngle:  - the rotation angle in 0.1 degree. 

Definition at line 28060 of file

def pcbnew.MARKER_PCB.SetItem (   self,
SetItem(MARKER_PCB self, BOARD_ITEM aItem)

MARKER_PCB::SetItem(const BOARD_ITEM *aItem) 

Definition at line 28132 of file

def pcbnew.MARKER_PCB.SetPosition (   self,
SetPosition(MARKER_PCB self, wxPoint aPos)

MARKER_PCB::SetPosition(const wxPoint &aPos) override 

Definition at line 28122 of file

def pcbnew.MARKER_PCB.ViewBBox (   self)
ViewBBox(MARKER_PCB self) -> BOX2I const

const BOX2I
MARKER_PCB::ViewBBox() const override

Function ViewBBox() returns the bounding box of the item covering all
its layers.

BOX2I - the current bounding box 

Definition at line 28259 of file

def pcbnew.MARKER_PCB.ViewGetLayers (   self,
ViewGetLayers(MARKER_PCB self, int [] aLayers, int & aCount)

MARKER_PCB::ViewGetLayers(int aLayers[], int &aCount) const override

Function ViewGetLayers() Returns the all the layers within the VIEW
the object is painted on.

For instance, a D_PAD spans zero or more copper layers and a few
technical layers. ViewDraw() or PAINTER::Draw() is repeatedly called
for each of the layers returned by ViewGetLayers(), depending on the
rendering order.


aLayers[]:  output layer index array

aCount:  number of layer indices in aLayers[] 

Definition at line 28292 of file

Member Data Documentation


Definition at line 28039 of file

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