Fix Eeschema BW printing
Checks forced state when printing to convert images to grayscale.
This commit is contained in:
parent
195c3d074b
commit
4ebb87d1c1
|
@ -266,9 +266,18 @@ void BITMAP_BASE::DrawBitmap( wxDC* aDC, const wxPoint& aPos )
|
|||
pos.y = KiROUND( pos.y / GetScalingFactor() );
|
||||
size.x = KiROUND( size.x / GetScalingFactor() );
|
||||
size.y = KiROUND( size.y / GetScalingFactor() );
|
||||
|
||||
aDC->SetClippingRegion( pos, size );
|
||||
|
||||
if( GetGRForceBlackPenState() )
|
||||
{
|
||||
wxBitmap result( m_bitmap->ConvertToImage().ConvertToGreyscale() );
|
||||
aDC->DrawBitmap( result, pos.x, pos.y, true );
|
||||
}
|
||||
else
|
||||
{
|
||||
aDC->DrawBitmap( *m_bitmap, pos.x, pos.y, true );
|
||||
}
|
||||
|
||||
aDC->DestroyClippingRegion();
|
||||
aDC->SetUserScale( scale, scale );
|
||||
aDC->SetLogicalOrigin( logicalOriginX, logicalOriginY );
|
||||
|
|
Loading…
Reference in New Issue