Print preview format bug

Started by Davide Cottignoli, June 14, 2016, 12:02:38 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Davide Cottignoli

Hi Liviu,
after success in compiling FET 5.29.5, I wanted to try the already generated timetable for my school to test color interface and print preview.
Since the initial version that included print preview I noticed there is a problem on column spaces.
I attached an example screenshot and the setting which get the wrong format.
There is a wrong colum width at 7:50 time which expand a row height very highly.

Davide.
Davide.

Volker Dirr

ok. things like that happen if the table is too large for a single page.

so how to fix it?
a) select landscape format (you done that already; good!)
b) in your case better choose "Tempo orizzontale per giorno"
c) select a "better" size of the front

in worst case you might print the tables from the timetable result folder. but webbrowsers have got similar problems, but you can/should try it.

Volker Dirr

i forgot: an other variant is to select the selection box with the current value "normal" and change it to value "pre".

Davide Cottignoli

I compiled FET 5.32.0 myself for Mac in foresight to the next timetable and to test print results but I noticed the print format bug has not been resolved. The problem appears to be only on the second column which format is made by only one char space; other columns space appear to be equally distributed. So I think there is a bug in columns space calculation.
I append the new screenshots which show the same problem.
How to fix it?

Davide.
Davide.

Volker Dirr

like i already said: if the hight of the cell will be reduced, it mean the width of the cell will grow. if the the width grow it mean it won' fit on the paper anymore and you can't see it anymore. (Qt/html doesn't print on a second paper next to the first one)
so please use one of the solutions i wrote in my first answer.

Davide Cottignoli

Ok Wolker but I don't understand why the second column is only one char width and all the others are minimum 5 chars or more. It's logical that every colums have got the same width, and this problem happens even if sheet measures are A2 or more.

Thanks.
Davide.

Volker Dirr

#6
That is calculated by the html render engine. Not by FET source. So you must ask that the gus who coded the render engine. So you need to ask that the Qt guys.
But in my opinion it is not unlogical. It is logical. The render engine try to use as less space then possible. So if some cells contains a low number of characters (compared to other cells) it might be much smaller if you break already after 1 character instead of 5 characters like in the other columns. So there is no rule like "always X characters per column"; the rule is "try to use as less space as possible". If the table doesn't fit on a paper, than i guess that rule/algorithm doesn't work always "perfect"; but in fact that doesn't matter, since it doesn't fit on the paper; so printing a bit nicer, but still not on the paper doesn't help.

So if there are still to many columns for a paper, than of course also DIN A2 doesn't help. You need reduce that with by:
- using lager paper size
or/and
- using smaller font size
or/and
- using less columns (by printing an other table and/or limit the colums by the "max names" feature (if same are on the x-axis)
or/and
- select landscape format

if there is space left or right to the table if you select DIN A2, than you are right, than there might be a bug. But i don't think that there is space (except of the printer margin). I can't check that without your dataset (or a screenshot)
if you still think that there is a bug, than you need to sent me your file.

Davide Cottignoli

Thank you Volkerr,

try with the attached file and compare the generated HTML (which is fine) with the print preview (which is wrong).
Davide.
Davide.

Volker Dirr

the printpreview is html (just limited to a paper). html itself doesn't have a with. i will check the file now.

Volker Dirr

the preview works correct (like the rule by the render engine. it is logical to print it that way; i guess you want to have it on 2 or more sheets; but the html engine doesn't work like that. i can't change that in the FET source. You must talk to the Qt guys that coded the render engine if you want to change that. But i bet they won't change that, because it is correct by W3C rule.)
There is no bug; the table is still to width. you need to reduce that.
So what can you do?
Like i already said a few times: You must limit the number of columns if you can't reduce the size or enlarge the paper size anymore.
That will be easy: just select "Tempo orizzontale PER GIORNO" instead of "Tempo orizzontale"
So you will get at least as many papers as you have got days per week. Just place them next to each other and it will look like the needed one.


Volker Dirr

By the way: The tables will also look a bit better if you try to short the names.
So for example instead of "Borsi Giunchi Francesco (15h ITP)" just write "Borsi Giunchi F." or even shorter.
Also subjects. If you use small characters instead of upper one is save space. But here you should also thinking about shorting them.