[email protected] wrote: > Thank you, I'm not sticking to the idea putting everything > into pdftoppm. Making a program using only cairo output is > better because the source code is shorter & cleaner. > > However, yet I'm not sure how to use pdftocairo to crop PDF. > > The sample source including 8 figures: > > http://home.hiroshima-u.ac.jp/mpsuzuki/tibetbt-chart.pdf > > The pdf cropped by pdftoppm with my patch is > > http://home.hiroshima-u.ac.jp/mpsuzuki/cropped-pdftoppm.pdf > > It was cropped aslike: > > pdftoppm -pdf -f 1 -l 1 -r 72 -x 80 -y 80 -W 215 -H 160 \ > tibetbt-chart.pdf cropped-pdftoppm > > The pdf "cropped" by pdftocairo is > > http://home.hiroshima-u.ac.jp/mpsuzuki/cropped-pdftocairo.pdf > > It was "cropped" aslike: > > pdftoppm -pdf -f 1 -l 1 -r 72 -x 80 -y 80 -W 215 -H 160 \ > tibetbt-chart.pdf cropped-pdftocairo.pdf
I assume you meant "pdftocairo" instead of "pdftoppm". The resolution option "-r" is not required (and doesn't do anything) when using -pdf or -ps. > It seems that the origin specified by -x & -y are reflected, > but the output is full sized, not cropped. What was wrong? Probably a bug. I copied pdftoppm.cc to create pdftocairo.cc so all the relevant options were copied across. However many of the options have not been tested as I only use pdftocairo for my testing purposes. Patches are welcome. _______________________________________________ poppler mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/poppler
