mirror of
https://github.com/ankitects/anki.git
synced 2025-11-08 21:57:12 -05:00
use the field model's font/colours for type answer support
This commit is contained in:
parent
781324741a
commit
d0fa8ce9a6
1 changed files with 7 additions and 2 deletions
|
|
@ -148,8 +148,13 @@ class View(object):
|
|||
ret = "";
|
||||
s = difflib.SequenceMatcher(None, b, a)
|
||||
|
||||
sz = self.main.currentCard.cardModel.answerFontSize
|
||||
fn = self.main.currentCard.cardModel.answerFontFamily
|
||||
sz = 20
|
||||
fn = u"Arial"
|
||||
for fm in self.main.currentCard.fact.model.fieldModels:
|
||||
if fm.name == self.main.currentCard.cardModel.typeAnswer:
|
||||
sz = fm.quizFontSize
|
||||
fn = fm.quizFontFamily
|
||||
break
|
||||
st = "background: %s; color: #000; font-size: %dpx; font-family: %s;"
|
||||
ok = st % (passedCharColour, sz, fn)
|
||||
bad = st % (failedCharColour, sz, fn)
|
||||
|
|
|
|||
Loading…
Reference in a new issue