From 3bc72418944ec0bfcb1efbc6f23a4882e9d0699c Mon Sep 17 00:00:00 2001 From: Walter Bender Date: Mon, 25 Feb 2013 01:21:57 +0000 Subject: more robust toolbar resizing algorithm --- diff --git a/abacus_window.py b/abacus_window.py index 59bfeb7..3085471 100644 --- a/abacus_window.py +++ b/abacus_window.py @@ -797,10 +797,12 @@ class Abacus(): self.height = Gdk.Screen.height() - GRID_CELL_SIZE if self.width > self.height: self.scale = 1.33 * Gdk.Screen.height() / 900.0 + if gtk.gdk.screen_width() / 14 >= style.GRID_CELL_SIZE: self.activity.hex.show() self.activity.binary.show() else: self.scale = 1.33 * Gdk.Screen.width() / 1200.0 + if gtk.gdk.screen_width() / 14 < style.GRID_CELL_SIZE: self.activity.hex.hide() self.activity.binary.hide() self.canvas.set_size_request(Gdk.Screen.width(), Gdk.Screen.height()) -- cgit v0.9.1