KiCad PCB EDA Suite
Loading...
Searching...
No Matches
eeschema_settings.cpp
Go to the documentation of this file.
1/*
2* This program source code file is part of KiCad, a free EDA CAD application.
3*
4* Copyright (C) 2020-2023 KiCad Developers, see AUTHORS.txt for contributors.
5*
6* This program is free software; you can redistribute it and/or
7* modify it under the terms of the GNU General Public License
8* as published by the Free Software Foundation; either version 2
9* of the License, or (at your option) any later version.
10*
11* This program is distributed in the hope that it will be useful,
12* but WITHOUT ANY WARRANTY; without even the implied warranty of
13* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14* GNU General Public License for more details.
15*
16* You should have received a copy of the GNU General Public License
17* along with this program; if not, you may find one here:
18* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
19* or you may search the http://www.gnu.org website for the version 2 license,
20* or you may write to the Free Software Foundation, Inc.,
21* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
22*/
23
24#include <functional>
25
26#include <dialogs/dialog_bom_cfg_lexer.h>
27#include <eeschema_settings.h>
28#include <layer_ids.h>
30#include <macros.h>
31#include <pgm_base.h>
34#include <settings/parameters.h>
37#include <wx/config.h>
38#include <widgets/ui_common.h>
39#include <default_values.h> // For some default values
40
41using namespace T_BOMCFG_T; // for the BOM_CFG_PARSER parser and its keywords
42
45
47const nlohmann::json defaultBomPlugins =
48 {
49 {
50 { "name", "bom_csv_grouped_extra" },
51 { "path", "bom_csv_grouped_extra.py" }
52 },
53 {
54 { "name", "bom_csv_grouped_by_value" },
55 { "path", "bom_csv_grouped_by_value.py" }
56 },
57 {
58 { "name", "bom_csv_grouped_by_value_with_fp" },
59 { "path", "bom_csv_grouped_by_value_with_fp.py" }
60 },
61 };
62
63
64const wxAuiPaneInfo& defaultNetNavigatorPaneInfo()
65{
66 static wxAuiPaneInfo paneInfo;
67
68 paneInfo.Name( wxS( "NetNavigator" ) )
69 .Caption( _( "Net Navigator" ) )
70 .CaptionVisible( true )
71 .PaneBorder( true )
72 .Left().Layer( 3 )
73 .TopDockable( false )
74 .BottomDockable( false )
75 .CloseButton( true )
76 .MinSize( 120, 60 )
77 .BestSize( 200, 200 )
78 .FloatingSize( 200, 200 )
79 .FloatingPosition( 50, 200 )
80 .Show( false );
81
82 return paneInfo;
83}
84
85
88 m_Appearance(),
89 m_AutoplaceFields(),
90 m_Drawing(),
91 m_FindReplaceExtra(),
92 m_Input(),
93 m_PageSettings(),
94 m_AnnotatePanel(),
95 m_BomPanel(),
96 m_FieldEditorPanel(),
97 m_LibViewPanel(),
98 m_NetlistPanel(),
99 m_PlotPanel(),
100 m_SymChooserPanel(),
101 m_Selection(),
102 m_Simulator(),
103 m_RescueNeverShow( false )
104{
105 m_params.emplace_back( new PARAM<wxString>( "appearance.edit_symbol_visible_columns",
106 &m_Appearance.edit_symbol_visible_columns, "0 1 2 3 4 5 6 7" ) );
107
108 m_params.emplace_back( new PARAM<int>( "appearance.edit_symbol_width",
110
111 m_params.emplace_back( new PARAM<int>( "appearance.edit_symbol_height",
113
114 m_params.emplace_back( new PARAM<wxString>( "appearance.edit_sheet_visible_columns",
115 &m_Appearance.edit_sheet_visible_columns, "0 1 2 3 4 5 6 7" ) );
116
117 m_params.emplace_back( new PARAM<int>( "appearance.edit_sheet_width",
119
120 m_params.emplace_back( new PARAM<int>( "appearance.edit_sheet_height",
122
123 m_params.emplace_back( new PARAM<wxString>( "appearance.edit_label_visible_columns",
124 &m_Appearance.edit_label_visible_columns, "0 1 2 3 4 5 6 7" ) );
125
126 m_params.emplace_back( new PARAM<int>( "appearance.edit_label_width",
128
129 m_params.emplace_back( new PARAM<int>( "appearance.edit_label_height",
131
132 m_params.emplace_back( new PARAM<int>( "appearance.erc_severities",
134
135 m_params.emplace_back( new PARAM<bool>( "appearance.footprint_preview",
137
138 m_params.emplace_back( new PARAM<bool>( "appearance.print_sheet_reference",
140
141 m_params.emplace_back( new PARAM<wxString>( "appearance.default_font",
142 &m_Appearance.default_font, "KiCad Font" ) );
143
144 m_params.emplace_back( new PARAM<bool>( "appearance.show_hidden_pins",
145 &m_Appearance.show_hidden_pins, false ) );
146
147 m_params.emplace_back( new PARAM<bool>( "appearance.show_hidden_fields",
149
150 m_params.emplace_back( new PARAM<bool>( "appearance.show_directive_labels",
152
153 m_params.emplace_back( new PARAM<bool>( "appearance.show_erc_warnings",
155
156 m_params.emplace_back( new PARAM<bool>( "appearance.show_erc_errors",
157 &m_Appearance.show_erc_errors, true ) );
158
159 m_params.emplace_back( new PARAM<bool>( "appearance.show_erc_exclusions",
161
162 m_params.emplace_back( new PARAM<bool>( "appearance.show_op_voltages",
164
165 m_params.emplace_back( new PARAM<bool>( "appearance.show_op_currents",
167
168 m_params.emplace_back( new PARAM<bool>( "appearance.show_illegal_symbol_lib_dialog",
170
171 m_params.emplace_back( new PARAM<bool>( "appearance.show_page_limits",
173
174 m_params.emplace_back( new PARAM<bool>( "appearance.show_sexpr_file_convert_warning",
176
177 m_params.emplace_back(
178 new PARAM<bool>( "appearance.show_sheet_filename_case_sensitivity_dialog",
180
181 m_params.emplace_back( new PARAM<bool>( "aui.show_schematic_hierarchy",
183
184 m_params.emplace_back( new PARAM<int>( "aui.hierarchy_panel_docked_width",
186
187 m_params.emplace_back( new PARAM<int>( "aui.hierarchy_panel_docked_height",
189
190 m_params.emplace_back( new PARAM<int>( "aui.hierarchy_panel_float_width",
192
193 m_params.emplace_back( new PARAM<int>( "aui.hierarchy_panel_float_height",
195
196 m_params.emplace_back( new PARAM<bool>( "aui.schematic_hierarchy_float",
198
199 m_params.emplace_back( new PARAM<int>( "aui.search_panel_height",
201
202 m_params.emplace_back( new PARAM<bool>( "aui.show_search",
203 &m_AuiPanels.show_search, false ) );
204
205 m_params.emplace_back( new PARAM<bool>( "aui.show_net_nav_panel",
207
208 m_params.emplace_back( new PARAM<bool>( "aui.float_net_nav_panel",
210
211 m_params.emplace_back( new PARAM<wxSize>( "aui.net_nav_panel_docked_size",
212 &m_AuiPanels.net_nav_panel_docked_size, wxSize( 120, -1 ) ) );
213
214 m_params.emplace_back( new PARAM<bool>( "aui.float_net_nav_panel",
216
217 m_params.emplace_back( new PARAM<wxPoint>( "aui.net_nav_panel_float_pos",
218 &m_AuiPanels.net_nav_panel_float_pos, wxPoint( 50, 200 ), false ) );
219
220 m_params.emplace_back( new PARAM<wxSize>( "aui.net_nav_panel_float_size",
221 &m_AuiPanels.net_nav_panel_float_size, wxSize( 200, 200 ) ) );
222
223 m_params.emplace_back( new PARAM<bool>( "autoplace_fields.enable",
224 &m_AutoplaceFields.enable, true ) );
225
226 m_params.emplace_back( new PARAM<bool>( "autoplace_fields.allow_rejustify",
228
229 m_params.emplace_back( new PARAM<bool>( "autoplace_fields.align_to_grid",
231
232 m_params.emplace_back( new PARAM<int>( "drawing.default_bus_thickness",
234
235 m_params.emplace_back( new PARAM<int>( "drawing.default_junction_size",
237
238 m_params.emplace_back( new PARAM<int>( "drawing.pin_symbol_size",
240
241 m_params.emplace_back( new PARAM<double>( "drawing.text_offset_ratio",
242 &m_Drawing.text_offset_ratio, 0.08 ) );
243
244 m_params.emplace_back( new PARAM<int>( "drawing.default_line_thickness",
246
247 m_params.emplace_back( new PARAM<int>( "drawing.default_repeat_offset_x",
249
250 m_params.emplace_back( new PARAM<int>( "drawing.default_repeat_offset_y",
252
253 m_params.emplace_back( new PARAM<int>( "drawing.default_wire_thickness",
255
256 m_params.emplace_back( new PARAM<int>( "drawing.default_text_size",
258
259 m_params.emplace_back( new PARAM<wxString>( "drawing.field_names",
260 &m_Drawing.field_names, "" ) );
261
262 m_params.emplace_back( new PARAM<int>( "drawing.line_mode", &m_Drawing.line_mode,
263 LINE_MODE::LINE_MODE_90 ) );
264
265 m_params.emplace_back( new PARAM<bool>( "drawing.auto_start_wires",
266 &m_Drawing.auto_start_wires, true ) );
267
268 m_params.emplace_back( new PARAM<int>( "drawing.repeat_label_increment",
270
271 m_params.emplace_back( new PARAM<COLOR4D>( "drawing.default_sheet_border_color",
272 &m_Drawing.default_sheet_border_color, COLOR4D::UNSPECIFIED ) );
273
274 m_params.emplace_back( new PARAM<COLOR4D>( "drawing.default_sheet_background_color",
275 &m_Drawing.default_sheet_background_color, COLOR4D::UNSPECIFIED ) );
276
277 m_params.emplace_back( new PARAM_LIST<double>( "drawing.junction_size_mult_list",
278 &m_Drawing.junction_size_mult_list, { 0.0, 1.7, 4.0, 6.0, 9.0, 12.0 } ) );
279
280 m_params.emplace_back(new PARAM <int>( "drawing.junction_size_choice",
282
283 m_params.emplace_back( new PARAM<bool>( "find_replace.search_all_fields",
285
286 m_params.emplace_back( new PARAM<bool>( "find_replace.search_all_pins",
288
289 m_params.emplace_back( new PARAM<bool>( "find_replace.search_current_sheet_only",
291 false ) );
292
293 m_params.emplace_back( new PARAM<bool>( "find_replace.replace_references",
295
296 m_params.emplace_back( new PARAM<bool>( "input.drag_is_move",
297 &m_Input.drag_is_move, false ) );
298
299 m_params.emplace_back( new PARAM<bool>( "input.esc_clears_net_highlight",
301
302 m_params.emplace_back( new PARAM<int>( "selection.thickness",
304
305 m_params.emplace_back( new PARAM<int>( "selection.highlight_thickness",
307
308 m_params.emplace_back( new PARAM<bool>( "selection.draw_selected_children",
310
311 m_params.emplace_back( new PARAM<bool>( "selection.fill_shapes",
312 &m_Selection.fill_shapes, false ) );
313
314 m_params.emplace_back( new PARAM<bool>( "selection.select_pin_selects_symbol",
316
317 m_params.emplace_back( new PARAM<bool>( "annotation.automatic",
318 &m_AnnotatePanel.automatic, true ) );
319
320 m_params.emplace_back( new PARAM<bool>( "annotation.recursive",
321 &m_AnnotatePanel.recursive, true ) );
322
323 m_params.emplace_back( new PARAM<int>( "annotation.method",
324 &m_AnnotatePanel.method, 0, 0, 2 ) );
325
326 m_params.emplace_back( new PARAM<int>( "annotation.scope",
327 &m_AnnotatePanel.scope, 0, 0, 2 ) );
328
329 m_params.emplace_back( new PARAM<int>( "annotation.options",
330 &m_AnnotatePanel.options, 0, 0, 2 ) );
331
332 m_params.emplace_back( new PARAM<int>( "annotation.messages_filter",
334
335 m_params.emplace_back( new PARAM<int>( "annotation.sort_order",
336 &m_AnnotatePanel.sort_order, 0, 0, 1 ) );
337
338 m_params.emplace_back( new PARAM<wxString>( "bom.selected_plugin",
340
341 m_params.emplace_back( new PARAM_LAMBDA<nlohmann::json>( "bom.plugins",
342 std::bind( &EESCHEMA_SETTINGS::bomSettingsToJson, this ),
343 [&]( const nlohmann::json& aObj )
344 {
345 if( !aObj.is_array() )
346 return;
347
348 const nlohmann::json& list = aObj.empty() ? defaultBomPlugins : aObj;
349
351 },
353
354 m_params.emplace_back( new PARAM_LAMBDA<nlohmann::json>( "netlist.plugins",
356 [&]( const nlohmann::json& aObj )
357 {
358 if( !aObj.is_array() )
359 return;
360
361 if( aObj.empty() )
362 return;
363
364 const nlohmann::json& list = aObj;
365
367 },
368 nullptr ) );
369
370 m_params.emplace_back( new PARAM<bool>( "page_settings.export_paper",
371 &m_PageSettings.export_paper, false ) );
372
373 m_params.emplace_back( new PARAM<bool>( "page_settings.export_revision",
375
376 m_params.emplace_back( new PARAM<bool>( "page_settings.export_date",
377 &m_PageSettings.export_date, false ) );
378
379 m_params.emplace_back( new PARAM<bool>( "page_settings.export_title",
380 &m_PageSettings.export_title, false ) );
381
382 m_params.emplace_back( new PARAM<bool>( "page_settings.export_company",
383 &m_PageSettings.export_company, false ) );
384
385 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment1",
387
388 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment2",
390
391 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment3",
393
394 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment4",
396
397 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment5",
399
400 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment6",
402
403 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment7",
405
406 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment8",
408
409 m_params.emplace_back( new PARAM<bool>( "page_settings.export_comment9",
411
412 m_params.emplace_back( new PARAM_MAP<int>( "field_editor.field_widths",
414
415 m_params.emplace_back( new PARAM<int>( "field_editor.width", &m_FieldEditorPanel.width, 0 ) );
416
417 m_params.emplace_back( new PARAM<int>( "field_editor.height", &m_FieldEditorPanel.height, 0 ) );
418
419 m_params.emplace_back( new PARAM<int>( "field_editor.page", &m_FieldEditorPanel.page, 0 ) );
420
421 m_params.emplace_back( new PARAM<bool>( "plot.background_color",
422 &m_PlotPanel.background_color, false ) );
423
424 m_params.emplace_back( new PARAM<bool>( "plot.color",
425 &m_PlotPanel.color, true ) );
426
427 m_params.emplace_back( new PARAM<wxString>( "plot.color_theme",
428 &m_PlotPanel.color_theme, wxT( "user" ) ) );
429
430 m_params.emplace_back( new PARAM<int>( "plot.format",
431 &m_PlotPanel.format, 0 ) );
432
433 m_params.emplace_back( new PARAM<bool>( "plot.frame_reference",
434 &m_PlotPanel.frame_reference, true ) );
435
436 m_params.emplace_back( new PARAM<int>( "plot.hpgl_paper_size",
438
439 m_params.emplace_back( new PARAM<double>( "plot.hpgl_pen_size",
440 &m_PlotPanel.hpgl_pen_size, 0.5 ) );
441
442 m_params.emplace_back( new PARAM<int>( "plot.hpgl_origin",
443 &m_PlotPanel.hpgl_origin, 0 ) );
444
445 m_params.emplace_back( new PARAM<bool>( "plot.other_open_file_after_plot",
447
448 m_params.emplace_back( new PARAM<int>( "simulator.window.pos_x",
450
451 m_params.emplace_back( new PARAM<int>( "simulator.window.pos_y",
453
454 m_params.emplace_back( new PARAM<int>( "simulator.window.size_x",
455 &m_Simulator.window.state.size_x, 500 ) );
456
457 m_params.emplace_back( new PARAM<int>( "simulator.window.size_y",
458 &m_Simulator.window.state.size_y, 400 ) );
459
460 m_params.emplace_back( new PARAM<unsigned int>( "simulator.window.display",
462
463 m_params.emplace_back( new PARAM<bool>( "simulator.window.maximized",
464 &m_Simulator.window.state.maximized, false ) );
465
466 m_params.emplace_back( new PARAM<wxString>( "simulator.window.perspective",
468
469 m_params.emplace_back( new PARAM<int>( "simulator.plot_panel_width",
471
472 m_params.emplace_back( new PARAM<int>( "simulator.plot_panel_height",
474
475 m_params.emplace_back( new PARAM<int>( "simulator.signal_panel_height",
477
478 m_params.emplace_back( new PARAM<int>( "simulator.cursors_panel_height",
480
481 m_params.emplace_back( new PARAM<int>( "simulator.measurements_panel_height",
483
484 m_params.emplace_back( new PARAM<bool>( "simulator.white_background",
485 &m_Simulator.white_background, false ) );
486
487 m_params.emplace_back( new PARAM<int>( "symbol_chooser.sash_pos_h",
489
490 m_params.emplace_back( new PARAM<int>( "symbol_chooser.sash_pos_v",
492
493 m_params.emplace_back( new PARAM<int>( "symbol_chooser.width",
494 &m_SymChooserPanel.width, -1 ) );
495
496 m_params.emplace_back( new PARAM<int>( "symbol_chooser.height",
497 &m_SymChooserPanel.height, -1 ) );
498
499 m_params.emplace_back( new PARAM<int>( "symbol_chooser.sort_mode",
501
502 m_params.emplace_back( new PARAM<bool>( "symbol_chooser.keep_symbol",
503 &m_SymChooserPanel.keep_symbol, false ) );
504
505 m_params.emplace_back( new PARAM<bool>( "symbol_chooser.place_all_units",
507
508 m_params.emplace_back( new PARAM<bool>( "system.never_show_rescue_dialog",
509 &m_RescueNeverShow, false ) );
510
511 m_params.emplace_back( new PARAM<int>( "lib_view.window.pos_x",
513
514 m_params.emplace_back( new PARAM<int>( "lib_view.window.pos_y",
516
517 m_params.emplace_back( new PARAM<int>( "lib_view.window.size_x",
519
520 m_params.emplace_back( new PARAM<int>( "lib_view.window.size_y",
522
523 m_params.emplace_back( new PARAM<unsigned int>( "lib_view.window.display",
525
526 m_params.emplace_back( new PARAM<bool>( "lib_view.window.maximized",
528
529 m_params.emplace_back( new PARAM<wxString>( "lib_view.window.perspective",
531
532 m_params.emplace_back( new PARAM<int>( "lib_view.lib_list_width",
534
535 m_params.emplace_back( new PARAM<int>( "lib_view.cmp_list_width",
537
538 m_params.emplace_back( new PARAM<bool>( "lib_view.show_pin_electrical_type",
540
541 m_params.emplace_back( new PARAM<wxString>( "system.last_symbol_lib_dir",
542 &m_lastSymbolLibDir, "" ) );
543
544
545 // Migrations
546
547 registerMigration( 0, 1,
548 [&]() -> bool
549 {
550 // Version 0 to 1: BOM plugin settings moved from sexpr to JSON
551 return migrateBomSettings();
552 } );
553
554
555 registerMigration( 1, 2,
556 [&]() -> bool
557 {
558 // We used to have a bug on GTK which would set the lib tree column width way
559 // too narrow.
560 if( std::optional<int> optval = Get<int>( "lib_tree.column_width" ) )
561 {
562 if( optval < 150 )
563 Set( "lib_tree.column_width", 300 );
564 }
565
566 return true;
567 } );
568
569 registerMigration( 2, 3,
570 [&]() -> bool
571 {
572 // This is actually a migration for APP_SETTINGS_BASE::m_LibTree
573 return migrateLibTreeWidth();
574 } );
575}
576
577
578bool EESCHEMA_SETTINGS::MigrateFromLegacy( wxConfigBase* aCfg )
579{
580 bool ret = APP_SETTINGS_BASE::MigrateFromLegacy( aCfg );
581
582 // Now modify the loaded grid selection, because in earlier versions the grids index was shared
583 // between all applications and started at 1000 mils. There is a 4-position offset between
584 // this index and the possible eeschema grids list that we have to subtract.
585 std::string gridSizePtr = "window.grid.last_size";
586
587 if( std::optional<int> currentSize = Get<int>( gridSizePtr ) )
588 {
589 Set( gridSizePtr, *currentSize - 4 );
590 }
591 else
592 {
593 // Otherwise, default grid size should be 50 mils; index 1
594 Set( gridSizePtr, 1 );
595 }
596
597 ret &= fromLegacy<bool>( aCfg, "FootprintPreview", "appearance.footprint_preview" );
598 ret &= fromLegacy<bool>( aCfg, "NavigatorStaysOpen", "appearance.navigator_stays_open" );
599 ret &= fromLegacy<bool>( aCfg, "PrintSheetReferenceAndTitleBlock",
600 "appearance.print_sheet_reference" );
601 ret &= fromLegacy<bool>( aCfg, "ShowHiddenPins", "appearance.show_hidden_pins" );
602 ret &= fromLegacy<bool>( aCfg, "ShowIllegalSymbolLibDialog",
603 "appearance.show_illegal_symbol_lib_dialog" );
604 ret &= fromLegacy<bool>( aCfg, "ShowPageLimits", "appearance.show_page_limits" );
605 ret &= fromLegacy<bool>( aCfg, "ShowSheetFileNameCaseSensitivityDlg",
606 "appearance.show_sheet_filename_case_sensitivity_dialog" );
607
608 ret &= fromLegacy<bool>( aCfg, "AutoplaceFields", "autoplace_fields.enable" );
609 ret &= fromLegacy<bool>( aCfg, "AutoplaceJustify", "autoplace_fields.allow_rejustify" );
610 ret &= fromLegacy<bool>( aCfg, "AutoplaceAlign", "autoplace_fields.align_to_grid" );
611
612 ret &= fromLegacy<int>( aCfg, "DefaultBusWidth", "drawing.default_bus_thickness" );
613 ret &= fromLegacy<int>( aCfg, "DefaultJunctionSize", "drawing.default_junction_size" );
614 ret &= fromLegacy<int>( aCfg, "DefaultDrawLineWidth", "drawing.default_line_thickness" );
615 ret &= fromLegacy<int>( aCfg, "RepeatStepX", "drawing.default_repeat_offset_x" );
616 ret &= fromLegacy<int>( aCfg, "RepeatStepY", "drawing.default_repeat_offset_y" );
617 ret &= fromLegacy<int>( aCfg, "DefaultWireWidth", "drawing.default_wire_thickness" );
618 ret &= fromLegacyString( aCfg, "FieldNames", "drawing.field_names" );
619 ret &= fromLegacy<bool>( aCfg, "HorizVertLinesOnly", "drawing.line_mode" );
620 ret &= fromLegacy<int>( aCfg, "RepeatLabelIncrement", "drawing.repeat_label_increment" );
621
622 ret &= fromLegacy<bool>( aCfg, "DragActionIsMove", "input.drag_is_move" );
623
624 ret &= fromLegacy<int>( aCfg, "SelectionThickness", "selection.thickness" );
625 ret &= fromLegacy<bool>( aCfg, "SelectionDrawChildItems", "selection.draw_selected_children" );
626 ret &= fromLegacy<bool>( aCfg, "SelectionFillShapes", "selection.fill_shapes" );
627 ret &= fromLegacy<bool>( aCfg, "SelectPinSelectSymbolOpt",
628 "selection.select_pin_selects_symbol" );
629
630 ret &= fromLegacy<int>( aCfg, "AnnotateAlgoOption", "annotation.method" );
631 ret &= fromLegacy<int>( aCfg, "AnnotateFilterMsg", "annotation.messages_filter" );
632 ret &= fromLegacy<int>( aCfg, "AnnotateSortOption", "annotation.sort_order" );
633
634 ret &= fromLegacyString( aCfg, "bom_plugin_selected", "bom.selected_plugin" );
635 ret &= fromLegacyString( aCfg, "bom_plugins", "bom.plugins" );
636
638
639 ret &= fromLegacyString( aCfg, "SymbolFieldsShownColumns",
640 "edit_sch_component.visible_columns" );
641
642 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportRevision", "page_settings.export_revision" );
643 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportDate", "page_settings.export_date" );
644 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportTitle", "page_settings.export_title" );
645 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportCompany", "page_settings.export_company" );
646 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment1", "page_settings.export_comment1" );
647 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment2", "page_settings.export_comment2" );
648 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment3", "page_settings.export_comment3" );
649 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment4", "page_settings.export_comment4" );
650 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment5", "page_settings.export_comment5" );
651 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment6", "page_settings.export_comment6" );
652 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment7", "page_settings.export_comment7" );
653 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment8", "page_settings.export_comment8" );
654 ret &= fromLegacy<bool>( aCfg, "PageSettingsExportComment9", "page_settings.export_comment9" );
655
656 #if 0 // To do: move this code to the new netlist plugin management in settings
657 {
658 constexpr int max_custom_commands = 8; // from DIALOG_NETLIST
659 nlohmann::json js_cmd = nlohmann::json::array();
660 nlohmann::json js_title = nlohmann::json::array();
661 wxString cmd_key, title_key, cmd, title;
662
663 for( int i = 1; i <= max_custom_commands; ++i )
664 {
665 // Only migrate if both title and command are specified
666 cmd_key.Printf( "CustomNetlistCommand%d", i );
667 title_key.Printf( "CustomNetlistTitle%d", i );
668
669 if( aCfg->Read( cmd_key, &cmd ) && aCfg->Read( title_key, &title )
670 && !cmd.IsEmpty() && !title.IsEmpty() )
671 {
672 js_cmd.push_back( cmd.ToUTF8() );
673 js_title.push_back( title.ToUTF8() );
674 }
675 }
676
677 Set( "netlist.custom_command_titles", js_title );
678 Set( "netlist.custom_command_paths", js_cmd );
679 }
680 #endif
681
682 {
683 // NOTE(JE) These parameters should move to project-local storage before V6, but we are
684 // migrating them here in order to preserve data. There is a bug here that is preserved:
685 // keys are taken directly from the (translated) UI and stored in the config, so if the user
686 // changes languages the keys will no longer work.
687 aCfg->SetPath( "SymbolFieldEditor/Show/" );
688
689 nlohmann::json js = nlohmann::json( {} );
690 wxString key;
691 bool value = false;
692 long index = 0;
693
694 while( aCfg->GetNextEntry( key, index ) )
695 {
696 if( aCfg->Read( key, &value ) )
697 {
698 std::string key_utf( key.ToUTF8() );
699
700 try
701 {
702 js[key_utf] = value;
703 }
704 catch(...)
705 {
706 continue;
707 }
708 }
709 }
710
711 Set( "field_editor.fields_show", js );
712
713 aCfg->SetPath( "../GroupBy" );
714
715 while( aCfg->GetNextEntry( key, index ) )
716 {
717 if( aCfg->Read( key, &value ) )
718 {
719 std::string key_utf( key.ToUTF8() );
720
721 try
722 {
723 js[key_utf] = value;
724 }
725 catch(...)
726 {
727 continue;
728 }
729 }
730 }
731
732 Set( "field_editor.fields_group_by", js );
733
734 aCfg->SetPath( "../.." );
735 }
736
737 ret &= fromLegacy<bool>( aCfg, "PlotModeColor", "plot.color" );
738 ret &= fromLegacy<int>( aCfg, "PlotFormat", "plot.format" );
739 ret &= fromLegacy<bool>( aCfg, "PlotFrameRef", "plot.frame_reference" );
740 ret &= fromLegacy<bool>( aCfg, "PlotHPGLOrg", "plot.hpgl_origin" );
741 ret &= fromLegacy<int>( aCfg, "PlotHPGLPaperSize", "plot.hpgl_paper_size" );
742 ret &= fromLegacy<double>( aCfg, "PlotHPGLPenSize", "plot.hpgl_pen_size" );
743
744 ret &= fromLegacy<int>( aCfg, "SIM_PLOT_FRAMEPos_x", "simulator.window.pos_x" );
745 ret &= fromLegacy<int>( aCfg, "SIM_PLOT_FRAMEPos_y", "simulator.window.pos_y" );
746 ret &= fromLegacy<int>( aCfg, "SIM_PLOT_FRAMESize_x", "simulator.window.size_x" );
747 ret &= fromLegacy<int>( aCfg, "SIM_PLOT_FRAMESize_y", "simulator.window.size_y" );
748 ret &= fromLegacy<bool>( aCfg, "SIM_PLOT_FRAMEMaximized", "simulator.window.maximized" );
749 ret &= fromLegacyString( aCfg, "SIM_PLOT_FRAMEPerspective", "simulator.window.perspective" );
750 ret &= fromLegacyString( aCfg, "SIM_PLOT_FRAMEMostRecentlyUsedPath", "simulator.mru_path" );
751 ret &= fromLegacy<int>( aCfg, "SimPlotPanelWidth", "simulator.plot_panel_width" );
752 ret &= fromLegacy<int>( aCfg, "SimPlotPanelHeight", "simulator.plot_panel_height" );
753 ret &= fromLegacy<int>( aCfg, "SimSignalPanelHeight", "simulator.signal_panel_height" );
754 ret &= fromLegacy<int>( aCfg, "SimCursorsPanelHeight", "simulator.cursors_panel_height" );
755 ret &= fromLegacy<bool>( aCfg, "SimPlotWhiteBg", "simulator.white_background" );
756
757 ret &= fromLegacy<int>( aCfg, "SymbolChooserHSashPosition", "symbol_chooser.sash_pos_h" );
758 ret &= fromLegacy<int>( aCfg, "SymbolChooserVSashPosition", "symbol_chooser.sash_pos_v" );
759 ret &= fromLegacy<int>( aCfg, "SymbolChooserWidth", "symbol_chooser.width" );
760 ret &= fromLegacy<int>( aCfg, "SymbolChooserHeight", "symbol_chooser.height" );
761 ret &= fromLegacy<bool>( aCfg, "SymbolChooserKeepSymbol", "symbol_chooser.keep_symbol" );
762 ret &= fromLegacy<bool>( aCfg, "SymbolChooserUseUnits", "symbol_chooser.place_all_units" );
763
764 const std::string vlf = "ViewlibFrame";
765 ret &= fromLegacy<bool>( aCfg, vlf + "Maximized", "lib_view.window.maximized" );
766 ret &= fromLegacyString( aCfg, vlf + "MostRecentlyUsedPath", "lib_view.window.mru_path" );
767 ret &= fromLegacy<int>( aCfg, vlf + "Size_x", "lib_view.window.size_x" );
768 ret &= fromLegacy<int>( aCfg, vlf + "Size_y", "lib_view.window.size_y" );
769 ret &= fromLegacyString( aCfg, vlf + "Perspective", "lib_view.window.perspective" );
770 ret &= fromLegacy<int>( aCfg, vlf + "Pos_x", "lib_view.window.pos_x" );
771 ret &= fromLegacy<int>( aCfg, vlf + "Pos_y", "lib_view.window.pos_y" );
772 ret &= fromLegacy<int>( aCfg, "ViewLiblistWidth", "lib_view.lib_list_width" );
773 ret &= fromLegacy<int>( aCfg, "ViewCmplistWidth", "lib_view.cmp_list_width" );
774 ret &= fromLegacy<bool>( aCfg,
775 "ViewCmpShowPinElectricalType", "lib_view.show_pin_electrical_type" );
776 ret &= fromLegacy<bool>( aCfg, vlf + "ShowGrid", "lib_view.grid.show" );
777 ret &= fromLegacy<int>( aCfg, vlf + "_LastGridSize", "lib_view.grid.last_size" );
778
779 ret &= fromLegacy<bool>( aCfg, "RescueNeverShow", "system.never_show_rescue_dialog" );
780
781 // Legacy version stored this setting in eeschema, so move it to common if it exists
782 bool tmp;
783
784 if( aCfg->Read( "MoveWarpsCursor", &tmp ) )
785 Pgm().GetCommonSettings()->m_Input.warp_mouse_on_move = tmp;
786
787 COLOR_SETTINGS* cs = Pgm().GetSettingsManager().GetMigratedColorSettings();
788
789 auto migrateLegacyColor = [&] ( const std::string& aKey, int aLayerId ) {
790 wxString str;
791
792 if( aCfg->Read( aKey, &str ) )
793 cs->SetColor( aLayerId, COLOR4D( str ) );
794 };
795
796 migrateLegacyColor( "Color4DBgCanvasEx", LAYER_SCHEMATIC_BACKGROUND );
797 migrateLegacyColor( "Color4DBodyBgEx", LAYER_DEVICE_BACKGROUND );
798 migrateLegacyColor( "Color4DBodyEx", LAYER_DEVICE );
799 migrateLegacyColor( "Color4DBrightenedEx", LAYER_BRIGHTENED );
800 migrateLegacyColor( "Color4DBusEx", LAYER_BUS );
801 migrateLegacyColor( "Color4DConnEx", LAYER_JUNCTION );
802 migrateLegacyColor( "Color4DCursorEx", LAYER_SCHEMATIC_CURSOR );
803 migrateLegacyColor( "Color4DErcEEx", LAYER_ERC_ERR );
804 migrateLegacyColor( "Color4DErcWEx", LAYER_ERC_WARN );
805 migrateLegacyColor( "Color4DFieldEx", LAYER_FIELDS );
806 migrateLegacyColor( "Color4DGLabelEx", LAYER_GLOBLABEL );
807 migrateLegacyColor( "Color4DGridEx", LAYER_SCHEMATIC_GRID );
808 migrateLegacyColor( "Color4DHLabelEx", LAYER_HIERLABEL );
809 migrateLegacyColor( "Color4DHiddenEx", LAYER_HIDDEN );
810 migrateLegacyColor( "Color4DLLabelEx", LAYER_LOCLABEL );
811 migrateLegacyColor( "Color4DNoConnectEx", LAYER_NOCONNECT );
812 migrateLegacyColor( "Color4DNoteEx", LAYER_NOTES );
813 migrateLegacyColor( "Color4DPinEx", LAYER_PIN );
814 migrateLegacyColor( "Color4DPinNameEx", LAYER_PINNAM );
815 migrateLegacyColor( "Color4DPinNumEx", LAYER_PINNUM );
816 migrateLegacyColor( "Color4DReferenceEx", LAYER_REFERENCEPART );
817 migrateLegacyColor( "Color4DShadowEx", LAYER_SELECTION_SHADOWS );
818 migrateLegacyColor( "Color4DSheetEx", LAYER_SHEET );
819 migrateLegacyColor( "Color4DSheetFileNameEx", LAYER_SHEETFILENAME );
820 migrateLegacyColor( "Color4DSheetLabelEx", LAYER_SHEETLABEL );
821 migrateLegacyColor( "Color4DSheetNameEx", LAYER_SHEETNAME );
822 migrateLegacyColor( "Color4DValueEx", LAYER_VALUEPART );
823 migrateLegacyColor( "Color4DWireEx", LAYER_WIRE );
824 migrateLegacyColor( "Color4DWorksheetEx", LAYER_SCHEMATIC_DRAWINGSHEET );
825
826 Pgm().GetSettingsManager().SaveColorSettings( cs, "schematic" );
827
828 Set( "appearance.color_theme", cs->GetFilename() );
829
830 // LibEdit settings were stored with eeschema. If eeschema is the first app to run,
831 // we need to migrate the LibEdit settings here
832
833 auto libedit = Pgm().GetSettingsManager().GetAppSettings<SYMBOL_EDITOR_SETTINGS>();
834 libedit->MigrateFromLegacy( aCfg );
835 libedit->Load();
836
837 return ret;
838}
839
840
845class BOM_CFG_PARSER : public DIALOG_BOM_CFG_LEXER
846{
847 std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS>* m_pluginList;
848
849public:
850 BOM_CFG_PARSER( std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS>* aPluginList,
851 const char* aData, const wxString& aSource );
852
853 void Parse();
854
855private:
856 void parseGenerator();
857};
858
859
860std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS> EESCHEMA_SETTINGS::DefaultBomPlugins()
861{
863}
864
865
867{
868 if( !Contains( "bom.plugins" ) )
869 return false;
870
871 wxString list = *Get<wxString>( "bom.plugins" );
872
873 BOM_CFG_PARSER cfg_parser( &m_BomPanel.plugins, TO_UTF8( list ), wxT( "plugins" ) );
874
875 try
876 {
877 cfg_parser.Parse();
878 }
879 catch( const IO_ERROR& )
880 {
881 return false;
882 }
883
884 // Parser will have loaded up our array, let's dump it out to JSON
885 At( "bom.plugins" ) = bomSettingsToJson();
886
887 return true;
888}
889
890
892{
893 nlohmann::json js = nlohmann::json::array();
894
895 for( const BOM_PLUGIN_SETTINGS& plugin : m_BomPanel.plugins )
896 {
897 nlohmann::json pluginJson;
898
899 pluginJson["name"] = plugin.name.ToUTF8();
900 pluginJson["path"] = plugin.path.ToUTF8();
901 pluginJson["command"] = plugin.command.ToUTF8();
902
903 js.push_back( pluginJson );
904 }
905
906 return js;
907}
908
909
910std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS> EESCHEMA_SETTINGS::bomSettingsFromJson(
911 const nlohmann::json& aObj )
912{
913 std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS> ret;
914
915 wxASSERT( aObj.is_array() );
916
917 for( const nlohmann::json& entry : aObj )
918 {
919 if( entry.empty() || !entry.is_object() )
920 continue;
921
922 if( !entry.contains( "name" ) || !entry.contains( "path" ) )
923 continue;
924
925 BOM_PLUGIN_SETTINGS plugin( entry.at( "name" ).get<wxString>(),
926 entry.at( "path" ).get<wxString>() );
927
928 if( entry.contains( "command" ) )
929 plugin.command = entry.at( "command" ).get<wxString>();
930
931 ret.emplace_back( plugin );
932 }
933
934 return ret;
935}
936
937
939{
940 nlohmann::json js = nlohmann::json::array();
941
942 for( const NETLIST_PLUGIN_SETTINGS& plugin : m_NetlistPanel.plugins )
943 {
944 nlohmann::json pluginJson;
945
946 pluginJson["name"] = plugin.name.ToUTF8();
947 pluginJson["path"] = plugin.path.ToUTF8();
948 pluginJson["command"] = plugin.command.ToUTF8();
949
950 js.push_back( pluginJson );
951 }
952
953 return js;
954}
955
956
957std::vector<EESCHEMA_SETTINGS::NETLIST_PLUGIN_SETTINGS> EESCHEMA_SETTINGS::netlistSettingsFromJson(
958 const nlohmann::json& aObj )
959{
960 std::vector<EESCHEMA_SETTINGS::NETLIST_PLUGIN_SETTINGS> ret;
961
962 wxASSERT( aObj.is_array() );
963
964 for( const nlohmann::json& entry : aObj )
965 {
966 if( entry.empty() || !entry.is_object() )
967 continue;
968
969 if( !entry.contains( "name" ) || !entry.contains( "path" ) )
970 continue;
971
972 NETLIST_PLUGIN_SETTINGS plugin( entry.at( "name" ).get<wxString>(),
973 entry.at( "path" ).get<wxString>() );
974
975 if( entry.contains( "command" ) )
976 plugin.command = entry.at( "command" ).get<wxString>();
977
978 ret.emplace_back( plugin );
979 }
980
981 return ret;
982}
983
984
985BOM_CFG_PARSER::BOM_CFG_PARSER( std::vector<EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS>* aPluginList,
986 const char* aLine, const wxString& aSource ) :
987 DIALOG_BOM_CFG_LEXER( aLine, aSource )
988{
989 wxASSERT( aPluginList );
990 m_pluginList = aPluginList;
991}
992
993
995{
996 T token;
997
998 while( ( token = NextTok() ) != T_RIGHT )
999 {
1000 if( token == T_EOF)
1001 break;
1002
1003 if( token == T_LEFT )
1004 token = NextTok();
1005
1006 if( token == T_plugins )
1007 continue;
1008
1009 switch( token )
1010 {
1011 case T_plugin: // Defines a new plugin
1013 break;
1014
1015 default:
1016// Unexpected( CurText() );
1017 break;
1018 }
1019 }
1020}
1021
1022
1024{
1025 wxString str;
1027
1028 NeedSYMBOLorNUMBER();
1029 settings.path = FromUTF8();
1030
1031 T token;
1032
1033 while( ( token = NextTok() ) != T_RIGHT )
1034 {
1035 if( token == T_EOF)
1036 break;
1037
1038 switch( token )
1039 {
1040 case T_LEFT:
1041 break;
1042
1043 case T_cmd:
1044 NeedSYMBOLorNUMBER();
1045
1046 settings.command = FromUTF8();
1047
1048 NeedRIGHT();
1049 break;
1050
1051 case T_opts:
1052 {
1053 NeedSYMBOLorNUMBER();
1054
1055 wxString option = FromUTF8();
1056
1057 if( option.StartsWith( wxS( "nickname=" ), &str ) )
1058 settings.name = str;
1059
1060 NeedRIGHT();
1061 break;
1062 }
1063
1064 default:
1065 Unexpected( CurText() );
1066 break;
1067 }
1068 }
1069
1070 m_pluginList->emplace_back( settings );
1071}
APP_SETTINGS_BASE is a settings class that should be derived for each standalone KiCad application.
Definition: app_settings.h:110
virtual bool MigrateFromLegacy(wxConfigBase *aCfg) override
Migrates from wxConfig to JSON-based configuration.
bool migrateLibTreeWidth()
Migrates the library tree width setting from a single column (Item) to multi-column.
Used for parsing legacy-format bom plugin configurations.
BOM_CFG_PARSER(std::vector< EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS > *aPluginList, const char *aData, const wxString &aSource)
std::vector< EESCHEMA_SETTINGS::BOM_PLUGIN_SETTINGS > * m_pluginList
Color settings are a bit different than most of the settings objects in that there can be more than o...
void SetColor(int aLayer, const COLOR4D &aColor)
PANEL_ANNOTATE m_AnnotatePanel
static std::vector< BOM_PLUGIN_SETTINGS > DefaultBomPlugins()
PANEL_NETLIST m_NetlistPanel
nlohmann::json bomSettingsToJson() const
virtual bool MigrateFromLegacy(wxConfigBase *aLegacyConfig) override
Migrates from wxConfig to JSON-based configuration.
nlohmann::json netlistSettingsToJson() const
PANEL_SYM_CHOOSER m_SymChooserPanel
PAGE_SETTINGS m_PageSettings
static std::vector< BOM_PLUGIN_SETTINGS > bomSettingsFromJson(const nlohmann::json &aObj)
FIND_REPLACE_EXTRA m_FindReplaceExtra
PANEL_LIB_VIEW m_LibViewPanel
AUTOPLACE_FIELDS m_AutoplaceFields
static std::vector< NETLIST_PLUGIN_SETTINGS > netlistSettingsFromJson(const nlohmann::json &aObj)
PANEL_FIELD_EDITOR m_FieldEditorPanel
Hold an error message and may be used when throwing exceptions containing meaningful error messages.
Definition: ki_exception.h:76
bool fromLegacyString(wxConfigBase *aConfig, const std::string &aKey, const std::string &aDest)
Translates a legacy wxConfig string value to a given JSON pointer value.
bool Contains(const std::string &aPath) const
std::vector< PARAM_BASE * > m_params
The list of parameters (owned by this object)
void registerMigration(int aOldSchemaVersion, int aNewSchemaVersion, std::function< bool(void)> aMigrator)
Registers a migration from one schema version to another.
nlohmann::json & At(const std::string &aPath)
Wrappers for the underlying JSON API so that most consumers don't need json.hpp All of these function...
void Set(const std::string &aPath, ValueType aVal)
Stores a value into the JSON document Will throw an exception if ValueType isn't something that the l...
wxString GetFilename() const
Definition: json_settings.h:73
A color representation with 4 components: red, green, blue, alpha.
Definition: color4d.h:103
Like a normal param, but with custom getter and setter functions.
Definition: parameters.h:282
Represents a map of <std::string, Value>.
Definition: parameters.h:548
#define DEFAULT_BUS_WIDTH_MILS
The default noconnect size in mils.
#define DEFAULT_JUNCTION_DIAM
The default bus and wire entry size in mils.
#define DEFAULT_WIRE_WIDTH_MILS
The default bus width in mils. (can be changed in preference menu)
#define DEFAULT_LINE_WIDTH_MILS
The default wire width in mils. (can be changed in preference menu)
#define DEFAULT_TEXT_SIZE
Ratio of the font height to the baseline of the text above the wire.
#define _(s)
const nlohmann::json defaultBomPlugins
Default value for bom.plugins.
const wxAuiPaneInfo & defaultNetNavigatorPaneInfo()
const int eeschemaSchemaVersion
! Update the schema version whenever a migration is required
@ LAYER_SHEETNAME
Definition: layer_ids.h:367
@ LAYER_ERC_WARN
Definition: layer_ids.h:373
@ LAYER_SHEETLABEL
Definition: layer_ids.h:370
@ LAYER_PINNUM
Definition: layer_ids.h:354
@ LAYER_DEVICE
Definition: layer_ids.h:361
@ LAYER_BRIGHTENED
Definition: layer_ids.h:383
@ LAYER_HIDDEN
Definition: layer_ids.h:384
@ LAYER_HIERLABEL
Definition: layer_ids.h:353
@ LAYER_PINNAM
Definition: layer_ids.h:355
@ LAYER_GLOBLABEL
Definition: layer_ids.h:352
@ LAYER_WIRE
Definition: layer_ids.h:348
@ LAYER_NOTES
Definition: layer_ids.h:362
@ LAYER_ERC_ERR
Definition: layer_ids.h:374
@ LAYER_PIN
Definition: layer_ids.h:365
@ LAYER_VALUEPART
Definition: layer_ids.h:357
@ LAYER_BUS
Definition: layer_ids.h:349
@ LAYER_SCHEMATIC_CURSOR
Definition: layer_ids.h:381
@ LAYER_FIELDS
Definition: layer_ids.h:358
@ LAYER_DEVICE_BACKGROUND
Definition: layer_ids.h:376
@ LAYER_SCHEMATIC_DRAWINGSHEET
Definition: layer_ids.h:386
@ LAYER_LOCLABEL
Definition: layer_ids.h:351
@ LAYER_JUNCTION
Definition: layer_ids.h:350
@ LAYER_REFERENCEPART
Definition: layer_ids.h:356
@ LAYER_SHEET
Definition: layer_ids.h:366
@ LAYER_SELECTION_SHADOWS
Definition: layer_ids.h:385
@ LAYER_SCHEMATIC_BACKGROUND
Definition: layer_ids.h:380
@ LAYER_SHEETFILENAME
Definition: layer_ids.h:368
@ LAYER_NOCONNECT
Definition: layer_ids.h:371
@ LAYER_SCHEMATIC_GRID
Definition: layer_ids.h:378
This file contains miscellaneous commonly used macros and functions.
#define TO_UTF8(wxstring)
Convert a wxString to a UTF8 encoded C string for all wxWidgets build modes.
Definition: macros.h:96
see class PGM_BASE
@ RPT_SEVERITY_WARNING
@ RPT_SEVERITY_ERROR
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
Definition: single_top.cpp:115
std::vector< double > junction_size_mult_list
std::vector< BOM_PLUGIN_SETTINGS > plugins
std::map< std::string, int > field_widths
std::vector< NETLIST_PLUGIN_SETTINGS > plugins
WINDOW_STATE state
Definition: app_settings.h:93
wxString perspective
Definition: app_settings.h:95
unsigned int display
Definition: app_settings.h:85
Functions to provide common constants and other functions to assist in making a consistent UI.