KiCad PCB EDA Suite
class_track.h
Go to the documentation of this file.
1 /*
2  * This program source code file is part of KiCad, a free EDA CAD application.
3  *
4  * Copyright (C) 2004 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com
5  * Copyright (C) 1992-2017 KiCad Developers, see AUTHORS.txt for contributors.
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, you may find one here:
19  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
20  * or you may search the http://www.gnu.org website for the version 2 license,
21  * or you may write to the Free Software Foundation, Inc.,
22  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
23  */
24 
30 #ifndef CLASS_TRACK_H
31 #define CLASS_TRACK_H
32 
33 
34 #include <pcbnew.h>
35 #include <class_board_item.h>
37 #include <PolyLine.h>
38 #include <trigo.h>
39 
40 
41 class TRACK;
42 class VIA;
43 class D_PAD;
44 class MSG_PANEL_ITEM;
45 
46 
47 // Via types
48 // Note that this enum must be synchronized to GAL_LAYER_ID
50 {
51  VIA_THROUGH = 3, /* Always a through hole via */
52  VIA_BLIND_BURIED = 2, /* this via can be on internal layers */
53  VIA_MICROVIA = 1, /* this via which connect from an external layer
54  * to the near neighbor internal layer */
55  VIA_NOT_DEFINED = 0 /* not yet used */
56 };
57 
58 #define UNDEFINED_DRILL_DIAMETER -1 //< Undefined via drill diameter.
59 
60 #define MIN_VIA_DRAW_SIZE 4
61 
62 
78 TRACK* GetTrack( TRACK* aStartTrace, const TRACK* aEndTrace,
79  const wxPoint& aPosition, LSET aLayerMask );
80 
82 {
83 public:
84  static inline bool ClassOf( const EDA_ITEM* aItem )
85  {
86  return aItem && PCB_TRACE_T == aItem->Type();
87  }
88 
89  BOARD_CONNECTED_ITEM* start; // pointers to a connected item (pad or track)
91 
92  double m_Param; // Auxiliary variable ( used in some computations )
93 
94  TRACK( BOARD_ITEM* aParent, KICAD_T idtype = PCB_TRACE_T );
95 
96  // Do not create a copy constructor. The one generated by the compiler is adequate.
97 
98  TRACK* Next() const { return static_cast<TRACK*>( Pnext ); }
99  TRACK* Back() const { return static_cast<TRACK*>( Pback ); }
100 
101  virtual void Move( const wxPoint& aMoveVector ) override
102  {
103  m_Start += aMoveVector;
104  m_End += aMoveVector;
105  }
106 
107  virtual void Rotate( const wxPoint& aRotCentre, double aAngle ) override;
108 
109  virtual void Flip( const wxPoint& aCentre ) override;
110 
111  void SetPosition( const wxPoint& aPos ) override { m_Start = aPos; }
112  const wxPoint& GetPosition() const override { return m_Start; }
113 
114  void SetWidth( int aWidth ) { m_Width = aWidth; }
115  int GetWidth() const { return m_Width; }
116 
117  void SetEnd( const wxPoint& aEnd ) { m_End = aEnd; }
118  const wxPoint& GetEnd() const { return m_End; }
119 
120  void SetStart( const wxPoint& aStart ) { m_Start = aStart; }
121  const wxPoint& GetStart() const { return m_Start; }
122 
123 
125  const wxPoint& GetEndPoint( ENDPOINT_T aEndPoint ) const
126  {
127  if( aEndPoint == ENDPOINT_START )
128  return m_Start;
129  else
130  return m_End;
131  }
132 
133  // Virtual function
134  const EDA_RECT GetBoundingBox() const override;
135 
136  bool IsLocked() const override
137  {
138  return GetState( TRACK_LOCKED );
139  }
140 
141  void SetLocked( bool aLocked ) override
142  {
143  return SetState( TRACK_LOCKED, aLocked );
144  }
145 
154  TRACK* GetBestInsertPoint( BOARD* aPcb );
155 
156  /* Search (within the track linked list) the first segment matching the netcode
157  * ( the linked list is always sorted by net codes )
158  */
159  TRACK* GetStartNetCode( int NetCode );
160 
161  /* Search (within the track linked list) the last segment matching the netcode
162  * ( the linked list is always sorted by net codes )
163  */
164  TRACK* GetEndNetCode( int NetCode );
165 
171  double GetLength() const
172  {
173  return GetLineLength( m_Start, m_End );
174  }
175 
176  /* Display on screen: */
177  void Draw( EDA_DRAW_PANEL* panel, wxDC* DC,
178  GR_DRAWMODE aDrawMode, const wxPoint& aOffset = ZeroOffset ) override;
179 
193  int aClearanceValue,
194  int aCircleToSegmentsCount,
195  double aCorrectionFactor ) const;
203  STATUS_FLAGS IsPointOnEnds( const wxPoint& point, int min_dist = 0 );
204 
209  bool IsNull();
210 
211  void GetMsgPanelInfo( std::vector< MSG_PANEL_ITEM >& aList ) override;
212 
217  wxString ShowWidth() const;
218 
219  SEARCH_RESULT Visit( INSPECTOR inspector, void* testData, const KICAD_T scanTypes[] ) override;
220 
221  virtual bool HitTest( const wxPoint& aPosition ) const override;
222 
223  virtual bool HitTest( const EDA_RECT& aRect, bool aContained = true, int aAccuracy = 0 ) const override;
224 
233  VIA* GetVia( const wxPoint& aPosition, PCB_LAYER_ID aLayer = UNDEFINED_LAYER );
234 
245  VIA* GetVia( TRACK* aEndTrace, const wxPoint& aPosition, LSET aLayerMask );
246 
262  TRACK* GetTrack( TRACK* aStartTrace, TRACK* aEndTrace, ENDPOINT_T aEndPoint,
263  bool aSameNetOnly, bool aSequential );
264 
275  int GetEndSegments( int NbSegm, TRACK** StartTrack, TRACK** EndTrack );
276 
277  wxString GetClass() const override
278  {
279  return wxT( "TRACK" );
280  }
281 
291  virtual int GetClearance( BOARD_CONNECTED_ITEM* aItem = NULL ) const override;
292 
293  virtual wxString GetSelectMenuText() const override;
294 
295  BITMAP_DEF GetMenuImage() const override;
296 
297  virtual EDA_ITEM* Clone() const override;
298 
299  virtual void ViewGetLayers( int aLayers[], int& aCount ) const override;
300 
301  virtual unsigned int ViewGetLOD( int aLayer, KIGFX::VIEW* aView ) const override;
302 
303 #if defined (DEBUG)
304  virtual void Show( int nestLevel, std::ostream& os ) const override { ShowDummy( os ); }
305 
311  static wxString ShowState( int stateBits );
312 
313 #endif
314 
315 protected:
321  virtual void GetMsgPanelInfoBase( std::vector< MSG_PANEL_ITEM >& aList );
322 
323 
326  void GetMsgPanelInfoBase_Common( std::vector< MSG_PANEL_ITEM >& aList );
327 
330  void DrawShortNetname( EDA_DRAW_PANEL* panel, wxDC* aDC, GR_DRAWMODE aDrawMode,
331  COLOR4D aBgColor );
332 
333  int m_Width;
336 
337 private:
338  // make SetNext() and SetBack() private so that they may not be called from anywhere.
339  // list management is done on TRACKs using DLIST<TRACK> only.
340  void SetNext( EDA_ITEM* aNext ) { Pnext = aNext; }
341  void SetBack( EDA_ITEM* aBack ) { Pback = aBack; }
342 };
343 
344 
345 class SEGZONE : public TRACK
346 {
347 public:
348  SEGZONE( BOARD_ITEM* aParent );
349 
350  // Do not create a copy constructor. The one generated by the compiler is adequate.
351 
352  wxString GetClass() const override
353  {
354  return wxT( "ZONE" );
355  }
356 
357 
358  SEGZONE* Next() const { return static_cast<SEGZONE*>( Pnext ); }
359 
360  wxString GetSelectMenuText() const override;
361 
362  void Draw( EDA_DRAW_PANEL* panel, wxDC* DC,
363  GR_DRAWMODE aDrawMode, const wxPoint& aOffset = ZeroOffset ) override;
364 
365  BITMAP_DEF GetMenuImage() const override;
366 
367  EDA_ITEM* Clone() const override;
368 
369 protected:
370  virtual void GetMsgPanelInfoBase( std::vector< MSG_PANEL_ITEM >& aList ) override;
371 };
372 
373 
374 class VIA : public TRACK
375 {
376 public:
377  VIA( BOARD_ITEM* aParent );
378 
379  static inline bool ClassOf( const EDA_ITEM *aItem )
380  {
381  return aItem && PCB_VIA_T == aItem->Type();
382  }
383 
384  // Do not create a copy constructor. The one generated by the compiler is adequate.
385 
386  void Draw( EDA_DRAW_PANEL* panel, wxDC* DC,
387  GR_DRAWMODE aDrawMode, const wxPoint& aOffset = ZeroOffset ) override;
388 
389  bool IsOnLayer( PCB_LAYER_ID aLayer ) const override;
390 
391  virtual LSET GetLayerSet() const override;
392 
400  void SetLayerPair( PCB_LAYER_ID aTopLayer, PCB_LAYER_ID aBottomLayer );
401 
409  void LayerPair( PCB_LAYER_ID* top_layer, PCB_LAYER_ID* bottom_layer ) const;
410 
411  const wxPoint& GetPosition() const override { return m_Start; }
412  void SetPosition( const wxPoint& aPoint ) override { m_Start = aPoint; m_End = aPoint; }
413 
414  virtual bool HitTest( const wxPoint& aPosition ) const override;
415 
416  virtual bool HitTest( const EDA_RECT& aRect, bool aContained = true, int aAccuracy = 0 ) const override;
417 
418  wxString GetClass() const override
419  {
420  return wxT( "VIA" );
421  }
422 
423  wxString GetSelectMenuText() const override;
424 
425  BITMAP_DEF GetMenuImage() const override;
426 
427  EDA_ITEM* Clone() const override;
428 
429  virtual void ViewGetLayers( int aLayers[], int& aCount ) const override;
430 
431  virtual unsigned int ViewGetLOD( int aLayer, KIGFX::VIEW* aView ) const override;
432 
433  virtual void Flip( const wxPoint& aCentre ) override;
434 
435 #if defined (DEBUG)
436  virtual void Show( int nestLevel, std::ostream& os ) const override { ShowDummy( os ); }
437 #endif
438 
439  VIATYPE_T GetViaType() const { return m_ViaType; }
440  void SetViaType( VIATYPE_T aViaType ) { m_ViaType = aViaType; }
441 
447  void SetDrill( int aDrill ) { m_Drill = aDrill; }
448 
454  int GetDrill() const { return m_Drill; }
455 
462  int GetDrillValue() const;
463 
469 
474  bool IsDrillDefault() const { return m_Drill <= 0; }
475 
476 protected:
477  virtual void GetMsgPanelInfoBase( std::vector< MSG_PANEL_ITEM >& aList ) override;
478 
479 private:
482 
483  VIATYPE_T m_ViaType; // Type of via
484 
485  int m_Drill; // for vias: via drill (- 1 for default value)
486 };
487 
488 
490 inline VIA* GetFirstVia( TRACK* aTrk, const TRACK* aStopPoint = NULL )
491 {
492  while( aTrk && (aTrk != aStopPoint) && (aTrk->Type() != PCB_VIA_T) )
493  aTrk = aTrk->Next();
494 
495  // It could stop because of the stop point, not on a via
496  if( aTrk && (aTrk->Type() == PCB_VIA_T) )
497  return static_cast<VIA*>( aTrk );
498  else
499  return NULL;
500 }
501 
502 
504 inline TRACK* GetFirstTrack( TRACK* aTrk, const TRACK* aStopPoint = NULL )
505 {
506  while( aTrk && ( aTrk != aStopPoint ) && ( aTrk->Type() != PCB_TRACE_T ) )
507  aTrk = aTrk->Next();
508 
509  // It could stop because of the stop point, not on a via
510  if( aTrk && ( aTrk->Type() == PCB_TRACE_T ) )
511  return static_cast<TRACK*>( aTrk );
512  else
513  return NULL;
514 }
515 
516 #endif // CLASS_TRACK_H
bool IsLocked() const override
Function IsLocked.
Definition: class_track.h:136
KICAD_T Type() const
Function Type()
Definition: base_struct.h:212
Class BOARD_CONNECTED_ITEM.
TRACK * GetTrack(TRACK *aStartTrace, TRACK *aEndTrace, ENDPOINT_T aEndPoint, bool aSameNetOnly, bool aSequential)
Function GetTrack returns the trace segment connected to the segment at aEndPoint from aStartTrace to...
EDA_ITEM * Pback
previous in linked list
Definition: base_struct.h:179
bool IsNull()
Function IsNull returns true if segment length is zero.
wxPoint m_Start
Line start point.
Definition: class_track.h:334
double GetLineLength(const wxPoint &aPointA, const wxPoint &aPointB)
Function GetLineLength returns the length of a line segment defined by aPointA and aPointB...
Definition: trigo.h:191
VIATYPE_T m_ViaType
Definition: class_track.h:483
PNG memory record (file in memory).
Definition: bitmap_types.h:38
static bool ClassOf(const EDA_ITEM *aItem)
Definition: class_track.h:84
virtual LSET GetLayerSet() const override
Function GetLayerSet returns a "layer mask", which is a bitmap of all layers on which the TRACK segme...
void SetViaType(VIATYPE_T aViaType)
Definition: class_track.h:440
wxString GetSelectMenuText() const override
Function GetSelectMenuText returns the text to display to be used in the selection clarification cont...
void SetPosition(const wxPoint &aPoint) override
Definition: class_track.h:412
Class BOARD_ITEM is a base class for any item which can be embedded within the BOARD container class...
void SetEnd(const wxPoint &aEnd)
Definition: class_track.h:117
Classes BOARD_ITEM and BOARD_CONNECTED_ITEM.
virtual void Flip(const wxPoint &aCentre) override
Function Flip Flip this object, i.e.
STATUS_FLAGS IsPointOnEnds(const wxPoint &point, int min_dist=0)
Function IsPointOnEnds returns STARTPOINT if point if near (dist = min_dist) start point...
TRACK * GetTrack(TRACK *aStartTrace, const TRACK *aEndTrace, const wxPoint &aPosition, LSET aLayerMask)
Function GetTrack is a helper function to locate a trace segment having an end point at aPosition on ...
Definition: class_track.cpp:67
const EDA_RECT GetBoundingBox() const override
Function GetBoundingBox returns the orthogonal, bounding box of this object for display purposes...
virtual void ViewGetLayers(int aLayers[], int &aCount) const override
Function ViewGetLayers() Returns the all the layers within the VIEW the object is painted on...
wxString GetClass() const override
Function GetClass returns the class name.
Definition: class_track.h:352
virtual EDA_ITEM * Clone() const override
Function Clone creates a duplicate of this item with linked list members set to NULL.
int GetEndSegments(int NbSegm, TRACK **StartTrack, TRACK **EndTrack)
Function GetEndSegments get the segments connected to the end point of the track. ...
void GetMsgPanelInfo(std::vector< MSG_PANEL_ITEM > &aList) override
Function GetMsgPanelInfo populates aList of MSG_PANEL_ITEM objects with it's internal state for displ...
VIATYPE_T
Definition: class_track.h:49
VIA(BOARD_ITEM *aParent)
virtual void Rotate(const wxPoint &aRotCentre, double aAngle) override
Function Rotate Rotate this object.
int GetState(int type) const
Definition: base_struct.h:251
Class BOARD_CONNECTED_ITEM is a base class derived from BOARD_ITEM for items that can be connected an...
TRACK * Back() const
Definition: class_track.h:99
int GetDrill() const
Function GetDrill returns the local drill setting for this VIA.
Definition: class_track.h:454
const wxPoint & GetEnd() const
Definition: class_track.h:118
KICAD_T
Enum KICAD_T is the set of class identification values, stored in EDA_ITEM::m_StructType.
Definition: typeinfo.h:90
static wxPoint ZeroOffset
A value of wxPoint(0,0) which can be passed to the Draw() functions.
class TRACK, a track segment (segment on a copper layer)
Definition: typeinfo.h:107
double m_Param
Definition: class_track.h:92
int m_Width
Thickness of track, or via diameter.
Definition: class_track.h:333
void SetWidth(int aWidth)
Definition: class_track.h:114
ENDPOINT_T
Flag used in locate routines (from which endpoint work)
Definition: pcbnew.h:54
SEGZONE * Next() const
Definition: class_track.h:358
virtual void GetMsgPanelInfoBase(std::vector< MSG_PANEL_ITEM > &aList) override
Function GetMsgPanelInfoBase Display info about the track segment only, and does not calculate the fu...
virtual unsigned int ViewGetLOD(int aLayer, KIGFX::VIEW *aView) const override
Function ViewGetLOD() Returns the level of detail of the item.
const wxPoint & GetPosition() const override
Definition: class_track.h:112
const INSPECTOR_FUNC & INSPECTOR
Definition: base_struct.h:118
VIA * GetVia(const wxPoint &aPosition, PCB_LAYER_ID aLayer=UNDEFINED_LAYER)
Function GetVia finds the first VIA object at aPosition on aLayer starting at the trace...
void SetLocked(bool aLocked) override
Function SetLocked modifies 'lock' status for of the item.
Definition: class_track.h:141
static bool ClassOf(const EDA_ITEM *aItem)
Definition: class_track.h:379
PCB_LAYER_ID
A quick note on layer IDs:
virtual bool HitTest(const wxPoint &aPosition) const override
Function HitTest tests if aPosition is contained within or on the bounding area of an item...
BITMAP_DEF GetMenuImage() const override
Function GetMenuImage returns a pointer to an image to be used in menus.
Class LSET is a set of PCB_LAYER_IDs.
VIATYPE_T GetViaType() const
Definition: class_track.h:439
BITMAP_DEF GetMenuImage() const override
Function GetMenuImage returns a pointer to an image to be used in menus.
GR_DRAWMODE
Drawmode. Compositing mode plus a flag or two.
Definition: gr_basic.h:41
Class SHAPE_POLY_SET.
virtual bool HitTest(const wxPoint &aPosition) const override
Function HitTest tests if aPosition is contained within or on the bounding area of an item...
const wxPoint & GetStart() const
Definition: class_track.h:121
virtual void Flip(const wxPoint &aCentre) override
Function Flip Flip this object, i.e.
wxPoint m_End
Line end point.
Definition: class_track.h:335
int m_Drill
Definition: class_track.h:485
void DrawShortNetname(EDA_DRAW_PANEL *panel, wxDC *aDC, GR_DRAWMODE aDrawMode, COLOR4D aBgColor)
Helper for drawing the short netname in tracks.
const wxPoint & GetEndPoint(ENDPOINT_T aEndPoint) const
Return the selected endpoint (start or end)
Definition: class_track.h:125
unsigned STATUS_FLAGS
Definition: base_struct.h:158
SEARCH_RESULT Visit(INSPECTOR inspector, void *testData, const KICAD_T scanTypes[]) override
Function Visit may be re-implemented for each derived class in order to handle all the types given by...
PCB_LAYER_ID m_BottomLayer
The bottom layer of the via (the top layer is in m_Layer)
Definition: class_track.h:481
virtual unsigned int ViewGetLOD(int aLayer, KIGFX::VIEW *aView) const override
Function ViewGetLOD() Returns the level of detail of the item.
TRACK * GetEndNetCode(int NetCode)
#define TRACK_LOCKED
Pcbnew: track locked: protected from global deletion.
Definition: base_struct.h:142
virtual void Move(const wxPoint &aMoveVector) override
Function Move move this object.
Definition: class_track.h:101
void SetLayerPair(PCB_LAYER_ID aTopLayer, PCB_LAYER_ID aBottomLayer)
Function SetLayerPair For a via m_Layer contains the top layer, the other layer is in m_BottomLayer...
#define UNDEFINED_DRILL_DIAMETER
Definition: class_track.h:58
virtual int GetClearance(BOARD_CONNECTED_ITEM *aItem=NULL) const override
Function GetClearance returns the clearance in internal units.
void TransformShapeWithClearanceToPolygon(SHAPE_POLY_SET &aCornerBuffer, int aClearanceValue, int aCircleToSegmentsCount, double aCorrectionFactor) const
Function TransformShapeWithClearanceToPolygon Convert the track shape to a closed polygon Used in fil...
virtual wxString GetSelectMenuText() const override
Function GetSelectMenuText returns the text to display to be used in the selection clarification cont...
SEGZONE(BOARD_ITEM *aParent)
void Draw(EDA_DRAW_PANEL *panel, wxDC *DC, GR_DRAWMODE aDrawMode, const wxPoint &aOffset=ZeroOffset) override
Function Draw BOARD_ITEMs have their own color information.
void SetDrillDefault()
Function SetDrillDefault sets the drill value for vias to the default value UNDEFINED_DRILL_DIAMETER...
Definition: class_track.h:468
void LayerPair(PCB_LAYER_ID *top_layer, PCB_LAYER_ID *bottom_layer) const
Function LayerPair Return the 2 layers used by the via (the via actually uses all layers between thes...
void Draw(EDA_DRAW_PANEL *panel, wxDC *DC, GR_DRAWMODE aDrawMode, const wxPoint &aOffset=ZeroOffset) override
Function Draw BOARD_ITEMs have their own color information.
wxString GetSelectMenuText() const override
Function GetSelectMenuText returns the text to display to be used in the selection clarification cont...
void Draw(EDA_DRAW_PANEL *panel, wxDC *DC, GR_DRAWMODE aDrawMode, const wxPoint &aOffset=ZeroOffset) override
Function Draw BOARD_ITEMs have their own color information.
virtual void ViewGetLayers(int aLayers[], int &aCount) const override
Function ViewGetLayers() Returns the all the layers within the VIEW the object is painted on...
wxString ShowWidth() const
Function ShowWidth returns the width of the track in displayable user units.
TRACK * GetBestInsertPoint(BOARD *aPcb)
Function GetBestInsertPoint searches the "best" insertion point within the track linked list...
BITMAP_DEF GetMenuImage() const override
Function GetMenuImage returns a pointer to an image to be used in menus.
wxString GetClass() const override
Function GetClass returns the class name.
Definition: class_track.h:418
TRACK * Next() const
Definition: class_track.h:98
void SetState(int type, int state)
Definition: base_struct.h:256
EDA_ITEM * Clone() const override
Function Clone creates a duplicate of this item with linked list members set to NULL.
TRACK * GetStartNetCode(int NetCode)
void SetBack(EDA_ITEM *aBack)
Definition: class_track.h:341
int GetDrillValue() const
Function GetDrillValue "calculates" the drill value for vias (m-Drill if > 0, or default drill value ...
Class BOARD holds information pertinent to a Pcbnew printed circuit board.
Definition: class_board.h:169
void GetMsgPanelInfoBase_Common(std::vector< MSG_PANEL_ITEM > &aList)
Helper function for the common panel info.
int GetWidth() const
Definition: class_track.h:115
void SetPosition(const wxPoint &aPos) override
Definition: class_track.h:111
Class EDA_RECT handles the component boundary box.
void SetDrill(int aDrill)
Function SetDrill sets the drill value for vias.
Definition: class_track.h:447
Class EDA_ITEM is a base class for most all the KiCad significant classes, used in schematics and boa...
Definition: base_struct.h:165
const wxPoint & GetPosition() const override
Definition: class_track.h:411
virtual void GetMsgPanelInfoBase(std::vector< MSG_PANEL_ITEM > &aList)
Function GetMsgPanelInfoBase Display info about the track segment only, and does not calculate the fu...
double GetLength() const
Function GetLength returns the length of the track using the hypotenuse calculation.
Definition: class_track.h:171
void SetStart(const wxPoint &aStart)
Definition: class_track.h:120
class VIA, a via (like a track segment on a copper layer)
Definition: typeinfo.h:108
TRACK(BOARD_ITEM *aParent, KICAD_T idtype=PCB_TRACE_T)
Definition: class_track.cpp:95
bool IsOnLayer(PCB_LAYER_ID aLayer) const override
Function IsOnLayer tests to see if this object is on the given layer.
Class EDA_MSG_ITEM is used EDA_MSG_PANEL as the item type for displaying messages.
Definition: msgpanel.h:53
Class VIEW.
Definition: view.h:58
void SetNext(EDA_ITEM *aNext)
Definition: class_track.h:340
SEARCH_RESULT
Definition: base_struct.h:82
BOARD_CONNECTED_ITEM * end
Definition: class_track.h:90
virtual void GetMsgPanelInfoBase(std::vector< MSG_PANEL_ITEM > &aList) override
Function GetMsgPanelInfoBase Display info about the track segment only, and does not calculate the fu...
BOARD_CONNECTED_ITEM * start
Definition: class_track.h:89
EDA_ITEM * Pnext
next in linked list
Definition: base_struct.h:178
bool IsDrillDefault() const
Function IsDrillDefault.
Definition: class_track.h:474
EDA_ITEM * Clone() const override
Function Clone creates a duplicate of this item with linked list members set to NULL.
TRACK * GetFirstTrack(TRACK *aTrk, const TRACK *aStopPoint=NULL)
Scan a track list for the first TRACK object. Returns NULL if not found (or NULL passed) ...
Definition: class_track.h:504
Class COLOR4D is the color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:39
wxString GetClass() const override
Function GetClass returns the class name.
Definition: class_track.h:277
VIA * GetFirstVia(TRACK *aTrk, const TRACK *aStopPoint=NULL)
Scan a track list for the first VIA o NULL if not found (or NULL passed)
Definition: class_track.h:490