mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Disable the color theme setting when using system style. Fixes #1981909 [Dark Mode always on when using System Default User Interface](https://bugs.launchpad.net/calibre/+bug/1981909)
This commit is contained in:
parent
11b84f7c90
commit
62207d5e85
@ -632,6 +632,14 @@ class ConfigWidget(ConfigWidgetBase, Ui_Form):
|
||||
self.sections_view.setSpacing(4)
|
||||
self.sections_view.setHorizontalScrollBarPolicy(Qt.ScrollBarPolicy.ScrollBarAlwaysOff)
|
||||
self.tabWidget.currentWidget().setFocus(Qt.FocusReason.OtherFocusReason)
|
||||
self.opt_ui_style.currentIndexChanged.connect(self.update_color_palette_state)
|
||||
self.update_color_palette_state()
|
||||
|
||||
def update_color_palette_state(self):
|
||||
if self.opt_ui_style.isVisible():
|
||||
enabled = self.opt_ui_style.currentData() == 'calibre'
|
||||
self.opt_color_palette.setEnabled(enabled)
|
||||
self.opt_color_palette_label.setEnabled(enabled)
|
||||
|
||||
def em_export_layout(self):
|
||||
filename = choose_save_file(self, 'em_import_export_field_list',
|
||||
|
@ -296,7 +296,7 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QLabel" name="label_20">
|
||||
<widget class="QLabel" name="opt_color_palette_label">
|
||||
<property name="text">
|
||||
<string>Color &palette (needs restart):</string>
|
||||
</property>
|
||||
@ -308,7 +308,9 @@
|
||||
<item row="2" column="1">
|
||||
<widget class="QComboBox" name="opt_color_palette">
|
||||
<property name="toolTip">
|
||||
<string>The colors to use for the calibre interface. By default the system colors are used. You can change this to force a light or dark color scheme. Note that if this is not set to system default then if the system wide color scheme is changed calibre will not follow it.</string>
|
||||
<string><p>The colors to use for the calibre interface. By default the system colors are used. You can change this to force a light or dark color scheme. Note that if this is not set to system default then if the system wide color scheme is changed calibre will not follow it.
|
||||
|
||||
<p>Also, if you set the calibre <i>User interface style</i> to <i>System default</i>, then this setting will not take effect and system colors will always be used.</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
|
Loading…
x
Reference in New Issue
Block a user