Skip to content
This repository has been archived by the owner on Apr 10, 2024. It is now read-only.

Commit

Permalink
Added button in the settings to open the config directory.
Browse files Browse the repository at this point in the history
May be useful to backup data or for moving it to another machine.
  • Loading branch information
mkrueger committed Aug 25, 2023
1 parent f613a00 commit 4982856
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 0 deletions.
1 change: 1 addition & 0 deletions i18n/de/icy_term.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ settings-scaling-linear = Linear
settings-terminal-category = Terminal
settings-terminal-console-beep-checkbox = Konsole Beep
settings-terminal-open-settings-dir-button = Einstellungsverzeichnis öffnen
settings-keybinds-category = Tastatur
settings-keybinds-disconnect = Trennen:
Expand Down
1 change: 1 addition & 0 deletions i18n/en/icy_term.ftl
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ settings-scaling-linear = Linear
settings-terminal-category = Terminal
settings-terminal-console-beep-checkbox = Console beep
settings-terminal-open-settings-dir-button = Open settings directory
settings-keybinds-category = Keybinds
settings-keybinds-disconnect = Disconnect:
Expand Down
11 changes: 11 additions & 0 deletions src/ui/dialogs/settings_dialog.rs
Original file line number Diff line number Diff line change
Expand Up @@ -192,6 +192,17 @@ fn show_terminal_settings(window: &mut MainWindow, ui: &mut egui::Ui) {
{
check_error!(window, window.options.store_options(), false);
}
if let Some(proj_dirs) = directories::ProjectDirs::from("com", "GitHub", "icy_term") {
if ui
.button(fl!(
crate::LANGUAGE_LOADER,
"settings-terminal-open-settings-dir-button"
))
.clicked()
{
open::that(proj_dirs.config_dir()).unwrap();
}
}
}

fn show_monitor_settings(window: &mut MainWindow, ui: &mut egui::Ui) {
Expand Down

0 comments on commit 4982856

Please sign in to comment.