commit 680b1a44bb0060847d65b4eab1390b513c3330f4
parent 34f59ebea3db165c1d77718f7fe8abbc80a800d2
Author: Eric Davis <edavis@insanum.com>
Date: Fri, 27 Jun 2014 12:27:44 -0700
added search string to status bar in the note title view
Diffstat:
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/sncli.py b/sncli.py
@@ -215,6 +215,9 @@ def filter_notes(search_string=None):
self.all_notes, match_regex, self.all_notes_cnt = \
self.ndb.filter_notes(self.search_string)
+ def get_search_string():
+ return self.search_string
+
def list_get_note_content(index, tabstop):
lines = []
for l in self.all_notes[index].note['content'].split('\n'):
@@ -379,9 +382,13 @@ def update_status(self):
cur = self.listbox.focus_position
total = len(self.listbox.body.positions())
+ hdr = u'Simplenote'
+ if get_search_string() != None:
+ hdr += ' - Search: ' + get_search_string()
+
status_title = \
urwid.AttrMap(urwid.Text(
- u'Simplenote',
+ hdr,
wrap='clip'),
'status_bar')
status_index = \