summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIan Ward <ian@excess.org>2014-01-02 22:10:34 -0500
committerIan Ward <ian@excess.org>2014-01-02 22:10:34 -0500
commit0a42d906a8b1af26efe604ea7fb1d69631ef919c (patch)
tree79d4626ec188763287c9205d2b0c2a34cd52c177
parentcb6b66f5adea03566f82b6fbe01340f7325184ac (diff)
downloadurwid-0a42d906a8b1af26efe604ea7fb1d69631ef919c.tar.gz
fix for packed columns not resizing when content changes #49
-rwxr-xr-xurwid/container.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/urwid/container.py b/urwid/container.py
index 245abc9..649e060 100755
--- a/urwid/container.py
+++ b/urwid/container.py
@@ -1989,7 +1989,8 @@ class Columns(Widget, WidgetContainerMixin, WidgetContainerListContentsMixin):
maxcol = size[0]
# FIXME: get rid of this check and recalculate only when
# a 'pack' widget has been modified.
- if maxcol == self._cache_maxcol and not PACK in self.column_types:
+ if maxcol == self._cache_maxcol and not any(
+ t == PACK for w, (t, n, b) in self.contents):
return self._cache_column_widths
widths = []