diff options
author | Michael Hoang <enzime@users.noreply.github.com> | 2016-08-21 11:59:45 +1000 |
---|---|---|
committer | Michael Hoang <enzime@users.noreply.github.com> | 2016-08-21 11:59:45 +1000 |
commit | 282d932fc027f25a29219ce231f7260ad26a9f33 (patch) | |
tree | 2d1d94046e5bc5c20dba2aa0b7f71aa85ebb6119 | |
parent | b093aa028839e26d19bf7ceefaf4666a036ec5da (diff) | |
download | ranger-282d932fc027f25a29219ce231f7260ad26a9f33.tar.gz |
Change how column widths are calculated
By changing it, this means the columns will use the entire width if the geometry allows for it
-rw-r--r-- | ranger/gui/widgets/view_multipane.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/ranger/gui/widgets/view_multipane.py b/ranger/gui/widgets/view_multipane.py index 7b77b3db..f8efd80f 100644 --- a/ranger/gui/widgets/view_multipane.py +++ b/ranger/gui/widgets/view_multipane.py @@ -42,11 +42,11 @@ class ViewMultipane(ViewBase): def resize(self, y, x, hei, wid): ViewBase.resize(self, y, x, hei, wid) - column_width = int(float(wid) / len(self.columns)) + column_width = int((float(wid) - len(self.columns) + 1) / len(self.columns)) left = 0 top = 0 for i, column in enumerate(self.columns): - column.resize(top, left, hei, max(1, column_width - 1)) - left += column_width + column.resize(top, left, hei, max(1, column_width)) + left += column_width + 1 column.need_redraw = True self.need_redraw = True |