24#include <math/vector2d.h>
26#include <geometry/shape_arc.h>
27#include <geometry/shape_line_chain.h>
30#include "pns_linked_item.h"
54 m_net = aParentArc.Net();
55 m_layers = aParentArc.Layers();
56 m_marker = aParentArc.Marker();
57 m_rank = aParentArc.Rank();
62 m_arc( aArc.GetP0(), aArc.GetArcMid(), aArc.GetP1(), aParentLine.
Width() )
64 m_net = aParentLine.Net();
65 m_layers = aParentLine.Layers();
66 m_marker = aParentLine.Marker();
67 m_rank = aParentLine.Rank();
70 static inline bool ClassOf(
const ITEM* aItem )
72 return aItem && ARC_T == aItem->
Kind();
79 return static_cast<const SHAPE*
>( &m_arc );
82 void SetWidth(
int aWidth )
override
84 m_arc.SetWidth(aWidth);
87 int Width()
const override
89 return m_arc.GetWidth();
97 const SHAPE_LINE_CHAIN Hull(
int aClearance,
int aWalkaroundThickness,
int aLayer )
const override;
99 virtual VECTOR2I Anchor(
int n )
const override
102 return m_arc.GetP0();
104 return m_arc.GetP1();
107 virtual int AnchorCount()
const override
112 OPT_BOX2I ChangedArea(
const ARC* aOther )
const;
115 const SHAPE_ARC& CArc()
const {
return m_arc; }
const SHAPE * Shape() const override
Return the geometrical shape of the item.
Definition pns_arc.h:77
ARC * Clone() const override
Return a deep copy of the item.
Definition pns_arc.cpp:34
Base class for PNS router board items.
Definition pns_item.h:57
PnsKind Kind() const
Return the type (kind) of the item.
Definition pns_item.h:131
Represents a track on a PCB, connecting two non-trivial joints (that is, vias, pads,...
Definition pns_line.h:61
int Width() const
Return true if the line is geometrically identical as line aOther.
Definition pns_line.h:156
Definition pns_linked_item.h:30
Definition shape_arc.h:36
Represent a polyline containing arcs as well as line segments: A chain of connected line and/or arc s...
Definition shape_line_chain.h:81
An abstract shape on 2D plane.
Definition shape.h:117