eeschema: Add highlight color to configurable list
The highlight color chosen from the system highlight doesn't always show against the schematic sheet background color. Allowing the user to customize with their KiCad theme makes it configurable on par with other colors. This is stop-gap until we get full color schemes from lp:1678345
This commit is contained in:
parent
ff118c62ec
commit
548dbb7c29
|
@ -220,6 +220,7 @@ static PARAM_CFG_ARRAY& cfg_params()
|
|||
CLR( "Color4DBrightenedEx", LAYER_BRIGHTENED, COLOR4D( PUREMAGENTA ) )
|
||||
CLR( "Color4DHiddenEx", LAYER_HIDDEN, COLOR4D( LIGHTGRAY ) )
|
||||
CLR( "Color4DWorksheetEx", LAYER_WORKSHEET, COLOR4D( RED ) )
|
||||
CLR( "Color4DShadowEx", LAYER_SELECTION_SHADOWS, COLOR4D( .4, .7, 1.0, 0.8 ) )
|
||||
}
|
||||
|
||||
return ca;
|
||||
|
|
|
@ -237,7 +237,6 @@ float SCH_PAINTER::getShadowWidth()
|
|||
COLOR4D SCH_PAINTER::getRenderColor( const EDA_ITEM* aItem, int aLayer, bool aDrawingShadows )
|
||||
{
|
||||
static COLOR4D highlightColor( 1.0, 0.3, 0.3, 1.0 );
|
||||
static COLOR4D selectionColor = wxSystemSettings::GetColour( wxSYS_COLOUR_HIGHLIGHT );
|
||||
|
||||
COLOR4D color = m_schSettings.GetLayerColor( aLayer );
|
||||
|
||||
|
@ -254,7 +253,7 @@ COLOR4D SCH_PAINTER::getRenderColor( const EDA_ITEM* aItem, int aLayer, bool aDr
|
|||
else if( aItem->IsSelected() )
|
||||
{
|
||||
if( aDrawingShadows )
|
||||
color = selectionColor.WithAlpha( 0.8 );
|
||||
color = m_schSettings.GetLayerColor( LAYER_SELECTION_SHADOWS ).WithAlpha( 0.8 );
|
||||
}
|
||||
else if( aItem->IsHighlighted() ) // Cross-probing
|
||||
{
|
||||
|
|
|
@ -88,14 +88,15 @@ static COLORBUTTON sheetColorButtons[] = {
|
|||
};
|
||||
|
||||
static COLORBUTTON miscColorButtons[] = {
|
||||
{ _( "ERC warning" ), LAYER_ERC_WARN },
|
||||
{ _( "ERC error" ), LAYER_ERC_ERR },
|
||||
{ _( "Brightened" ), LAYER_BRIGHTENED },
|
||||
{ _( "Hidden items" ), LAYER_HIDDEN },
|
||||
{ _( "Worksheet" ), LAYER_WORKSHEET },
|
||||
{ _( "Cursor" ), LAYER_SCHEMATIC_CURSOR },
|
||||
{ _( "Grid" ), LAYER_SCHEMATIC_GRID },
|
||||
{ _( "Background" ), LAYER_SCHEMATIC_BACKGROUND },
|
||||
{ _( "ERC warning" ), LAYER_ERC_WARN },
|
||||
{ _( "ERC error" ), LAYER_ERC_ERR },
|
||||
{ _( "Brightened" ), LAYER_BRIGHTENED },
|
||||
{ _( "Hidden items" ), LAYER_HIDDEN },
|
||||
{ _( "Worksheet" ), LAYER_WORKSHEET },
|
||||
{ _( "Cursor" ), LAYER_SCHEMATIC_CURSOR },
|
||||
{ _( "Grid" ), LAYER_SCHEMATIC_GRID },
|
||||
{ _( "Background" ), LAYER_SCHEMATIC_BACKGROUND },
|
||||
{ _( "Selection Highlight" ), LAYER_SELECTION_SHADOWS },
|
||||
{ wxT( "" ), -1 } // Sentinel marking end of list.
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue