summaryrefslogtreecommitdiffstats
path: root/sdaps.diff
blob: 014471039d048d0a937b52a21c21e53fcd8859c7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
diff --git a/sdaps/report/answers.py b/sdaps/report/answers.py
index 919d26283ac7..50b1b0641ec4 100644
--- a/sdaps/report/answers.py
+++ b/sdaps/report/answers.py
@@ -72,7 +72,7 @@ class Choice(platypus.Flowable):
     value_width = 45
     gap = 6
 
-    def __init__(self, answer, value, significant=0):
+    def __init__(self, answer, count, value, significant=0):
         platypus.Flowable.__init__(self)
         if significant:
             stylesheet_name = 'Right_Highlight'
@@ -80,7 +80,7 @@ class Choice(platypus.Flowable):
             stylesheet_name = 'Right'
         self.answer = platypus.Paragraph(escape(answer), stylesheet[stylesheet_name])
         self.value = platypus.Paragraph(
-            u'%.2f %%' % (value * 100), stylesheet[stylesheet_name]
+            u'%.0f (%.2f %%)' % round(value*count, 0), (value * 100), stylesheet[stylesheet_name]
         )
         self.black_box = flowables.Box(
             value * self.box_width, self.box_height, self.box_depth,
diff --git a/sdaps/report/buddies.py b/sdaps/report/buddies.py
index 118594c55f2a..6bc6c99deddf 100644
--- a/sdaps/report/buddies.py
+++ b/sdaps/report/buddies.py
@@ -197,6 +197,7 @@ class Choice(Question):
                 story.append(
                     answers.Choice(
                         box.text,
+                        self.obj.calculate.count,
                         self.obj.calculate.values[box.value],
                         self.obj.calculate.significant[box.value]
                     )
diff --git a/tex/sdaps.cls b/tex/sdaps.cls
index af3aab480134..4baab750c9e9 100644
--- a/tex/sdaps.cls
+++ b/tex/sdaps.cls
@@ -1051,7 +1051,7 @@
     \setcounter{choicegroupnumchoices}{-1} %
   \fi %
   \immediate\write\sdapsoutfile{QObject-Choice=XAUTO. \unexpanded{#1}}%
-  {\usekomafont{choicegrouplinefont}\strut#1\strut} \@sdaps@choicegroup@boxes \\ %
+  {\usekomafont{choicegrouplinefont}\strut#1\strut\dotfill} \@sdaps@choicegroup@boxes \\ %
 }
 
 \providecommand*{\groupaddchoice}[1]{%