Fix separator sizing
This commit is contained in:
parent
9fa9c0e45a
commit
73ba77ee5e
|
@ -39,6 +39,7 @@ class Terminator(Borg):
|
||||||
groups = None
|
groups = None
|
||||||
config = None
|
config = None
|
||||||
keybindings = None
|
keybindings = None
|
||||||
|
style_provider = None
|
||||||
|
|
||||||
origcwd = None
|
origcwd = None
|
||||||
dbus_path = None
|
dbus_path = None
|
||||||
|
@ -363,14 +364,23 @@ class Terminator(Borg):
|
||||||
def reconfigure(self):
|
def reconfigure(self):
|
||||||
"""Update configuration for the whole application"""
|
"""Update configuration for the whole application"""
|
||||||
|
|
||||||
|
if self.style_provider is not None:
|
||||||
|
Gtk.StyleContext.remove_provider_for_screen(
|
||||||
|
Gdk.Screen.get_default(),
|
||||||
|
self.style_provider)
|
||||||
|
self.style_provider = None
|
||||||
if self.config['handle_size'] in xrange(0, 6):
|
if self.config['handle_size'] in xrange(0, 6):
|
||||||
Gtk.rc_parse_string("""
|
css = """
|
||||||
style "terminator-paned-style" {
|
GtkPaned {
|
||||||
GtkPaned::handle_size = %s
|
-GtkPaned-handle-size: %s
|
||||||
}
|
}
|
||||||
class "GtkPaned" style "terminator-paned-style"
|
""" % self.config['handle_size']
|
||||||
""" % self.config['handle_size'])
|
self.style_provider = Gtk.CssProvider()
|
||||||
Gtk.rc_reset_styles(Gtk.Settings.get_default())
|
self.style_provider.load_from_data(css)
|
||||||
|
Gtk.StyleContext.add_provider_for_screen(
|
||||||
|
Gdk.Screen.get_default(),
|
||||||
|
self.style_provider,
|
||||||
|
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION)
|
||||||
|
|
||||||
# Cause all the terminals to reconfigure
|
# Cause all the terminals to reconfigure
|
||||||
for terminal in self.terminals:
|
for terminal in self.terminals:
|
||||||
|
|
Loading…
Reference in New Issue