From bb6555ff3619679a4fedf4bbce713a4bbb8cb733 Mon Sep 17 00:00:00 2001 From: Mike Williams Date: Sun, 4 Jun 2023 13:45:07 -0400 Subject: [PATCH] Symbol Fields Table: remember export filename https://gitlab.com/kicad/code/kicad/-/issues/14872 --- eeschema/dialogs/dialog_symbol_fields_table.cpp | 3 +++ eeschema/eeschema_settings.cpp | 3 +++ eeschema/eeschema_settings.h | 1 + 3 files changed, 7 insertions(+) diff --git a/eeschema/dialogs/dialog_symbol_fields_table.cpp b/eeschema/dialogs/dialog_symbol_fields_table.cpp index 941ecd41e5..523d1ebd63 100644 --- a/eeschema/dialogs/dialog_symbol_fields_table.cpp +++ b/eeschema/dialogs/dialog_symbol_fields_table.cpp @@ -266,6 +266,8 @@ DIALOG_SYMBOL_FIELDS_TABLE::DIALOG_SYMBOL_FIELDS_TABLE( SCH_EDIT_FRAME* parent ) m_nbPages->SetSelection( cfg->m_FieldEditorPanel.page ); + m_outputFileName->SetValue( cfg->m_FieldEditorPanel.export_filename ); + Center(); // Connect Events @@ -391,6 +393,7 @@ DIALOG_SYMBOL_FIELDS_TABLE::~DIALOG_SYMBOL_FIELDS_TABLE() cfg->m_FieldEditorPanel.width = GetSize().x; cfg->m_FieldEditorPanel.height = GetSize().y; cfg->m_FieldEditorPanel.page = m_nbPages->GetSelection(); + cfg->m_FieldEditorPanel.export_filename = m_outputFileName->GetValue(); for( int i = 0; i < m_grid->GetNumberCols(); i++ ) { diff --git a/eeschema/eeschema_settings.cpp b/eeschema/eeschema_settings.cpp index 1c8234791d..f5fa9d5b69 100644 --- a/eeschema/eeschema_settings.cpp +++ b/eeschema/eeschema_settings.cpp @@ -418,6 +418,9 @@ EESCHEMA_SETTINGS::EESCHEMA_SETTINGS() : m_params.emplace_back( new PARAM( "field_editor.page", &m_FieldEditorPanel.page, 0 ) ); + m_params.emplace_back( new PARAM( "field_editor.export_filename", + &m_FieldEditorPanel.export_filename, wxT( "" ) ) ); + m_params.emplace_back( new PARAM( "plot.background_color", &m_PlotPanel.background_color, false ) ); diff --git a/eeschema/eeschema_settings.h b/eeschema/eeschema_settings.h index d7b9c83ed5..e203309595 100644 --- a/eeschema/eeschema_settings.h +++ b/eeschema/eeschema_settings.h @@ -212,6 +212,7 @@ public: int width; int height; int page; + wxString export_filename; }; struct PANEL_LIB_VIEW