[poppler] Unit of the result from pageSize() and pageSizeF()

Albert Astals Cid aacid at kde.org
Thu Nov 24 09:52:52 PST 2011


El Dijous, 24 de novembre de 2011, a les 09:04:45, Joachim Langenbach va 
escriure:
> Good morning everybody,

Morning, assuming this questions are about the Qt4 frontend, if they are not, 
please be more specific when asking

> 
> I'm trying to calculate scale factors and it is a little bit confusing. So
> what is the unit of the sizes returned by pageSize and pageSizeF? Is it
> dots?

http://people.freedesktop.org/~aacid/docs/qt4/classPoppler_1_1Page.html#a466525e6988b199176d3d68dd0099bf1
The dimensions (cropbox) of the page, in points (i.e. 1/72th on an inch)

> And what is the unit of the parameters renderToImage(xres, yres)? Are those
> resolutions in dots/inch?

http://people.freedesktop.org/~aacid/docs/qt4/classPoppler_1_1Page.html#a43bb866fa1f848156799eb8d9e38d0aa
the parameters (x, y, w, h) in pixel coordinates


> May be it's worth to improve the documentation at those to functions,
> because units are not mentioned here. Or for pageSize and pageSizeF, I do
> not understand "i.e. 1/72th on an inch".

Oh, i see you found a typo, on -> of, does that help?

Albert

> I'm asking that, because I want to be able to render a PDF page into an
> image with known height and width in pixel.
> 
> Please add me to the cc, because I'm not a list subscribor.
> 
> I'm appreciate for any help!
> 
> Kind Regards,
> 
> Joachim


More information about the poppler mailing list