- Posts: 9
- Thank you received: 0
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
Pie Chart fonts missing in PDF
- deliot
- Topic Author
- Offline
- New Member
Less
More
5 years 10 months ago #168054
by deliot
Pie Chart fonts missing in PDF was created by deliot
Attachments:
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11746
- Thank you received: 2750
5 years 10 months ago #168059
by holch
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
Replied by holch on topic Pie Chart fonts missing in PDF
The most basic information is missing: Which LS version? Without that, it will be very difficult to reproduce.
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
The topic has been locked.
- deliot
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
5 years 10 months ago #168070
by deliot
Replied by deliot on topic Pie Chart fonts missing in PDF
Forgot...
Version 3.7.1+180424
Chrome Browser
Ubuntu 16.04 installation
Version 3.7.1+180424
Chrome Browser
Ubuntu 16.04 installation
The topic has been locked.
- deliot
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
5 years 10 months ago #168071
by deliot
Replied by deliot on topic Pie Chart fonts missing in PDF
Attachments:
The topic has been locked.
- gbl_amorim
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
5 years 5 months ago #174725
by gbl_amorim
Replied by gbl_amorim on topic Pie Chart fonts missing in PDF
Got the same problem here, did you solve it?
The topic has been locked.
- DenisChenu
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 13907
- Thank you received: 2546
5 years 5 months ago #174742
by DenisChenu
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
Replied by DenisChenu on topic Pie Chart fonts missing in PDF
holch wrote: The most basic information is missing: Which LS version? Without that, it will be very difficult to reproduce.
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand , plugin development .
I don't answer to private message.
The topic has been locked.
- gbl_amorim
- Offline
- New Member
Less
More
- Posts: 6
- Thank you received: 0
5 years 5 months ago - 5 years 5 months ago #174748
by gbl_amorim
Replied by gbl_amorim on topic Pie Chart fonts missing in PDF
Version: 3.14.5
I did some changes in the code and now I can show the legend, but they're wrong and still no percentage in any slice.
Edit: the legend isn't wrong but I would like to show the question text in the place of the numbers.
Edit2: I just figure out how to make the percentages work, in limesurvey\application\helpers\admin\statistics_helper.php where the 3D pie chart is created the "setFontProprieties" was poiting to '$rootdir."/fonts/".$chartfontfile', but the fonts are in '$rootdir."/assets/fonts/".$chartfontfile'. Now I just need to change te text.
Just a question, the option "graph type" was supposed to work just when i select html format or for pdf too? Because it doesn't, the graph type shown is the one i've set when creating the question.
I did some changes in the code and now I can show the legend, but they're wrong and still no percentage in any slice.
Edit: the legend isn't wrong but I would like to show the question text in the place of the numbers.
Edit2: I just figure out how to make the percentages work, in limesurvey\application\helpers\admin\statistics_helper.php where the 3D pie chart is created the "setFontProprieties" was poiting to '$rootdir."/fonts/".$chartfontfile', but the fonts are in '$rootdir."/assets/fonts/".$chartfontfile'. Now I just need to change te text.
Just a question, the option "graph type" was supposed to work just when i select html format or for pdf too? Because it doesn't, the graph type shown is the one i've set when creating the question.
Attachments:
Last edit: 5 years 5 months ago by gbl_amorim.
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11746
- Thank you received: 2750
5 years 5 months ago #174749
by holch
Update to the latest version, see if the problem persists. If it persists: make a bug report. Your changes might be overwritten by any future update you might make, so I think it is best that it is fixed in the core, rather than you hacking the code. Might be a temporary solution, but is not future proof.
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
Replied by holch on topic Pie Chart fonts missing in PDF
Edit2: I just figure out how to make the percentages work, in limesurvey\application\helpers\admin\statistics_helper.php where the 3D pie chart is created the "setFontProprieties" was poiting to '$rootdir."/fonts/".$chartfontfile', but the fonts are in '$rootdir."/assets/fonts/".$chartfontfile'. Now I just need to change te text.
Update to the latest version, see if the problem persists. If it persists: make a bug report. Your changes might be overwritten by any future update you might make, so I think it is best that it is fixed in the core, rather than you hacking the code. Might be a temporary solution, but is not future proof.
I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.
The following user(s) said Thank You: DenisChenu, gbl_amorim
The topic has been locked.
- deliot
- Topic Author
- Offline
- New Member
Less
More
- Posts: 9
- Thank you received: 0
4 years 10 months ago #183528
by deliot
Replied by deliot on topic Pie Chart fonts missing in PDF
So a year later I still have the same issue! Thankfully, I found the problem, and set up a workaround.
ISSUE: PDF legends on pie graphs and other graphs have no text. I found the problem by setting debug to "2" in the config.php file. This showed a number of PHP warnings linked to pChart.class.php and specifically a link to a missing file found along the path /HOMEDIR/fonts/DejaVuSans.ttf. It turns out that there is no fonts folder in this location, but there is one along the path /HOMEDIR/assets/fonts/DejaVuSans.ttf. I'm guessing this is because I have upgraded (properly) a number of times, and somehow the MySQL database still has a reference to the old path.
WORK AROUND: For now, I just created a symbolic link so that /fonts points to /assets/fonts. At some later date, perhaps I'll track down the error in the database.
NOTE: This seems somehow related to this bug report: bugs.limesurvey.org/view.php?id=13338
My current LimeSurvey version 3.16.1+
ISSUE: PDF legends on pie graphs and other graphs have no text. I found the problem by setting debug to "2" in the config.php file. This showed a number of PHP warnings linked to pChart.class.php and specifically a link to a missing file found along the path /HOMEDIR/fonts/DejaVuSans.ttf. It turns out that there is no fonts folder in this location, but there is one along the path /HOMEDIR/assets/fonts/DejaVuSans.ttf. I'm guessing this is because I have upgraded (properly) a number of times, and somehow the MySQL database still has a reference to the old path.
WORK AROUND: For now, I just created a symbolic link so that /fonts points to /assets/fonts. At some later date, perhaps I'll track down the error in the database.
NOTE: This seems somehow related to this bug report: bugs.limesurvey.org/view.php?id=13338
My current LimeSurvey version 3.16.1+
The topic has been locked.