From 95e73b141ca8f3618701ff59658ef519353cc7c0 Mon Sep 17 00:00:00 2001 From: Chandler J Date: Fri, 12 Apr 2024 20:44:47 -0600 Subject: major changes: - Can now save/load themes which entails the color scheme and wallpaper - Can now use themes to load colors independent of background image - refactoring to make code less bad --- src/load_config.py | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/load_config.py') diff --git a/src/load_config.py b/src/load_config.py index dbc0d81..5768b3e 100644 --- a/src/load_config.py +++ b/src/load_config.py @@ -20,6 +20,7 @@ class systemConfig: num_palettes = 15 use_dmenu = False generate_i3_lock = False + theme_directory = "" def __init__(self): print('[bold green]Loading configuration files') @@ -36,6 +37,7 @@ class systemConfig: self.polybar_config = f'/home/{self.username}/.config/polybar/config.ini' if os.path.exists(f'/home/{self.username}/.config/rofi/config.rasi'): self.rofi_config = f'/home/{self.username}/.config/rofi/config.rasi' + if os.path.exists(f'/home/{self.username}/.config/instantrice/'): self.rice_config = f'/home/{self.username}/.config/instantrice/config.rice' self.get_user_preferences() @@ -80,3 +82,8 @@ class systemConfig: else: print(f'Invalid configuration parameter at line {i}:\n{line}.\nUsing default \ configuration of 15 palettes.') + if "theme_directory" in line: + match = line.strip().split(' ') + if not match[2].endswith('/'): + match[2] += '/' + self.theme_directory = match[2] -- cgit v1.2.3