Quote:
Originally Posted by IceHand
Anyway, yes, splitting by four gives very good results concerning the left and right border – the text size is rather large though (see attached image).
It would be great if the pi algorithm would have an option to specify the page width and height in pixels and optimise the line breaks accordingly.
|
BTW, what was the size of the original pdf? A4/Letter size? That text does look uncomfortably large.
I would suspect that the text would be more reasonable (size-wise) if the original had more words per line.
It is good that we are 'flushing' out what would be nice, in case the original poster wants to improve his algorithm to incorporate:
Wish list
1) split lines in two equal halves or optional equal thirds or equal quarters
2) crop the resulting image by three or four to retain the ereader's aspect ratio (usually 0.75 = 480/640) instead of just having a doubled height page.
3) allow the 1/6 flex to be calculated by some
words per line estimate or user-input.
4) allow coloured backgrounds/text input images instead of just grayscale (pgm vs ppm/png/pbm). Accomodate images somehow, perhaps shrink them down.
5) re-align the 'split line segment' (second half of line) to align with the
next line's indenting if its not blank. This will make the first line indent and bullet items line up better.
6) avoid segmentation faults