Friday, 27 April 2018

bad linebreaks

I raised a report on the bug-tracker about really bad linebreaks that
Netsurf sometimes commits.

This isn't a new thing. I'm using #4316 but fault has existed since
many many versions ago and as far as I know has never been reported.

My theory is that the Netsurf code thinks it's OK to start a new line
when text reaches nearly the edge of the frame and that it can perform
the break not only at a wordspace but also at an HTML tag, i.e. at "<"
or ">" or "&xxx;". (Hmm, what about &nbsp; ?)

You too often see a word like "John&rsquo;s" with the apostrophe-s or
just the -s on the next line. Or a split in the middle of something
like "<i>x</i><sup>2</sup>=4<i>y</i>". Or "(<a href=...> blabla</a>)"
can leave the opening or closing parenthesis on a different line. Or
worse.

It obviously depends on the width of the window, so you might have to
drag the width to see it happen (presuming of course that it's not a
fixed-width page). Try a news page from http://theregister.co.uk as
an example.

Anybody concur with me?

--
Jim Nagel www.archivemag.co.uk

No comments:

Post a Comment