diff --git a/pcbnew/plugins/eagle/eagle_plugin.cpp b/pcbnew/plugins/eagle/eagle_plugin.cpp index 5d307c8822..55b56cfc19 100644 --- a/pcbnew/plugins/eagle/eagle_plugin.cpp +++ b/pcbnew/plugins/eagle/eagle_plugin.cpp @@ -1572,6 +1572,10 @@ void EAGLE_PLUGIN::orientFPText( FOOTPRINT* aFootprint, const EELEMENT& e, FP_TE // Even though size and ratio are both optional, I am not seeing // a case where ratio is present but size is not. double ratio = 8; + + if( a.ratio ) + ratio = *a.ratio; + wxSize fontz = aFPText->GetTextSize(); int textThickness = KiROUND( fontz.y * ratio / 100 ); @@ -1580,13 +1584,9 @@ void EAGLE_PLUGIN::orientFPText( FOOTPRINT* aFootprint, const EELEMENT& e, FP_TE { fontz = kicad_fontz( *a.size, textThickness ); aFPText->SetTextSize( fontz ); - - if( a.ratio ) - ratio = *a.ratio; } - int align = ETEXT::BOTTOM_LEFT; // bottom-left is eagle default if( a.align )