Use board polygon instead of bbox for size
Board BBox uses the visible size of the board, which includes edge cut
thickness. This is not appropriate for the Board characteristics.
Using the outline polygon gives accurate results and falls back to a
bounding box in the case where the outline is invalid
Fixes https://gitlab.com/kicad/code/kicad/issues/10972
(cherry picked from commit 54f621c570
)
This commit is contained in:
parent
a7ea868282
commit
283aaff2df
|
@ -431,7 +431,9 @@ std::vector<BOARD_ITEM*> DRAWING_TOOL::DrawBoardCharacteristics( const wxPoint&
|
|||
t->SetText( StringFromValue( EDA_UNITS::UNSCALED, settings.GetCopperLayerCount(), false ) );
|
||||
colData1.push_back( t );
|
||||
|
||||
EDA_RECT size = m_frame->GetBoard()->ComputeBoundingBox( true );
|
||||
SHAPE_POLY_SET outline;
|
||||
m_frame->GetBoard()->GetBoardPolygonOutlines( outline );
|
||||
BOX2I size = outline.BBox();
|
||||
t = static_cast<PCB_TEXT*>( dataStyle->Duplicate() );
|
||||
t->SetText( _( "Board overall dimensions: " ) );
|
||||
colLabel1.push_back( t );
|
||||
|
|
Loading…
Reference in New Issue