Fix up merge errors.
This commit is contained in:
parent
7113f1f879
commit
e59d8b0a2d
|
@ -827,34 +827,35 @@ void PCB_PAINTER::draw( const PCB_VIA* aVia, int aLayer )
|
||||||
default: wxASSERT( false ); break;
|
default: wxASSERT( false ); break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if( sketchMode )
|
m_gal->SetStrokeColor( color );
|
||||||
{
|
m_gal->SetFillColor( color );
|
||||||
// Outline mode
|
|
||||||
m_gal->SetIsStroke( true );
|
m_gal->SetIsStroke( true );
|
||||||
m_gal->SetIsFill( false );
|
m_gal->SetIsFill( false );
|
||||||
|
|
||||||
|
if( sketchMode )
|
||||||
m_gal->SetLineWidth( m_pcbSettings.m_outlineWidth );
|
m_gal->SetLineWidth( m_pcbSettings.m_outlineWidth );
|
||||||
m_gal->SetStrokeColor( color );
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
// Filled mode
|
|
||||||
m_gal->SetIsFill( true );
|
|
||||||
m_gal->SetIsStroke( false );
|
|
||||||
m_gal->SetFillColor( color );
|
|
||||||
}
|
|
||||||
|
|
||||||
if( aLayer == LAYER_VIA_HOLES )
|
if( aLayer == LAYER_VIA_HOLES )
|
||||||
{
|
{
|
||||||
|
m_gal->SetIsStroke( false );
|
||||||
|
m_gal->SetIsFill( true );
|
||||||
m_gal->DrawCircle( center, getDrillSize( aVia ) / 2.0 );
|
m_gal->DrawCircle( center, getDrillSize( aVia ) / 2.0 );
|
||||||
}
|
}
|
||||||
else if( aLayer == LAYER_VIA_THROUGH || m_pcbSettings.IsPrinting() )
|
else if( aLayer == LAYER_VIA_THROUGH || m_pcbSettings.IsPrinting() )
|
||||||
{
|
{
|
||||||
|
int annular_width = ( aVia->GetWidth() - getDrillSize( aVia ) ) / 2.0;
|
||||||
double radius = aVia->GetWidth() / 2.0;
|
double radius = aVia->GetWidth() / 2.0;
|
||||||
bool draw = aLayer == LAYER_VIA_THROUGH;
|
bool draw = aLayer == LAYER_VIA_THROUGH;
|
||||||
|
|
||||||
if( m_pcbSettings.IsPrinting() )
|
if( m_pcbSettings.IsPrinting() )
|
||||||
draw = aVia->FlashLayer( m_pcbSettings.GetPrintLayers() );
|
draw = aVia->FlashLayer( m_pcbSettings.GetPrintLayers() );
|
||||||
|
|
||||||
|
if( !sketchMode )
|
||||||
|
{
|
||||||
|
m_gal->SetLineWidth( annular_width );
|
||||||
|
radius -= annular_width / 2.0;
|
||||||
|
}
|
||||||
|
|
||||||
if( draw )
|
if( draw )
|
||||||
m_gal->DrawCircle( center, radius );
|
m_gal->DrawCircle( center, radius );
|
||||||
}
|
}
|
||||||
|
@ -868,7 +869,11 @@ void PCB_PAINTER::draw( const PCB_VIA* aVia, int aLayer )
|
||||||
double radius = aVia->GetWidth() / 2.0;
|
double radius = aVia->GetWidth() / 2.0;
|
||||||
|
|
||||||
if( !sketchMode )
|
if( !sketchMode )
|
||||||
|
{
|
||||||
|
m_gal->SetIsFill( true );
|
||||||
|
m_gal->SetIsStroke( false );
|
||||||
m_gal->SetLineWidth( ( aVia->GetWidth() - aVia->GetDrillValue() ) / 2.0 );
|
m_gal->SetLineWidth( ( aVia->GetWidth() - aVia->GetDrillValue() ) / 2.0 );
|
||||||
|
}
|
||||||
|
|
||||||
m_gal->DrawArc( center, radius, M_PI * -0.375, M_PI * 0.375 );
|
m_gal->DrawArc( center, radius, M_PI * -0.375, M_PI * 0.375 );
|
||||||
m_gal->DrawArc( center, radius, M_PI * 0.625, M_PI * 1.375 );
|
m_gal->DrawArc( center, radius, M_PI * 0.625, M_PI * 1.375 );
|
||||||
|
|
Loading…
Reference in New Issue