summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlan <alan@boum.org>2015-09-14 20:57:20 +0000
committerAlan <alan@boum.org>2015-09-14 20:57:25 +0000
commit87de554dc738e9043b848a862b5ff25ff1fe8006 (patch)
treed5ab2453ccda03cedc741f0928e3b0e803198e21
parentfafb47539e947a81863af48589311050cb9a3a10 (diff)
Adapt panes size to content
It often happens that more space than half of the window is needed to display the circuit names. This commit makes the panes non homogeneous in width and remove the scrollbar from the left pane so that it adapts to the required width.
-rwxr-xr-xtormonitor4
1 files changed, 3 insertions, 1 deletions
diff --git a/tormonitor b/tormonitor
index adca2d0..123bdd6 100755
--- a/tormonitor
+++ b/tormonitor
@@ -93,7 +93,6 @@ class TorMonitorWindow(Gtk.ApplicationWindow):
self.set_titlebar(headerbar)
grid = Gtk.Grid()
- grid.set_column_homogeneous(True)
self.add(grid)
self._infobar = Gtk.InfoBar()
@@ -127,6 +126,9 @@ class TorMonitorWindow(Gtk.ApplicationWindow):
scrolledwindow_circuits.set_property('expand', True)
scrolledwindow_circuits.set_property('halign', Gtk.Align.FILL)
scrolledwindow_circuits.set_property('valign', Gtk.Align.FILL)
+ scrolledwindow_circuits.set_policy(
+ hscrollbar_policy=Gtk.PolicyType.NEVER,
+ vscrollbar_policy=Gtk.PolicyType.AUTOMATIC)
grid.attach(scrolledwindow_circuits, 0, 1, 1, 1)
# Circuit details