Don't truncate values on import
Leads to off-by-one errors when converting to internal values Fixes https://gitlab.com/kicad/code/kicad/issues/9827
This commit is contained in:
parent
b729068326
commit
c4a6a61743
|
@ -45,7 +45,7 @@ GRAPHICS_IMPORTER_PCBNEW::GRAPHICS_IMPORTER_PCBNEW()
|
|||
wxPoint GRAPHICS_IMPORTER_PCBNEW::MapCoordinate( const VECTOR2D& aCoordinate )
|
||||
{
|
||||
VECTOR2D coord = ( aCoordinate + GetImportOffsetMM() ) * ImportScalingFactor();
|
||||
return wxPoint( (int) coord.x, (int) coord.y );
|
||||
return wxPoint( KiROUND( coord.x ), KiROUND( coord.y ) );
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue