Commit 506a73c3 authored by stambaughw's avatar stambaughw
Browse files

More comment translation work.

* Translate source files D through L in pcbnew.
* Add translate tag for comments that did not translate correctly.
parent ab66f9ec
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -902,7 +902,7 @@ float WinEDA_PcbFrame::Compute_Ratsnest_PlaceModule( wxDC* DC )
/* Draw keep out area of a module. */
/***********************************/

/* ???
/* TRANSLATE
 * les cellules ( du plan des Distances ) du rectangle x0,y0 a x1,y1 sont
 *  incrementees de la valeur Penalite
 *  celles qui sont externes au rectangle, mais internes au rectangle
+1 −1
Original line number Diff line number Diff line
@@ -344,7 +344,7 @@ int Build_Work( BOARD* Pcb )
    for( unsigned ii = 0; ii < Pcb->GetRatsnestsCount(); ii++ )
    {
        pt_rats = &Pcb->m_FullRatsnest[ii];
        /* ??? On ne route que les chevelus actifs et routables */
        /* TRANSLATE On ne route que les chevelus actifs et routables */
        if( (pt_rats->m_Status & CH_ACTIF) == 0 )
            continue;
        if( pt_rats->m_Status & CH_UNROUTABLE )
+55 −58
Original line number Diff line number Diff line
/*********************************************/
/* Edition des pistes: Routines d'effacement */
/* Effacement de segment, piste, net et zone */
/*********************************************/

/******************************************/
/* Edit Track: Erase Routines             */
/* Delete segments, tracks, and net areas */
/******************************************/
#include "fctsys.h"

#include "common.h"
@@ -14,16 +13,12 @@
#include "protos.h"


/***************************************************************/
TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
/***************************************************************/

/* Supprime 1 segment de piste.
 *  2 Cas possibles:
 *  Si On est en trace de nouvelle piste: Effacement du segment en
 *      cours de trace
 *  Sinon : Effacment du segment sous le curseur.
/* Removes 1 segment of track.
 * 2 cases:
 * If There is evidence of new track: delete new segment.
 * Otherwise, delete segment under the cursor.
 */
TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
{
    int current_net_code;

@@ -36,7 +31,8 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
        return NULL;
    }

    if( aTrack->m_Flags & IS_NEW )  // Trace in progress, erase the last segment
    if( aTrack->m_Flags & IS_NEW )  // Trace in progress, erase the last
                                    // segment
    {
        if( g_CurrentTrackList.GetCount() > 0 )
        {
@@ -44,7 +40,7 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )

            D( g_CurrentTrackList.VerifyListIntegrity(); )

            // effacement de la piste en cours
            // Delete the current trace
            ShowNewTrackWhenMovingCursor( DrawPanel, DC, FALSE );

            // delete the most recently entered
@@ -52,8 +48,9 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )

            if( g_TwoSegmentTrackBuild )
            {
                // if in 2 track mode, and the next most recent is a segment not a via,
                // and the one previous to that is a via, then delete up to the via.
                // if in 2 track mode, and the next most recent is a segment
                // not a via, and the one previous to that is a via, then
                // delete up to the via.
                if( g_CurrentTrackList.GetCount() >= 2
                    && g_CurrentTrackSegment->Type() != TYPE_VIA
                    && g_CurrentTrackSegment->Back()->Type() == TYPE_VIA )
@@ -62,22 +59,26 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
                }
            }

            while( g_CurrentTrackSegment && g_CurrentTrackSegment->Type() == TYPE_VIA )
            while( g_CurrentTrackSegment && g_CurrentTrackSegment->Type() ==
                   TYPE_VIA )
            {
                delete g_CurrentTrackList.PopBack();

                if( g_CurrentTrackSegment && g_CurrentTrackSegment->Type() != TYPE_VIA )
                if( g_CurrentTrackSegment && g_CurrentTrackSegment->Type() !=
                    TYPE_VIA )
                    previous_layer = g_CurrentTrackSegment->GetLayer();
            }

            // Rectification couche active qui a pu changer si une via
            // a ete effacee
            // Correct active layer which could change if a via
            // has been erased
            ( (PCB_SCREEN*) GetScreen() )->m_Active_Layer = previous_layer;

            UpdateStatusBar();
            if( g_TwoSegmentTrackBuild )   // We must have 2 segments or more, or 0
            if( g_TwoSegmentTrackBuild )   // We must have 2 segments or more,
                                           // or 0
            {
                if( g_CurrentTrackList.GetCount()==1 && g_CurrentTrackSegment->Type() != TYPE_VIA )
                if( g_CurrentTrackList.GetCount() == 1
                    && g_CurrentTrackSegment->Type() != TYPE_VIA )
                {
                    delete g_CurrentTrackList.PopBack();
                }
@@ -110,6 +111,7 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
    DLIST<TRACK>* container = (DLIST<TRACK>*)aTrack->GetList();
    wxASSERT( container );
    container->Remove( aTrack );

    // redraw the area where the track was
    DrawPanel->PostDirtyRect( aTrack->GetBoundingBox() );

@@ -122,9 +124,7 @@ TRACK* WinEDA_PcbFrame::Delete_Segment( wxDC* DC, TRACK* aTrack )
}


/**********************************************************/
void WinEDA_PcbFrame::Delete_Track( wxDC* DC, TRACK* aTrack )
/**********************************************************/
{
    if( aTrack != NULL )
    {
@@ -136,9 +136,7 @@ void WinEDA_PcbFrame::Delete_Track( wxDC* DC, TRACK* aTrack )
}


/********************************************************/
void WinEDA_PcbFrame::Delete_net( wxDC* DC, TRACK* aTrack )
/********************************************************/
{
    if( aTrack == NULL )
        return;
@@ -163,6 +161,7 @@ void WinEDA_PcbFrame::Delete_net( wxDC* DC, TRACK* aTrack )
            break;

        GetBoard()->m_Track.Remove( segm );

        // redraw the area where the track was
        DrawPanel->PostDirtyRect( segm->GetBoundingBox() );
        picker.m_PickedItem     = segm;
@@ -174,25 +173,22 @@ void WinEDA_PcbFrame::Delete_net( wxDC* DC, TRACK* aTrack )
    GetScreen()->SetModify();
    test_1_net_connexion( DC, net_code_delete );
    GetBoard()->DisplayInfo( this );

}


/********************************************************************/
void WinEDA_PcbFrame::Remove_One_Track( wxDC* DC, TRACK* pt_segm )
/********************************************************************/

/* Routine de suppression de 1 piste:
 *  le segment pointe est supprime puis les segments adjacents
 *  jusqu'a un pad ou un point de jonction de plus de 2 segments
/* Remove 1 track:
 * The leading segment is removed and all adjacent segments
 * until a pad or a junction point of more than 2 segments is found
 */
void WinEDA_PcbFrame::Remove_One_Track( wxDC* DC, TRACK* pt_segm )
{
    int segments_to_delete_count;

    if( pt_segm == NULL )
        return;

    TRACK*  trackList = Marque_Une_Piste( GetBoard(), pt_segm, &segments_to_delete_count, NULL, true );
    TRACK* trackList = Marque_Une_Piste( GetBoard(), pt_segm,
                                         &segments_to_delete_count, NULL, true );
    if( segments_to_delete_count == 0 )
        return;

@@ -213,6 +209,7 @@ void WinEDA_PcbFrame::Remove_One_Track( wxDC* DC, TRACK* pt_segm )
                   ); )

        GetBoard()->m_Track.Remove( tracksegment );

        // redraw the area where the track was
        DrawPanel->PostDirtyRect( tracksegment->GetBoundingBox() );
        picker.m_PickedItem     = tracksegment;
+47 −55
Original line number Diff line number Diff line
/////////////////////////////////////////////////////////////////////////////

// Name:        dialog_svg_print.cpp
// Author:      jean-pierre Charras
// Modified by:
@@ -56,16 +55,15 @@ private:
    void OnSetColorModeSelected( wxCommandEvent& event );
    void SetPenWidth();
    void PrintSVGDoc( bool aPrintAll, bool aPrint_Framet_Ref );
    bool DrawPage( const wxString& FullFileName, BASE_SCREEN* screen, bool aPrint_Framet_Ref );
    bool DrawPage( const wxString& FullFileName, BASE_SCREEN* screen,
                   bool aPrint_Framet_Ref );
};

/*******************************************************/
void WinEDA_DrawFrame::SVG_Print( wxCommandEvent& event )
/*******************************************************/

/* Prepare les structures de donnees de gestion de l'impression
 * et affiche la fenetre de dialogue de gestion de l'impression des feuilles
/* Prepare the data structures of print management
 * And displays the dialog window management of printing sheets
 */
void WinEDA_DrawFrame::SVG_Print( wxCommandEvent& event )
{
    DIALOG_SVG_PRINT frame( this );

@@ -84,9 +82,7 @@ DIALOG_SVG_PRINT::DIALOG_SVG_PRINT( WinEDA_DrawFrame* parent ) :
}


/*************************************************************/
void DIALOG_SVG_PRINT::OnInitDialog( wxInitDialogEvent& event )
/*************************************************************/
{
    SetFocus();     // Make ESC key working

@@ -99,7 +95,8 @@ void DIALOG_SVG_PRINT::OnInitDialog( wxInitDialogEvent& event )

    AddUnitSymbol( *m_TextPenWidth, g_UnitMetric );
    m_DialogPenWidth->SetValue(
        ReturnStringFromValue( g_UnitMetric, s_PrintPenMinWidth, m_Parent->m_InternalUnits ) );
        ReturnStringFromValue( g_UnitMetric, s_PrintPenMinWidth,
                               m_Parent->m_InternalUnits ) );

    m_Print_Frame_Ref_Ctrl->SetValue( s_Print_Frame_Ref );

@@ -108,15 +105,22 @@ void DIALOG_SVG_PRINT::OnInitDialog( wxInitDialogEvent& event )
    int    mask  = 1;
    for( int layer = 0; layer<NB_LAYERS; layer++, mask <<= 1 )
    {
        m_BoxSelectLayer[layer] = new  wxCheckBox( this, -1, board->GetLayerName( layer ) );
        m_BoxSelectLayer[layer] =
            new  wxCheckBox( this, -1, board->GetLayerName( layer ) );

        if( mask & s_SelectedLayers )
            m_BoxSelectLayer[layer]->SetValue( true );

        if( layer < 16 )
            m_CopperLayersBoxSizer->Add(  m_BoxSelectLayer[layer], 0, wxGROW | wxALL, 1 );
            m_CopperLayersBoxSizer->Add(  m_BoxSelectLayer[layer],
                                          0,
                                          wxGROW | wxALL,
                                          1 );
        else
            m_TechnicalBoxSizer->Add(  m_BoxSelectLayer[layer], 0, wxGROW | wxALL, 1 );
            m_TechnicalBoxSizer->Add(  m_BoxSelectLayer[layer],
                                       0,
                                       wxGROW | wxALL,
                                       1 );
    }

    if( m_Config )
@@ -141,11 +145,10 @@ void DIALOG_SVG_PRINT::OnInitDialog( wxInitDialogEvent& event )
}


/***********************************/
void DIALOG_SVG_PRINT::SetPenWidth()
/***********************************/
{
    s_PrintPenMinWidth = ReturnValueFromTextCtrl( *m_DialogPenWidth, m_Parent->m_InternalUnits );
    s_PrintPenMinWidth = ReturnValueFromTextCtrl( *m_DialogPenWidth,
                                                  m_Parent->m_InternalUnits );

    if( s_PrintPenMinWidth > WIDTH_MAX_VALUE )
    {
@@ -158,13 +161,12 @@ void DIALOG_SVG_PRINT::SetPenWidth()
    }

    m_DialogPenWidth->SetValue(
        ReturnStringFromValue( g_UnitMetric, s_PrintPenMinWidth, m_Parent->m_InternalUnits ) );
        ReturnStringFromValue( g_UnitMetric, s_PrintPenMinWidth,
                               m_Parent->m_InternalUnits ) );
}


/***************************************************************************/
void DIALOG_SVG_PRINT::PrintSVGDoc( bool aPrintAll, bool aPrint_Framet_Ref )
/***************************************************************************/
{
    wxFileName fn;
    wxString   msg;
@@ -197,7 +199,6 @@ void DIALOG_SVG_PRINT::PrintSVGDoc( bool aPrintAll, bool aPrint_Framet_Ref )
            m_PrintMaskLayer = 1 << layer;
            if( m_PrintBoardEdgesCtrl->IsChecked() )
                m_PrintMaskLayer |= EDGE_LAYER;

        }

        fn.SetExt( wxT( "svg" ) );
@@ -215,14 +216,12 @@ void DIALOG_SVG_PRINT::PrintSVGDoc( bool aPrintAll, bool aPrint_Framet_Ref )
}


/**********************************************************************************/
bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName, BASE_SCREEN* screen,
                                 bool aPrint_Framet_Ref )
/***********************************************************************************/

/*
 * Routine effective d'impression
 * Routine actual print
 */
bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName,
                                 BASE_SCREEN*    screen,
                                 bool            aPrint_Framet_Ref )
{
    int     tmpzoom;
    wxPoint tmp_startvisu;
@@ -231,7 +230,7 @@ bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName, BASE_SCREEN* scre
    float   dpi;
    bool    success = true;

    /* modification des cadrages et reglages locaux */
    /* Change frames and local settings */
    tmp_startvisu = screen->m_StartVisu;
    tmpzoom = screen->GetZoom();
    old_org = screen->m_DrawOrg;
@@ -250,16 +249,20 @@ bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName, BASE_SCREEN* scre

    EDA_Rect          tmp = panel->m_ClipBox;
    GRResetPenAndBrush( &dc );
    s_PrintPenMinWidth = ReturnValueFromTextCtrl( *m_DialogPenWidth, m_Parent->m_InternalUnits );
    s_PrintPenMinWidth = ReturnValueFromTextCtrl( *m_DialogPenWidth,
                                                  m_Parent->m_InternalUnits );
    SetPenMinWidth( s_PrintPenMinWidth );
    GRForceBlackPen( m_ModeColorOption->GetSelection() == 0 ? FALSE : true );


    panel->m_ClipBox.SetX( 0 ); panel->m_ClipBox.SetY( 0 );
    panel->m_ClipBox.SetWidth( 0x7FFFFF0 ); panel->m_ClipBox.SetHeight( 0x7FFFFF0 );
    panel->m_ClipBox.SetWidth( 0x7FFFFF0 ); panel->m_ClipBox.SetHeight(
        0x7FFFFF0 );

    screen->m_IsPrinting = true;
    SetLocaleTo_C_standard();       // Switch the locale to standard C (needed to print floating point numbers like 1.3)
    SetLocaleTo_C_standard();       // Switch the locale to standard C (needed
                                    // to print floating point numbers like
                                    // 1.3)
    panel->PrintPage( &dc, aPrint_Framet_Ref, m_PrintMaskLayer, false );
    SetLocaleTo_Default();          // revert to the current  locale
    screen->m_IsPrinting = false;
@@ -276,35 +279,27 @@ bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName, BASE_SCREEN* scre
}


/********************************************************************/
void DIALOG_SVG_PRINT::OnButtonPrintBoardClick( wxCommandEvent& event )
/********************************************************************/
{
    s_Print_Frame_Ref = m_Print_Frame_Ref_Ctrl->IsChecked();
    PrintSVGDoc( true, s_Print_Frame_Ref );
}


/********************************************************************/
void DIALOG_SVG_PRINT::OnButtonPrintSelectedClick( wxCommandEvent& event )
/********************************************************************/
{
    s_Print_Frame_Ref = m_Print_Frame_Ref_Ctrl->IsChecked();
    PrintSVGDoc( false, s_Print_Frame_Ref );
}


/******************************************************************/
void DIALOG_SVG_PRINT::OnButtonCancelClick( wxCommandEvent& event )
/******************************************************************/
{
    Close();
}


/***********************************************************/
void DIALOG_SVG_PRINT::OnCloseWindow( wxCloseEvent& event )
/***********************************************************/
{
    SetPenWidth();
    s_PlotBlackAndWhite = m_ModeColorOption->GetSelection();
@@ -323,12 +318,9 @@ void DIALOG_SVG_PRINT::OnCloseWindow( wxCloseEvent& event )
}


/*********************************************************************/
void DIALOG_SVG_PRINT::OnSetColorModeSelected( wxCommandEvent& event )
/*********************************************************************/

/* called on radiobox color/black and white selection
 */
void DIALOG_SVG_PRINT::OnSetColorModeSelected( wxCommandEvent& event )
{
    s_PlotBlackAndWhite = m_ModeColorOption->GetSelection();
}
+77 −79

File changed.

Preview size limit exceeded, changes collapsed.

Loading