- Posts: 16
- Thank you received: 3
Welcome to the LimeSurvey Community Forum
Ask the community, share ideas, and connect with other LimeSurvey users!
simple stats graphs break when complex or lower screen res
- mikebb
- Topic Author
- Offline
- New Member
Less
More
5 years 8 months ago #172347
by mikebb
simple stats graphs break when complex or lower screen res was created by mikebb
I mentioned squished and broken graphs in a previous thread and the dev said he could not replicate it.
I've narrowed it down to the following when showing answers to a flexible array question:
- lots of answer categories (on the x axis) and/or
- long text strings on the answers (x axis labels) and/or
- lower screen resolutions (still above the specified minimum) and/or higher than 100% font size (in windows).
all this makes for broken graphs like in the first screenshot (browser showing 90%). if the screensize is changed or the browser zoomed out then the graphs display fine - see screenshot 2 (browser showing 80%).
These are on a 2560x1440 display with text size 175% (my eyes are poor) using LS 3.14.3+180809. same/similar on Edge, chrome and firefox (all latest).
I think the problem is in chart.js and the sizing it sets in its container using bootsrap columns. Interestingly complex stats does not have this problem where the charts are held in tables - ie not relying on bootsrap's layout.
I don't understand chart.js enough to know a solution. I wonder if its about the div size at holds the chart before chart does its building and sizing - there's some thread about on this.
Work-arounds are:
If you think this is a bug I can do a bug report - I think a fix would make limesurvey more useful.
Thanks
Mike
Browser at 90% - broken
Browser at 80% - OK
I've narrowed it down to the following when showing answers to a flexible array question:
- lots of answer categories (on the x axis) and/or
- long text strings on the answers (x axis labels) and/or
- lower screen resolutions (still above the specified minimum) and/or higher than 100% font size (in windows).
all this makes for broken graphs like in the first screenshot (browser showing 90%). if the screensize is changed or the browser zoomed out then the graphs display fine - see screenshot 2 (browser showing 80%).
These are on a 2560x1440 display with text size 175% (my eyes are poor) using LS 3.14.3+180809. same/similar on Edge, chrome and firefox (all latest).
I think the problem is in chart.js and the sizing it sets in its container using bootsrap columns. Interestingly complex stats does not have this problem where the charts are held in tables - ie not relying on bootsrap's layout.
I don't understand chart.js enough to know a solution. I wonder if its about the div size at holds the chart before chart does its building and sizing - there's some thread about on this.
Work-arounds are:
- use a higher screen resolution - not easy for some!
- collapse the side bar and reload the page (so there's more horizontal space).
- use short answer categories or re-design your question texts
- set
Code:
responsive: !0
- avoid flexible array graphs
If you think this is a bug I can do a bug report - I think a fix would make limesurvey more useful.
Thanks
Mike
Browser at 90% - broken
Browser at 80% - OK
Attachments:
The topic has been locked.
- holch
- Offline
- LimeSurvey Community Team
Less
More
- Posts: 11658
- Thank you received: 2742
5 years 8 months ago #172374
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 simple stats graphs break when complex or lower screen res
Why opening a new thread if this (or part of this) has been discussed in another thread before?
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.
- mikebb
- Topic Author
- Offline
- New Member
Less
More
- Posts: 16
- Thank you received: 3
5 years 8 months ago - 5 years 8 months ago #172417
by mikebb
Replied by mikebb on topic simple stats graphs break when complex or lower screen res
holch - I opened a new thread as the other one i referred to was mainly about a different issue where this matter was a minor part of it that I added to main question. And
that issue (click here)
was resolved by an update.
so I didn't want to hijack a dead thread.
I can move that back if you prefer.
so I didn't want to hijack a dead thread.
I can move that back if you prefer.
Last edit: 5 years 8 months ago by mikebb.
The topic has been locked.