Avoid drawing the scroll bars if the widget is non-visible

This commit is contained in:
Markus Gans 2019-06-02 19:14:06 +02:00
parent 7c46d52ef4
commit b9ef1200e8
1 changed files with 11 additions and 8 deletions

View File

@ -556,6 +556,8 @@ void FTextView::adjustSize()
hbar->setValue (xoffset); hbar->setValue (xoffset);
hbar->resize(); hbar->resize();
if ( isShown() )
{
if ( last_line < int(height) + nf_offset - 1 ) if ( last_line < int(height) + nf_offset - 1 )
vbar->hide(); vbar->hide();
else else
@ -566,6 +568,7 @@ void FTextView::adjustSize()
else else
hbar->show(); hbar->show();
} }
}
// private methods of FTextView // private methods of FTextView