Skip to content

Commit aad98f6

Browse files
committed
FEATURE: presist the doccumentation annotation setting
1 parent 7fef9e5 commit aad98f6

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

MethodicConfigurator/frontend_tkinter_parameter_editor.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,9 @@ def legend_frame(self, config_subframe: ttk.Frame, font_family: str) -> None:
367367

368368
def __create_parameter_area_widgets(self) -> None:
369369
self.show_only_differences = tk.BooleanVar(value=False)
370-
self.annotate_params_into_files = tk.BooleanVar(value=False)
370+
self.annotate_params_into_files = tk.BooleanVar(
371+
value=bool(ProgramSettings.get_setting("annotate_docs_into_param_files"))
372+
)
371373

372374
# Create a Scrollable parameter editor table
373375
self.parameter_editor_table = ParameterEditorTable(self.main_frame, self.local_filesystem, self)
@@ -400,6 +402,9 @@ def __create_parameter_area_widgets(self) -> None:
400402
text=_("Annotate docs into .param files"),
401403
state="normal" if self.local_filesystem.doc_dict else "disabled",
402404
variable=self.annotate_params_into_files,
405+
command=lambda: ProgramSettings.set_setting(
406+
"annotate_docs_into_param_files", self.annotate_params_into_files.get()
407+
),
403408
)
404409
annotate_params_checkbox.pack(side=tk.TOP, anchor=tk.NW)
405410
show_tooltip(

0 commit comments

Comments
 (0)