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

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
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
@@ -205,8 +205,11 @@ TEXTE_PCB* PCB_EDIT_FRAME::CreateTextePcb( wxDC* aDC, TEXTE_PCB* aText )
        int layer = ( (PCB_SCREEN*) GetScreen() )->m_Active_Layer;
        textePcb->SetLayer( layer );

        if( layer == LAYER_N_BACK
            || layer == SILKSCREEN_N_BACK )
        // Set the mirrored option for layers on the BACK side of the board
        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->SetSize( GetBoard()->GetDesignSettings().m_PcbTextSize );
+3 −2
Original line number Diff line number Diff line
@@ -2117,8 +2117,9 @@ D_PAD* PCB_PARSER::parseD_PAD() throw( IO_ERROR, PARSE_ERROR )
                }

                case T_offset:
                    pad->SetOffset( wxPoint( parseBoardUnits( "drill offset x" ),
                                             parseBoardUnits( "drill offset y" ) ) );
                    pt.x = parseBoardUnits( "drill offset x" );
                    pt.y = parseBoardUnits( "drill offset y" );
                    pad->SetOffset( pt );
                    NeedRIGHT();
                    break;