From d0fa8ce9a6f3bdfceb4815b3ac2f544116e09620 Mon Sep 17 00:00:00 2001 From: Damien Elmes Date: Sat, 25 Dec 2010 07:04:54 +0900 Subject: [PATCH] use the field model's font/colours for type answer support --- ankiqt/ui/view.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/ankiqt/ui/view.py b/ankiqt/ui/view.py index 705114e95..495ee14f5 100644 --- a/ankiqt/ui/view.py +++ b/ankiqt/ui/view.py @@ -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)