Merge pull request #158 from henrikh/history-typography

Minor typographic changes in history browser
This commit is contained in:
Damien Elmes 2017-02-08 17:01:21 +10:00 committed by GitHub
commit b45b57d93d

View File

@ -144,8 +144,10 @@ class AddCards(QDialog):
for nid in self.history:
if self.mw.col.findNotes("nid:%s" % nid):
fields = self.mw.col.getNote(nid).fields
txt = stripHTMLMedia(",".join(fields))[:30]
a = m.addAction(_("Edit %s") % txt)
txt = stripHTMLMedia(", ".join(fields))
if len(txt) > 30:
txt = txt[:30] + "..."
a = m.addAction(_("Edit \"%s\"") % txt)
a.triggered.connect(lambda b, nid=nid: self.editHistory(nid))
else:
a = m.addAction(_("(Note deleted)"))