- when changing the style for the decorations from Preferences, now change is applied immediately

This commit is contained in:
Marius Stanciu
2022-11-09 19:55:59 +02:00
committed by Marius
parent 9ec2ee2920
commit 8b4423dc0f
3 changed files with 9 additions and 0 deletions

View File

@@ -396,6 +396,9 @@ class GeneralGUIPrefGroupUI(OptionsGroupUI):
qsettings = QSettings("Open Source", "FlatCAM")
qsettings.setValue('style', str(style))
new_style = QtWidgets.QStyleFactory.keys()[int(style)]
QtWidgets.QApplication.setStyle(new_style)
# This will write the setting to the platform specific storage.
del qsettings