Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

PDF Report and Formatting

More
3 weeks 2 days ago #273207 by holch
Please help us help you and fill where relevant:
Your LimeSurvey version: LimeSurvey Community Edition Version 6.15.22+251103
Own server or LimeSurvey hosting: Own server
Survey theme/template: NA
==================
I am trying to implement a digital signature process for participating in research. 

So I have a confidentiality agreement, where I have a long text, formatted in a "text display" questions. 
I ask for a couple of personal data (Name, ID number, City, Email, Telephone) and at the end I use the "Signature Pad" question theme for them to sign.

Then I use the PDFReport plugin to create a PDF that displays the confidentiality agreement first via {term.question} then a couple of the data collected and then the signature as an image. So far, it works perfect.

However, the created PDF is weird. Normal text is tiny, really tiny. And headers are huge, really huge. Everything is disproportionate. And if you use html lists, the text on the second line overwrites the first line.

First I thought the report tries to fit everything from one question onto one page, so I split the "term" into 3 text display questions. No change.

Does anyone have any tips on how to get the PDF formatted more "normal" and how to solve the issue with lists?

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

More
3 weeks 2 days ago #273208 by holch
Replied by holch on topic PDF Report and Formatting
Here to illustrate what I mean:
 

So the first red marker shows an example of how for html lists the list items seem to use just one line and just write over previous lines.

The second marker shows where I tried to solve this problem with a table. However, the table distributes the columns 50%, which makes it look weird.

Overall, if the normal text would be a little bigger (in the actual PDF it is more or less readable) and the List items would work better, this would be a very good solution. Because the inclusion of the image created by the signature pad works pretty good, just the formatting of the text is horrible. I mean, I can probably use it, but it doesn't look very professional.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

More
3 weeks 2 days ago - 3 weeks 1 day ago #273209 by holch
Replied by holch on topic PDF Report and Formatting
I might have found a solution. Originally the font sizes were in px. I changed it to pt and the fonts look more reasonable. I also got rid of the headers and formatted them "by hand".

I got rid of all the ULs and OLs in HTML and just formatted them differently. Looks a lot better now.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.
Last edit: 3 weeks 1 day ago by holch.

Please Log in to join the conversation.

More
3 weeks 2 days ago #273210 by holch
Replied by holch on topic PDF Report and Formatting
No I just need to find out how to get rid of the huge title which is the survey title.

Rest is acceptable.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

More
3 weeks 1 day ago - 3 weeks 1 day ago #273213 by Joffm
Replied by Joffm on topic PDF Report and Formatting
Hallo, @holch

This is a bit strange.
I created this small report (rather quick and dirty)
Code:
<p style="margin-bottom: 0cm;font-weight:bold;font-size:11pt">OBJETIVO DA PESQUISA (11pt)</p>
 
<p style="font-size:8pt">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.</p>
 
<p style="margin-bottom: 0cm;font-weight:bold;font-size:11pt">VISAO GERAL DO PROJETO (11pt)</p>
<ul style="font-size:8pt">
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut</p></li>
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit amet, consetetur sadipscing elitr</p></li>
    <li><p>Lorem ipsum dolor sit ametr invidunt ut</p></li>
</ul>
 
<p style="margin-bottom: 0cm;font-weight:bold;font-size:11pt">O texto a seguir (11pt)</p>
<p style="font-size:8pt">accumsan et iusto odio dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Lorem ipsum dolor sit amet, consectetuer</p>
<p style="margin-bottom: 0cm;font-weight:bold;font-size:9pt">1. OS PRODUTOS (9pt)</p>
<ol style="font-size:8pt">
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut</p></li>
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit amet, consetetur sadipscing elitr</p></li>
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit ametr invidunt ut</p>
      <ul>
        <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut</p></li>
        <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit ametr invidunt ut</p></li>
      </ul>
    </li>
    <li><p style="margin-bottom: 0cm">Lorem ipsum dolor sit ametr invidunt ut</p></li>
</ol>
...
 
<p style="margin-bottom: 0cm;font-weight:bold;font-size:9pt">13. LOREM IPSUM (9pt)</p>
<p style="font-size:7pt">;(Nur noch 7pt) Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet. Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.</p>


and got (with LimeMpdf)
 

(without LimeMpdf)
 

Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
Last edit: 3 weeks 1 day ago by Joffm.
The following user(s) said Thank You: DenisChenu, holch

Please Log in to join the conversation.

More
3 weeks 1 day ago #273214 by holch
Replied by holch on topic PDF Report and Formatting
Your example looks pretty good.

To be honest, after I figured out that the putting the font size in "pt" instead of "px" helps to increase the font, I don't think I had the time or nerves to do more experiments and just got rid of the lists, to avoid the issue. Not sure if pt would have solved the issue with UL an OL lists.

I don't think that I have LimePDF and I didn't want to experiment anymore yesterday night. I needed the thing to more or less work, and it does. It is not the pretties at the moment, but it serves its purpose. There is a PDF, with the text of the confidentiality agreement, there is the data of the signer and there is the image of the signature, and I have it all in an PDF. So this is the basics that I wanted.

For the future I will have to look into a nicer formatting for sure.

Couldn't get a line break to work, for example.

Probably need to look into LimeMpdf for future versions of this.

I am already quite happy that I got this to work with the signature pad image and everything, creating a PDF file with the signed document. Simple digital signature, saves me quite a bit of money on the commercial solutions and is just as good (or better) to what we had before, with people just signing a PDF file in call kind of strange ways (printing, signing, taking a photo, etc.)

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

More
2 weeks 6 days ago #273222 by DenisChenu
Hi Holch : next tome ping me at discord.

Else : send the HTML you use, clearly included HTM can broke  easily.

And LimeMPDF is best now.

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.
The following user(s) said Thank You: holch

Please Log in to join the conversation.

More
2 weeks 6 days ago #273234 by holch
Replied by holch on topic PDF Report and Formatting
Hi Denis,

Thank you for responding here! But I am currently without discord. Guess I need to set it up again.

In anyway, thank you for the excellent work with PDFReport and the signature pad.

Makes a nice and easy digital signature. Might not be as legally binding as DocuSign, but it is not much different than paper signatures that we had before.

So we collected over 900 signatures since Friday, which I consider a success.

Will need to look a little further into this to make the PDF more visually pleasing for the future, but I am actually quite happy with how it turned out.

Help us to help you!
  • Provide your LS version and where it is installed (own server, uni/employer, SaaS hosting, etc.).
  • Always provide a LSS file (not LSQ or LSG).
Note: I answer at this forum in my spare time, I'm not a LimeSurvey GmbH employee.

Please Log in to join the conversation.

Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose