Increase visibility of polygon preview
This set the polygon preview item to wider size and adjusts the draw
order to ensure it remains visible even when antialiasing
(cherry picked from commit ea1c8525ce
)
This commit is contained in:
parent
2cd43aee0a
commit
5e2721d2f5
|
@ -31,6 +31,7 @@
|
|||
|
||||
using namespace KIGFX::PREVIEW;
|
||||
|
||||
const double POLYGON_ITEM::POLY_LINE_WIDTH = 150000.0;
|
||||
|
||||
POLYGON_ITEM::POLYGON_ITEM():
|
||||
SIMPLE_OVERLAY_ITEM()
|
||||
|
@ -60,12 +61,14 @@ void POLYGON_ITEM::drawPreviewShape( KIGFX::VIEW* aView ) const
|
|||
auto& gal = *aView->GetGAL();
|
||||
auto rs = static_cast<KIGFX::PCB_RENDER_SETTINGS*>( aView->GetPainter()->GetSettings() );
|
||||
|
||||
gal.SetLineWidth( POLY_LINE_WIDTH );
|
||||
gal.DrawPolyline( m_lockedChain );
|
||||
gal.DrawPolygon( m_polyfill );
|
||||
|
||||
// draw the leader line in a different color
|
||||
gal.SetStrokeColor( rs->GetLayerColor( LAYER_AUX_ITEMS ) );
|
||||
gal.DrawPolyline( m_leaderChain );
|
||||
|
||||
gal.DrawPolygon( m_polyfill );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -75,6 +75,8 @@ private:
|
|||
|
||||
///> polygon fill
|
||||
SHAPE_POLY_SET m_polyfill;
|
||||
|
||||
static const double POLY_LINE_WIDTH;
|
||||
};
|
||||
|
||||
} // PREVIEW
|
||||
|
|
Loading…
Reference in New Issue