config.patch (2232B)
1 diff --git c/main.py i/main.py 2 index 5164746..6a2398e 100644 3 --- c/main.py 4 +++ i/main.py 5 @@ -31,13 +31,13 @@ if __name__ == '__main__': 6 7 # Ensure we create the necesary folders if they don't exist 8 if not os.path.exists(c.FOLDER_DATA): 9 - os.mkdir(c.FOLDER_DATA) 10 + os.makedirs(c.FOLDER_DATA) 11 if not os.path.exists(c.FOLDER_OUTPUT): 12 - os.mkdir(c.FOLDER_OUTPUT) 13 + os.makedirs(c.FOLDER_OUTPUT) 14 if not os.path.exists(c.FOLDER_CONFIGS): 15 - os.mkdir(c.FOLDER_CONFIGS) 16 + os.makedirs(c.FOLDER_CONFIGS) 17 if not os.path.exists(c.FOLDER_USER_CONFIGS): 18 - os.mkdir(c.FOLDER_USER_CONFIGS) 19 + os.makedirs(c.FOLDER_USER_CONFIGS) 20 21 # Start the program 22 window = MainWindowHandlers() 23 diff --git c/src/core/constants.py i/src/core/constants.py 24 index 69e53c8..1fae240 100644 25 --- c/src/core/constants.py 26 +++ i/src/core/constants.py 27 @@ -19,13 +19,14 @@ connect the VAL and CONFIG_STYLE in the DATA_GROUPS dictionary 28 """ 29 30 from PyQt5.QtCore import Qt 31 +from os.path import expanduser 32 33 34 # Resource Strings 35 -FOLDER_DATA = 'data' 36 -FOLDER_OUTPUT = 'output' 37 -FOLDER_CONFIGS = 'configs' 38 -FOLDER_USER_CONFIGS = 'configs/user' 39 +FOLDER_DATA = expanduser('~/.local/share/map-stylizer/data') 40 +FOLDER_OUTPUT = expanduser('~/.local/share/map-stylizer/output') 41 +FOLDER_CONFIGS = expanduser('~/.config/map-stylizer/configs') 42 +FOLDER_USER_CONFIGS = expanduser('~/.config/map-stylizer/configs/user') 43 FILE_ICON = 'src/resources/icon.png' 44 FILE_CONFIG = 'user.config' 45 46 diff --git c/src/gui/MainWindow/MainWindowHandlers.py i/src/gui/MainWindow/MainWindowHandlers.py 47 index 2e491d6..c2223bc 100644 48 --- c/src/gui/MainWindow/MainWindowHandlers.py 49 +++ i/src/gui/MainWindow/MainWindowHandlers.py 50 @@ -228,7 +228,7 @@ class MainWindowHandlers(QMainWindow): 51 The user has clicked the button to save the map as an image 52 """ 53 fileName, _ = QFileDialog.getSaveFileName( 54 - self, 'Save Image', 'output', 'Image Files (*.jpg)') 55 + self, 'Save Image', 'output', 'Image Files (*.png)') 56 57 if fileName: 58 self._map.saveImage(self._box_max_dim.value(), fileName)