GSoC Report

John Tytgat joty at
Sun Jun 22 16:38:04 BST 2008

In message <200806221717.47482.adamblokus at>
          Adam Blokus <adamblokus at> wrote:

> > > I moved also some responsibility for margins etc. to the plotter code, to
> > > make printing less dependant on the way margins and page sizes are set.
> > >
> > > For this week I plan to change the layouting for printed content, so that
> > > all of it will be fit in the available width (the 'loose' layout that I
> > > wrote about last week).
> >
> > This is including teaching NetSurf layout code to take the text width
> > determined by the backend into account (as the fonts used in PDF output
> > do not necessarily have the same width as what the layout engine was
> > using) ?
> I am not sure if after adding the possibility to embed fonts this couldn't be 
> done by the same nsfont_width function, that determines text width for the 
> window. If not - I will most surely parametrize the function being used for 
> it.

If you manage to always embed the fonts in the PDF output then yes,
nsfont_width can remain the same as it is.  However, at least for RISC OS
version of NetSurf this won't be the case as there RISC OS fonts are used
and libharu does not have code to convert those to one of the font types
supported by PDF. So we'll need to do something with nsfont_width to
look after this usecase.

John Tytgat
joty at

More information about the netsurf-dev mailing list