From 1514677f4280561c04200f73df743a17face2965 Mon Sep 17 00:00:00 2001 From: Mathieu Loiseau <mathieu.loiseau@univ-grenoble-alpes.fr> Date: Wed, 26 Jan 2022 09:37:18 +0100 Subject: [PATCH] height --- XML_Moodle.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/XML_Moodle.py b/XML_Moodle.py index f1da54d..75ce463 100755 --- a/XML_Moodle.py +++ b/XML_Moodle.py @@ -164,7 +164,7 @@ class TF(MCQ): self.choices.append(Answer("\\multiling{faux}{false}", a.attrib['fraction'], self.max, fb)) class ShortAnswer(TF): - def __init__(self, xmlQ,c,n,f,l=4): + def __init__(self, xmlQ,c,n,f,l=2): super().__init__(xmlQ,c,n,f) self.nb_lines = l if self.__class__.__name__ == "ShortAnswer": @@ -179,7 +179,7 @@ class ShortAnswer(TF): def __str__(self): res = """\\element{"""+self.category+"""}{ \\begin{"""+self.env+"""}{"""+self.id+"""}\\nbpoints{"""+score_2_str(self.max)+"""} - """+self.q+"\n\t\t\\AMCOpen{lineheight=0.66cm,lines="+str(self.nb_lines)+"}{" + """+self.q+"\n\t\t\\AMCOpen{lineheight=0.6cm,lines="+str(self.nb_lines)+"}{" for c in self.choices: res += "\\wrongchoice{"+score_2_str(c)+"}\\scoring{"+score_2_str(c)+"}" res += "\\correctchoice{"+score_2_str(self.max)+"}\\scoring{"+score_2_str(self.max)+"}" -- GitLab