mirror of
https://github.com/ankitects/anki.git
synced 2025-09-19 06:22:22 -04:00
Merge pull request #21 from ospalh/id-correct-answer
Wrap the "Correct answer was" bit in a span with an id.
This commit is contained in:
commit
beb580117c
1 changed files with 3 additions and 1 deletions
|
@ -376,7 +376,9 @@ Please run Tools>Maintenance>Empty Cards""")
|
|||
# compare with typed answer
|
||||
res = self.correct(cor, given)
|
||||
if cor != given:
|
||||
res += "<br>" + _("Correct answer was:") + "<br>" + cor
|
||||
# Wrap the extra text in an id-ed span.
|
||||
res += '<span id=rightanswer><br> {0} <br> {1} </span>'.format(
|
||||
_("Correct answer was:"), cor)
|
||||
# and update the type answer area
|
||||
return re.sub(self.typeAnsPat, """
|
||||
<span style="font-family: '%s'; font-size: %spx">%s</span>""" %
|
||||
|
|
Loading…
Reference in a new issue