Fix unwanted seperator size change, and increase granularity of dim/transparent sliders
This commit is contained in:
parent
80b157ee33
commit
7f071e0d7e
|
@ -861,10 +861,12 @@
|
|||
</child>
|
||||
<child>
|
||||
<object class="GtkHScale" id="inactive_color_offset">
|
||||
<property name="width_request">100</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="adjustment">adjustment7</property>
|
||||
<property name="round_digits">1</property>
|
||||
<property name="round_digits">2</property>
|
||||
<property name="digits">2</property>
|
||||
<property name="value_pos">left</property>
|
||||
<signal name="change-value" handler="on_inactive_color_offset_change_value" swapped="no"/>
|
||||
</object>
|
||||
|
@ -2839,7 +2841,8 @@
|
|||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="adjustment">background_darkness_scale</property>
|
||||
<property name="round_digits">1</property>
|
||||
<property name="round_digits">2</property>
|
||||
<property name="digits">2</property>
|
||||
<property name="value_pos">bottom</property>
|
||||
<signal name="change-value" handler="on_darken_background_scale_change_value" swapped="no"/>
|
||||
</object>
|
||||
|
|
|
@ -826,9 +826,12 @@ class PrefsEditor:
|
|||
self.config['scrollbar_position'] = value
|
||||
self.config.save()
|
||||
|
||||
def on_darken_background_scale_change_value(self, widget, scroll, value):
|
||||
def on_darken_background_scale_change_value(self, widget, scroll, _value_not_rounded):
|
||||
"""Background darkness setting changed"""
|
||||
self.config['background_darkness'] = round(value, 2)
|
||||
value = widget.get_value() # This one is rounded according to the UI.
|
||||
if value > 1.0:
|
||||
value = 1.0
|
||||
self.config['background_darkness'] = value
|
||||
self.config.save()
|
||||
|
||||
def on_palette_combobox_changed(self, widget):
|
||||
|
@ -980,16 +983,18 @@ class PrefsEditor:
|
|||
self.config['title_transmit_fg_color'] = color2hex(widget)
|
||||
self.config.save()
|
||||
|
||||
def on_inactive_color_offset_change_value(self, widget, scroll, value):
|
||||
def on_inactive_color_offset_change_value(self, widget, scroll, _value_not_rounded):
|
||||
"""Inactive color offset setting changed"""
|
||||
value = widget.get_value() # This one is rounded according to the UI.
|
||||
if value > 1.0:
|
||||
value = 1.0
|
||||
self.config['inactive_color_offset'] = round(value, 2)
|
||||
self.config['inactive_color_offset'] = value
|
||||
self.config.save()
|
||||
|
||||
def on_handlesize_change_value(self, widget, scroll, value):
|
||||
def on_handlesize_change_value(self, widget, scroll, _value_not_rounded):
|
||||
"""Handle size changed"""
|
||||
value = int(value)
|
||||
value = widget.get_value() # This one is rounded according to the UI.
|
||||
value = int(value) # Cast to int.
|
||||
if value > 5:
|
||||
value = 5
|
||||
self.config['handle_size'] = value
|
||||
|
|
Loading…
Reference in New Issue