From baa4019448d2e62d12ff45ffb5bde834287e4e50 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Thu, 18 Oct 2018 13:25:46 +0100 Subject: [PATCH] Draw pin previews with the correct schematic background color. Fixes: lp:1798447 * https://bugs.launchpad.net/kicad/+bug/1798447 --- eeschema/dialogs/dialog_lib_edit_pin.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/eeschema/dialogs/dialog_lib_edit_pin.cpp b/eeschema/dialogs/dialog_lib_edit_pin.cpp index bb5474333a..812d25004a 100644 --- a/eeschema/dialogs/dialog_lib_edit_pin.cpp +++ b/eeschema/dialogs/dialog_lib_edit_pin.cpp @@ -26,7 +26,7 @@ #include #include #include - +#include #include #include #include @@ -53,7 +53,8 @@ DIALOG_LIB_EDIT_PIN::DIALOG_LIB_EDIT_PIN( LIB_EDIT_FRAME* parent, LIB_PIN* aPin m_dummyPin->SetParent( nullptr ); m_dummyPin->ClearFlags(); - m_panelShowPin->SetBackgroundColour( parent->GetDrawBgColor().ToColour() ); + COLOR4D bgColor = parent->GetRenderSettings()->GetLayerColor( LAYER_SCHEMATIC_BACKGROUND ); + m_panelShowPin->SetBackgroundColour( bgColor.ToColour() ); const wxArrayString& orientationNames = LIB_PIN::GetOrientationNames(); const BITMAP_DEF* orientationBitmaps = LIB_PIN::GetOrientationSymbols();