Commit 70ca712c authored by jean-pierre charras's avatar jean-pierre charras

Pcbvew: fix a strange bug which swap x and y values for pad offsets when...

Pcbvew: fix a strange bug which swap x and y values for pad offsets when reading a s expr *.kicad_pcb board file.
parent 6ad94a49
...@@ -205,8 +205,11 @@ TEXTE_PCB* PCB_EDIT_FRAME::CreateTextePcb( wxDC* aDC, TEXTE_PCB* aText ) ...@@ -205,8 +205,11 @@ TEXTE_PCB* PCB_EDIT_FRAME::CreateTextePcb( wxDC* aDC, TEXTE_PCB* aText )
int layer = ( (PCB_SCREEN*) GetScreen() )->m_Active_Layer; int layer = ( (PCB_SCREEN*) GetScreen() )->m_Active_Layer;
textePcb->SetLayer( layer ); textePcb->SetLayer( layer );
if( layer == LAYER_N_BACK // Set the mirrored option for layers on the BACK side of the board
|| layer == SILKSCREEN_N_BACK ) if( layer == LAYER_N_BACK || layer == SILKSCREEN_N_BACK ||
layer == SOLDERPASTE_N_BACK || layer == SOLDERMASK_N_FRONT ||
layer == ADHESIVE_N_BACK
)
textePcb->SetMirrored( true ); textePcb->SetMirrored( true );
textePcb->SetSize( GetBoard()->GetDesignSettings().m_PcbTextSize ); textePcb->SetSize( GetBoard()->GetDesignSettings().m_PcbTextSize );
......
...@@ -2117,8 +2117,9 @@ D_PAD* PCB_PARSER::parseD_PAD() throw( IO_ERROR, PARSE_ERROR ) ...@@ -2117,8 +2117,9 @@ D_PAD* PCB_PARSER::parseD_PAD() throw( IO_ERROR, PARSE_ERROR )
} }
case T_offset: case T_offset:
pad->SetOffset( wxPoint( parseBoardUnits( "drill offset x" ), pt.x = parseBoardUnits( "drill offset x" );
parseBoardUnits( "drill offset y" ) ) ); pt.y = parseBoardUnits( "drill offset y" );
pad->SetOffset( pt );
NeedRIGHT(); NeedRIGHT();
break; break;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment