core.generator.settings_last_path
- File:
EuljiroWorship/core/generator/settings_last_path.py
- Author:
Benjamin Jaedon Choi - https://github.com/saintbenjamin
- Affiliated Church:
The Eulji-ro Presbyterian Church [대한예수교장로회(통합) 을지로교회]
- Address:
The Eulji-ro Presbyterian Church, 24-10, Eulji-ro 20-gil, Jung-gu, Seoul 04549, South Korea
- Telephone:
+82-2-2266-3070
- E-mail:
euljirochurch [at] G.M.A.I.L. (replace [at] with @ and G.M.A.I.L as you understood.)
- License:
MIT License with Attribution Requirement (see LICENSE file for details); Copyright (c) 2025 The Eulji-ro Presbyterian Church.
Handles local UI state related to the last opened slide file path.
This module provides a minimal persistence layer for remembering the most recently opened slide JSON file in the generator UI. The path is stored as a small JSON file under the generator settings directory.
- core.generator.settings_last_path.load_last_path()[source]
Load the most recently opened slide file path.
This function reads the JSON file defined by
core.config.paths.SETTING_LAST_OPEN_FILEand extracts the stored"last_opened_file"value.If the settings file does not exist or the key is missing, the function safely returns None.
- Returns:
Absolute path of the last opened slide file, or None if no previous path is recorded.
- Return type:
str | None
- core.generator.settings_last_path.save_last_path(path)[source]
Save the most recently opened slide file path.
The given path is written to a small JSON file located at
core.config.paths.SETTING_LAST_OPEN_FILE.The parent directory is created automatically if it does not already exist.
- Parameters:
path (str) – Absolute path of the slide file to persist.
- Returns:
None