Set DoubleBuffering to reduce flicker
This sets double buffering for GTK and MSW to minimize flicker when redrawing window elements. Fixes https://gitlab.com/kicad/code/kicad/issues/4785
This commit is contained in:
parent
2675f69479
commit
106259f6e6
|
@ -197,6 +197,8 @@ void SCH_DRAW_PANEL::OnShow()
|
|||
if( frame )
|
||||
frame->ActivateGalCanvas();
|
||||
}
|
||||
|
||||
m_parent->SetDoubleBuffered( true );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -87,6 +87,8 @@ SCH_PREVIEW_PANEL::~SCH_PREVIEW_PANEL()
|
|||
|
||||
void SCH_PREVIEW_PANEL::OnShow()
|
||||
{
|
||||
m_parent->SetDoubleBuffered( true );
|
||||
|
||||
//m_view->RecacheAllItems();
|
||||
}
|
||||
|
||||
|
|
|
@ -100,6 +100,7 @@ void GERBVIEW_DRAW_PANEL_GAL::OnShow()
|
|||
|
||||
if( frame )
|
||||
{
|
||||
m_parent->SetDoubleBuffered( true );
|
||||
SetTopLayer( frame->GetActiveLayer() );
|
||||
auto& displ_opts = frame->GetDisplayOptions();
|
||||
static_cast<KIGFX::GERBVIEW_RENDER_SETTINGS*>(
|
||||
|
|
|
@ -416,6 +416,7 @@ void PCB_DRAW_PANEL_GAL::OnShow()
|
|||
|
||||
if( frame )
|
||||
{
|
||||
m_parent->SetDoubleBuffered( true );
|
||||
SetTopLayer( frame->GetActiveLayer() );
|
||||
KIGFX::PAINTER* painter = m_view->GetPainter();
|
||||
auto settings = static_cast<KIGFX::PCB_RENDER_SETTINGS*>( painter->GetSettings() );
|
||||
|
|
Loading…
Reference in New Issue