diff options
author | Aneesh Dogra <lionaneesh@gmail.com> | 2012-12-09 06:02:25 (GMT) |
---|---|---|
committer | Aneesh Dogra <lionaneesh@gmail.com> | 2012-12-09 06:02:25 (GMT) |
commit | 3dafb551e27e759d50f235e4a893cb9f468973e2 (patch) | |
tree | c8e79850ef0b9516ea558ec99a5519c0b75c41e4 /purk | |
parent | 7a132333bd1982b723e164f16c691500ffb08bd8 (diff) |
Some more fixes.
Diffstat (limited to 'purk')
-rw-r--r-- | purk/widgets.py | 7 | ||||
-rw-r--r-- | purk/windows.py | 22 |
2 files changed, 16 insertions, 13 deletions
diff --git a/purk/widgets.py b/purk/widgets.py index e7fe793..d3a06c4 100644 --- a/purk/widgets.py +++ b/purk/widgets.py @@ -586,6 +586,8 @@ class TextOutput(Gtk.TextView): buffer = Gtk.TextBuffer.new(tag_table) Gtk.TextView.__init__(self) + self.buffer = self.get_buffer() + self.buffer = buffer self.core = core self.events = core.events self.win = window @@ -625,8 +627,9 @@ class TextOutput(Gtk.TextView): self.autoscroll = adj.value + adj.page_size >= adj.upper vadj.connect("value-changed", set_scroll) - - self.connect("set-scroll-adjustments", setup_scroll) + # FIXME: set-scroll adjustment is no longer emitted. + # Check http://developer.gnome.org/gtk3/3.3/ch25s02.html + #self.connect("set-scroll-adjustments", setup_scroll) self.connect("size-allocate", self.scroll) def set_cursor(widget): diff --git a/purk/windows.py b/purk/windows.py index 9301a86..d00b8f7 100644 --- a/purk/windows.py +++ b/purk/windows.py @@ -160,13 +160,13 @@ class SimpleWindow(Window): self.focus = self.input.grab_focus self.connect("key-press-event", self.transfer_text) - self.pack_end(self.input, expand=False) - + self.pack_end(self.input, False, True, 0) + topbox = Gtk.ScrolledWindow() topbox.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC) topbox.add(self.output) - self.pack_end(topbox) + self.pack_end(topbox, False, True, 0) self.show_all() @@ -191,15 +191,15 @@ class StatusWindow(Window): self.manager = core.manager botbox = Gtk.HBox() botbox.add(self.input) - botbox.pack_end(self.nick_label, expand=False) + botbox.pack_end(self.nick_label, False, True, 0) - self.pack_end(botbox, expand=False) + self.pack_end(botbox, False, True, 0) topbox = Gtk.ScrolledWindow() topbox.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC) topbox.add(self.output) - self.pack_end(topbox) + self.pack_end(topbox, False, True, 0) self.show_all() @@ -214,9 +214,9 @@ class QueryWindow(Window): botbox = Gtk.HBox() botbox.pack_start(self.input) - botbox.pack_end(self.nick_label, expand=False) + botbox.pack_end(self.nick_label, False, True, 0) - self.pack_end(botbox, expand=False) + self.pack_end(botbox, False, True, 0) topbox = Gtk.ScrolledWindow() topbox.set_policy(Gtk.PolicyType.NEVER, Gtk.PolicyType.AUTOMATIC) @@ -284,9 +284,9 @@ class ChannelWindow(Window): botbox = Gtk.HBox() botbox.pack_start(self.input) - botbox.pack_end(self.nick_label, expand=False) + botbox.pack_end(self.nick_label, False, True, 0) - self.pack_end(botbox, expand=False) + self.pack_end(botbox, False, True, 0) pane = Gtk.HPaned() pane.pack1(topbox, resize=True, shrink=False) @@ -297,7 +297,7 @@ class ChannelWindow(Window): pane.connect("button-press-event", move_nicklist) pane.connect("button-release-event", drop_nicklist) - self.pack_end(pane) + self.pack_end(pane, False, True, 0) self.show_all() def is_channel(self): |