mirror of
https://github.com/ankitects/anki.git
synced 2025-09-22 07:52:24 -04:00
Use the same formatting for the browser and card history
This commit is contained in:
parent
1dfc4466f1
commit
857733c8e9
1 changed files with 2 additions and 2 deletions
|
@ -9,7 +9,7 @@ from aqt.utils import saveGeom, restoreGeom, showWarning, askUser, shortcut, \
|
||||||
tooltip, openHelp, addCloseShortcut, downArrow
|
tooltip, openHelp, addCloseShortcut, downArrow
|
||||||
from anki.sound import clearAudioQueue
|
from anki.sound import clearAudioQueue
|
||||||
from anki.hooks import addHook, remHook, runHook
|
from anki.hooks import addHook, remHook, runHook
|
||||||
from anki.utils import stripHTMLMedia, isMac
|
from anki.utils import stripHTMLMedia, fmtQA, isMac
|
||||||
import aqt.editor, aqt.modelchooser, aqt.deckchooser
|
import aqt.editor, aqt.modelchooser, aqt.deckchooser
|
||||||
|
|
||||||
class AddCards(QDialog):
|
class AddCards(QDialog):
|
||||||
|
@ -145,7 +145,7 @@ class AddCards(QDialog):
|
||||||
for nid in self.history:
|
for nid in self.history:
|
||||||
if self.mw.col.findNotes("nid:%s" % nid):
|
if self.mw.col.findNotes("nid:%s" % nid):
|
||||||
fields = self.mw.col.getNote(nid).fields
|
fields = self.mw.col.getNote(nid).fields
|
||||||
txt = stripHTMLMedia(", ".join(fields))
|
txt = fmtQA(", ".join(fields))
|
||||||
if len(txt) > 30:
|
if len(txt) > 30:
|
||||||
txt = txt[:30] + "..."
|
txt = txt[:30] + "..."
|
||||||
a = m.addAction(_("Edit \"%s\"") % txt)
|
a = m.addAction(_("Edit \"%s\"") % txt)
|
||||||
|
|
Loading…
Reference in a new issue