FP_TEXT::ViewGetLOD() fix incorrect test (LAYER_MOD_VALUES color has no matter)
Fixes #11026 https://gitlab.com/kicad/code/kicad/issues/11026 Fixes #11028
This commit is contained in:
parent
79b6991d7b
commit
c3f8d8b5a1
|
@ -377,13 +377,10 @@ double FP_TEXT::ViewGetLOD( int aLayer, KIGFX::VIEW* aView ) const
|
||||||
if( !aView->IsLayerVisible( GetLayer() ) )
|
if( !aView->IsLayerVisible( GetLayer() ) )
|
||||||
return HIDE;
|
return HIDE;
|
||||||
|
|
||||||
RENDER_SETTINGS* renderSettings = aView->GetPainter()->GetSettings();
|
|
||||||
|
|
||||||
// Handle Render tab switches
|
// Handle Render tab switches
|
||||||
if( m_Type == TEXT_is_VALUE || GetText() == wxT( "${VALUE}" ) )
|
if( m_Type == TEXT_is_VALUE || GetText() == wxT( "${VALUE}" ) )
|
||||||
{
|
{
|
||||||
if( !aView->IsLayerVisible( LAYER_MOD_VALUES )
|
if( !aView->IsLayerVisible( LAYER_MOD_VALUES ) )
|
||||||
|| renderSettings->GetLayerColor( LAYER_MOD_VALUES ) == COLOR4D::UNSPECIFIED )
|
|
||||||
{
|
{
|
||||||
return HIDE;
|
return HIDE;
|
||||||
}
|
}
|
||||||
|
@ -391,8 +388,7 @@ double FP_TEXT::ViewGetLOD( int aLayer, KIGFX::VIEW* aView ) const
|
||||||
|
|
||||||
if( m_Type == TEXT_is_REFERENCE || GetText() == wxT( "${REFERENCE}" ) )
|
if( m_Type == TEXT_is_REFERENCE || GetText() == wxT( "${REFERENCE}" ) )
|
||||||
{
|
{
|
||||||
if( !aView->IsLayerVisible( LAYER_MOD_REFERENCES )
|
if( !aView->IsLayerVisible( LAYER_MOD_REFERENCES ) )
|
||||||
|| renderSettings->GetLayerColor( LAYER_MOD_REFERENCES ) == COLOR4D::UNSPECIFIED )
|
|
||||||
{
|
{
|
||||||
return HIDE;
|
return HIDE;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue