PCB_TEXT: remove "hide" option, because they are never hidden.
- avoid write "hide" option in file - always return true when calling IsVisible() Fixes #8806 https://gitlab.com/kicad/code/kicad/issues/8806
This commit is contained in:
parent
3c721c55de
commit
56412cc843
|
@ -182,8 +182,8 @@ public:
|
|||
void SetBold( bool aBold ) { m_e.Bit( TE_BOLD, aBold); }
|
||||
bool IsBold() const { return m_e.Bit( TE_BOLD ); }
|
||||
|
||||
void SetVisible( bool aVisible ) { m_e.Bit( TE_VISIBLE, aVisible ); }
|
||||
bool IsVisible() const { return m_e.Bit( TE_VISIBLE ); }
|
||||
virtual void SetVisible( bool aVisible ) { m_e.Bit( TE_VISIBLE, aVisible ); }
|
||||
virtual bool IsVisible() const { return m_e.Bit( TE_VISIBLE ); }
|
||||
|
||||
void SetMirrored( bool isMirrored ) { m_e.Bit( TE_MIRROR, isMirrored ); }
|
||||
bool IsMirrored() const { return m_e.Bit( TE_MIRROR ); }
|
||||
|
|
|
@ -64,6 +64,10 @@ public:
|
|||
|
||||
wxString GetShownText( int aDepth = 0 ) const override;
|
||||
|
||||
/// PCB_TEXTs are always visible:
|
||||
void SetVisible( bool aVisible ) override { /* do nothing */}
|
||||
bool IsVisible() const override { return true; }
|
||||
|
||||
bool Matches( const wxFindReplaceData& aSearchData, void* aAuxData ) const override
|
||||
{
|
||||
return BOARD_ITEM::Matches( GetShownText(), aSearchData );
|
||||
|
|
|
@ -1711,7 +1711,8 @@ void PCB_IO::format( const PCB_TEXT* aText, int aNestLevel ) const
|
|||
|
||||
m_out->Print( 0, "\n" );
|
||||
|
||||
aText->EDA_TEXT::Format( m_out, aNestLevel, m_ctl );
|
||||
// PCB_TEXTS are never hidden, so always omit "hide" attribute
|
||||
aText->EDA_TEXT::Format( m_out, aNestLevel, m_ctl | CTL_OMIT_HIDE );
|
||||
|
||||
m_out->Print( aNestLevel, ")\n" );
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue