Tidy up handle size handling a little, but it is still insufficient, albeit not regressive

This commit is contained in:
Chris Jones 2010-04-07 22:23:31 +01:00
parent 09e8f37cb2
commit f9352625c4
2 changed files with 10 additions and 5 deletions

View File

@ -746,7 +746,10 @@ class PrefsEditor:
def on_handlesize_change_value(self, widget, scroll, value):
"""Handle size changed"""
self.config['handle_size'] = int(value)
value = int(value)
if value > 5:
value = 5
self.config['handle_size'] = value
self.config.save()
def on_focuscombo_changed(self, widget):

View File

@ -229,10 +229,12 @@ class Terminator(Borg):
"""Update configuration for the whole application"""
if self.config['handle_size'] in xrange(0, 6):
gtk.rc_parse_string("""style "terminator-paned-style" {
GtkPaned::handle_size = %s }
class "GtkPaned" style "terminator-paned-style" """ %
self.config['handle_size'])
gtk.rc_parse_string("""
style "terminator-paned-style" {
GtkPaned::handle_size = %s
}
class "GtkPaned" style "terminator-paned-style"
""" % self.config['handle_size'])
gtk.rc_reset_styles(gtk.settings_get_default())
# Cause all the terminals to reconfigure