KiCad PCB EDA Suite
GBR_NETLIST_METADATA Class Reference

this class handle info which can be added in a gerber file as attribute of an obtect the GBR_INFO_TYPE types can be OR'ed to add 2 (or more) attributes There are only 3 net attributes defined attached to an object by the TO command TO.P TO.N TO.C the .P attribute can be used only for flashed pads (using the D03 command) and only for external copper layers, if the component is on a external copper layer for other copper layer items (pads on internal layers, tracks ... More...

#include <gbr_netlist_metadata.h>

Public Types

enum  GBR_NETINFO_TYPE { GBR_NETINFO_UNSPECIFIED, GBR_NETINFO_PAD = 1, GBR_NETINFO_NET = 2, GBR_NETINFO_CMP = 4 }
 

Public Member Functions

 GBR_NETLIST_METADATA ()
 
void ClearAttribute (const wxString *aName)
 remove the net attribute specified by aName If aName == NULL or empty, remove all attributes More...
 

Public Attributes

int m_NetAttribType
 the type of net info (used to define the gerber string to create) More...
 
bool m_NotInNet
 true if a pad of a footprint cannot be connected (for instance a mechanical NPTH, ot a not named pad) in this case the pad net name is empty in gerber file More...
 
wxString m_Padname
 for a flashed pad: the pad name ((TO.P attribute) More...
 
wxString m_Cmpref
 the component reference parent of the data More...
 
wxString m_Netname
 for items associated to a net: the netname More...
 

Detailed Description

this class handle info which can be added in a gerber file as attribute of an obtect the GBR_INFO_TYPE types can be OR'ed to add 2 (or more) attributes There are only 3 net attributes defined attached to an object by the TO command TO.P TO.N TO.C the .P attribute can be used only for flashed pads (using the D03 command) and only for external copper layers, if the component is on a external copper layer for other copper layer items (pads on internal layers, tracks ...

), only .N and .C can be used

Definition at line 41 of file gbr_netlist_metadata.h.

Member Enumeration Documentation

Enumerator
GBR_NETINFO_UNSPECIFIED 

idle command (no command)

GBR_NETINFO_PAD 

print info associated to a flashed pad (TO.P attribute)

GBR_NETINFO_NET 

print info associated to a net (TO.N attribute)

GBR_NETINFO_CMP 

print info associated to a component (TO.C attribute)

Definition at line 47 of file gbr_netlist_metadata.h.

48  {
50  GBR_NETINFO_PAD = 1,
51  GBR_NETINFO_NET = 2,
52  GBR_NETINFO_CMP = 4
53  };
print info associated to a component (TO.C attribute)
print info associated to a flashed pad (TO.P attribute)
print info associated to a net (TO.N attribute)

Constructor & Destructor Documentation

GBR_NETLIST_METADATA::GBR_NETLIST_METADATA ( )
inline

Definition at line 65 of file gbr_netlist_metadata.h.

66  {
67  }
bool m_NotInNet
true if a pad of a footprint cannot be connected (for instance a mechanical NPTH, ot a not named pad)...
int m_NetAttribType
the type of net info (used to define the gerber string to create)

Member Function Documentation

void GBR_NETLIST_METADATA::ClearAttribute ( const wxString *  aName)
inline

remove the net attribute specified by aName If aName == NULL or empty, remove all attributes

Parameters
aNameis the name (.CN, .P .N or .C) of the attribute to remove

Definition at line 74 of file gbr_netlist_metadata.h.

References GBR_NETINFO_CMP, GBR_NETINFO_NET, GBR_NETINFO_PAD, and GBR_NETINFO_UNSPECIFIED.

Referenced by GERBER_PLOTTER::FlashPadCustom(), GERBER_PLOTTER::FlashPadOval(), GERBER_PLOTTER::FlashPadRoundRect(), GERBER_PLOTTER::FlashPadTrapez(), and GERBER_FILE_IMAGE::RemoveAttribute().

75  {
77  {
78  m_Padname.clear();
79  m_Cmpref.clear();
80  m_Netname.clear();
81  return;
82  }
83 
84  if( !aName || aName->IsEmpty() || *aName == ".CN" )
85  {
87  m_Padname.clear();
88  m_Cmpref.clear();
89  m_Netname.clear();
90  return;
91  }
92 
93  if( *aName == ".C" )
94  {
96  m_Cmpref.clear();
97  return;
98  }
99 
100  if( *aName == ".N" )
101  {
103  m_Netname.clear();
104  return;
105  }
106 
107  if( *aName == ".P" )
108  {
110  m_Padname.clear();
111  return;
112  }
113  }
print info associated to a component (TO.C attribute)
wxString m_Cmpref
the component reference parent of the data
wxString m_Padname
for a flashed pad: the pad name ((TO.P attribute)
wxString m_Netname
for items associated to a net: the netname
print info associated to a flashed pad (TO.P attribute)
print info associated to a net (TO.N attribute)
int m_NetAttribType
the type of net info (used to define the gerber string to create)

Member Data Documentation

int GBR_NETLIST_METADATA::m_NetAttribType
bool GBR_NETLIST_METADATA::m_NotInNet

true if a pad of a footprint cannot be connected (for instance a mechanical NPTH, ot a not named pad) in this case the pad net name is empty in gerber file

Definition at line 58 of file gbr_netlist_metadata.h.

Referenced by FormatNetAttribute(), BRDITEMS_PLOTTER::PlotPad(), and PlotStandardLayer().

wxString GBR_NETLIST_METADATA::m_Padname

for a flashed pad: the pad name ((TO.P attribute)

Definition at line 61 of file gbr_netlist_metadata.h.

Referenced by GERBER_FILE_IMAGE::ExecuteRS274XCommand(), FormatNetAttribute(), GERBER_DRAW_ITEM::GetMsgPanelInfo(), and GBR_METADATA::SetPadName().


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