diff options
Diffstat (limited to 'ttystatus/index.py')
-rw-r--r-- | ttystatus/index.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/ttystatus/index.py b/ttystatus/index.py index 3e73502..0158037 100644 --- a/ttystatus/index.py +++ b/ttystatus/index.py @@ -21,13 +21,15 @@ class Index(ttystatus.Widget): '''Display the position of a value in a list of values.''' + static_width = False + def __init__(self, name, listname): self.name = name self.listname = listname self.value = None self.listvalue = [] - def render(self): + def render(self, render): try: index = self.listvalue.index(self.value) + 1 except ValueError: |