PNS: ratlines need to not be debug graphics
Fixes https://gitlab.com/kicad/code/kicad/-/issues/5995
This commit is contained in:
parent
6a3384e764
commit
fd4b9f0efa
|
@ -848,14 +848,10 @@ void DIFF_PAIR_PLACER::updateLeadingRatLine()
|
|||
TOPOLOGY topo( m_lastNode );
|
||||
|
||||
if( topo.LeadingRatLine( &m_currentTrace.PLine(), ratLineP ) )
|
||||
{
|
||||
Dbg()->AddLine( ratLineP, 1, 10000 );
|
||||
}
|
||||
m_router->GetInterface()->DisplayRatline( ratLineP, 1 );
|
||||
|
||||
if( topo.LeadingRatLine ( &m_currentTrace.NLine(), ratLineN ) )
|
||||
{
|
||||
Dbg()->AddLine( ratLineN, 3, 10000 );
|
||||
}
|
||||
m_router->GetInterface()->DisplayRatline( ratLineN, 3 );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -1301,6 +1301,15 @@ void PNS_KICAD_IFACE::DisplayItem( const PNS::ITEM* aItem, int aColor, int aClea
|
|||
}
|
||||
|
||||
|
||||
void PNS_KICAD_IFACE::DisplayRatline( const SHAPE_LINE_CHAIN& aRatline, int aColor )
|
||||
{
|
||||
ROUTER_PREVIEW_ITEM* pitem = new ROUTER_PREVIEW_ITEM( nullptr, m_view );
|
||||
pitem->Line( aRatline, 10000, aColor );
|
||||
m_previewItems->Add( pitem );
|
||||
m_view->Update( m_previewItems );
|
||||
}
|
||||
|
||||
|
||||
void PNS_KICAD_IFACE::HideItem( PNS::ITEM* aItem )
|
||||
{
|
||||
BOARD_CONNECTED_ITEM* parent = aItem->Parent();
|
||||
|
|
|
@ -62,6 +62,7 @@ public:
|
|||
bool IsItemVisible( const PNS::ITEM* aItem ) const override { return true; }
|
||||
void HideItem( PNS::ITEM* aItem ) override {}
|
||||
void DisplayItem( const PNS::ITEM* aItem, int aColor = 0, int aClearance = 0, bool aEdit = false ) override {}
|
||||
void DisplayRatline( const SHAPE_LINE_CHAIN& aRatline, int aColor = -1 ) override {}
|
||||
void AddItem( PNS::ITEM* aItem ) override;
|
||||
void RemoveItem( PNS::ITEM* aItem ) override;
|
||||
void Commit() override {}
|
||||
|
@ -117,6 +118,7 @@ public:
|
|||
bool IsOnLayer( const PNS::ITEM* aItem, int aLayer ) const override;
|
||||
void HideItem( PNS::ITEM* aItem ) override;
|
||||
void DisplayItem( const PNS::ITEM* aItem, int aColor = 0, int aClearance = 0, bool aEdit = false ) override;
|
||||
void DisplayRatline( const SHAPE_LINE_CHAIN& aRatline, int aColor = -1 ) override;
|
||||
void Commit() override;
|
||||
void AddItem( PNS::ITEM* aItem ) override;
|
||||
void RemoveItem( PNS::ITEM* aItem ) override;
|
||||
|
|
|
@ -1367,7 +1367,7 @@ void LINE_PLACER::updateLeadingRatLine()
|
|||
TOPOLOGY topo( m_lastNode );
|
||||
|
||||
if( topo.LeadingRatLine( ¤t, ratLine ) )
|
||||
Dbg()->AddLine( ratLine, 5, 10000 );
|
||||
m_router->GetInterface()->DisplayRatline( ratLine, 5 );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -102,6 +102,7 @@ enum DRAG_MODE
|
|||
virtual bool IsItemVisible( const PNS::ITEM* aItem ) const = 0;
|
||||
virtual bool IsOnLayer( const PNS::ITEM* aItem, int aLayer ) const = 0;
|
||||
virtual void DisplayItem( const ITEM* aItem, int aColor = -1, int aClearance = -1, bool aEdit = false ) = 0;
|
||||
virtual void DisplayRatline( const SHAPE_LINE_CHAIN& aRatline, int aColor = -1 ) = 0;
|
||||
virtual void HideItem( ITEM* aItem ) = 0;
|
||||
virtual void Commit() = 0;
|
||||
virtual bool ImportSizes( SIZES_SETTINGS& aSizes, ITEM* aStartItem, int aNet ) = 0;
|
||||
|
|
Loading…
Reference in New Issue