pcbnew: Fix DXF units in drill map plotting

Fixes: lp:1836924
* https://bugs.launchpad.net/kicad/+bug/1836924
This commit is contained in:
Ian McInerney 2019-07-27 23:35:38 +02:00 committed by Wayne Stambaugh
parent 300fb43a38
commit 6c401ecce7
1 changed files with 6 additions and 0 deletions

View File

@ -144,6 +144,12 @@ bool GENDRILL_WRITER_BASE::genDrillMapFile( const wxString& aFullFileName,
case PLOT_FORMAT_DXF:
{
DXF_PLOTTER* dxf_plotter = new DXF_PLOTTER;
if( m_unitsMetric )
dxf_plotter->SetUnits( DXF_PLOTTER::DXF_UNIT_MILLIMETERS );
else
dxf_plotter->SetUnits( DXF_PLOTTER::DXF_UNIT_INCHES );
plotter = dxf_plotter;
plotter->SetPageSettings( page_info );
plotter->SetViewport( offset, IU_PER_MILS/10, scale, false );