diff --git a/eeschema/dialogs/dialog_symbol_fields_table.cpp b/eeschema/dialogs/dialog_symbol_fields_table.cpp index 22b4c28c2c..6301ec595e 100644 --- a/eeschema/dialogs/dialog_symbol_fields_table.cpp +++ b/eeschema/dialogs/dialog_symbol_fields_table.cpp @@ -37,6 +37,7 @@ #include #include #include +#include #include #include #include @@ -1179,8 +1180,8 @@ void DIALOG_SYMBOL_FIELDS_TABLE::OnTableItemContextMenu( wxGridEvent& event ) void DIALOG_SYMBOL_FIELDS_TABLE::OnSizeFieldList( wxSizeEvent& event ) { - int nameColWidth = event.GetSize().GetX() - m_showColWidth - m_groupByColWidth - - wxSystemSettings::GetMetric( wxSYS_VSCROLL_X ); + int nameColWidth = KIPLATFORM::UI::GetUnobscuredSize( m_fieldsCtrl ).x - m_showColWidth + - m_groupByColWidth; // GTK loses its head and messes these up when resizing the splitter bar: m_fieldsCtrl->GetColumn( SHOW_FIELD_COLUMN )->SetWidth( m_showColWidth ); @@ -1189,6 +1190,8 @@ void DIALOG_SYMBOL_FIELDS_TABLE::OnSizeFieldList( wxSizeEvent& event ) m_fieldsCtrl->GetColumn( CANONICAL_NAME_COLUMN )->SetHidden( true ); m_fieldsCtrl->GetColumn( DISPLAY_NAME_COLUMN )->SetWidth( nameColWidth ); + m_fieldsCtrl->Refresh(); // To refresh checkboxes on Windows. + event.Skip(); }