summaryrefslogtreecommitdiff
path: root/alot/buffers.py
diff options
context:
space:
mode:
authorPatrick Totzke <patricktotzke@gmail.com>2012-02-25 22:36:39 +0000
committerPatrick Totzke <patricktotzke@gmail.com>2012-02-25 22:36:39 +0000
commitc4aa6ca848707550906444017db55ba0ccfae34f (patch)
treef9b2e8ef14ae7143f3523eca97c690c923edf787 /alot/buffers.py
parent42eae6a471599cfb83b5515a4810cfeac39bf907 (diff)
display original tagstrings in taglist buffers
this makes the taglist buffer append the original tagstring in crackets to listed tags that display translated strings
Diffstat (limited to 'alot/buffers.py')
-rw-r--r--alot/buffers.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/alot/buffers.py b/alot/buffers.py
index f8d70de3..ba6f45b7 100644
--- a/alot/buffers.py
+++ b/alot/buffers.py
@@ -344,7 +344,10 @@ class TagListBuffer(Buffer):
key=unicode.lower)
for (num, b) in enumerate(displayedtags):
tw = widgets.TagWidget(b)
- lines.append(urwid.Columns([('fixed', tw.width(), tw)]))
+ rows = [('fixed', tw.width(), tw)]
+ if tw.translated is not b:
+ rows.append(urwid.Text('(%s)' % b))
+ lines.append(urwid.Columns(rows, dividechars=1))
self.taglist = urwid.ListBox(urwid.SimpleListWalker(lines))
self.body = self.taglist