SCH_EDIT_FRAME::DrawCurrentSheetToClipboard(): fix missing init of worksheet color.

This commit is contained in:
jean-pierre charras 2021-04-12 18:15:30 +02:00
parent a4c08e2af6
commit 929e535f0c
1 changed files with 4 additions and 1 deletions

View File

@ -2,7 +2,7 @@
* This program source code file is part of KiCad, a free EDA CAD application.
*
* Copyright (C) 2015 Jean-Pierre Charras, jp.charras at wanadoo.fr
* Copyright (C) 2004-2020 KiCad Developers, see change_log.txt for contributors.
* Copyright (C) 2004-2021 KiCad Developers, see AUTHORS.txt for contributors.
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
@ -525,6 +525,9 @@ void SCH_EDIT_FRAME::DrawCurrentSheetToClipboard()
dc.SetUserScale( scale, scale );
GetRenderSettings()->SetPrintDC( &dc );
// Init the color of the layer actually used to print the worksheet:
GetRenderSettings()->SetLayerColor( LAYER_DRAWINGSHEET,
GetRenderSettings()->GetLayerColor( LAYER_SCHEMATIC_DRAWINGSHEET ) );
PrintPage( GetRenderSettings() );