font_split change, action required

Chris Young chris.young at unsatisfactorysoftware.co.uk
Sun Feb 10 23:35:49 GMT 2013


On Sun, 10 Feb 2013 19:55:31 +0000 (GMT), Michael Drake wrote:

> The implementation requirements for font_split have changed slightly.
> The split point (char_offset) does not now have to be a space.

I'm clearly missing something here, as I took this literally initially
and just set the split point where x would fall, expecting the core to
seek back to the previous character that was a valid split point. 
Instead, I ended up with lines split mid-word.

I've slightly bodged it now, so it only splits on spaces, but when it
doesn't find a space (which seems to be happening in some instances
when a space is clearly present, not sure why yet), it just splits
where x falls.  This is working without any words getting split across
lines.

If the intention is to split at not only spaces, is there any reason
why the frontend can't just return the character that falls at x?

Chris



More information about the netsurf-dev mailing list