How to generate a pdf calendar?

I want to generate a pdf calendar, and I have incoming calendar data
from a json interface. Any advice on things I should investigate to
implement this?

In my research, there are two main ways to generate a PDF:

  1. use an html -> pdf generator such as wkhtmltopdf or princexml (and
    invoke the command line from ruby)

  2. use another library (Prawn seems to be the big one for ruby). You’ll
    have to learn the markup syntax for Prawn, but I think if you’re
    willing
    to get over that hurdle then you have more control than if you used an
    html-> pdf generator.

-Kristina

On 12/13/2011 3:58 PM, K Clair wrote:

-Kristina

On Wed, 14 Dec 2011 05:47:36 +0900, Dan Q. wrote:

I want to generate a pdf calendar, and I have incoming calendar data
from a json interface. Any advice on things I should investigate to
implement this?

the ruby bindings to libharu may be useful also
http://libharu.org/wiki/Documentation/Examples

K Clair wrote in post #1036592:

In my research, there are two main ways to generate a PDF:

  1. use an html -> pdf generator such as wkhtmltopdf or princexml (and
    invoke the command line from ruby)

  2. use another library (Prawn seems to be the big one for ruby). You’ll
    have to learn the markup syntax for Prawn, but I think if you’re
    willing
    to get over that hurdle then you have more control than if you used an
    html-> pdf generator.

-Kristina

Interesting. Do the html to pdf generators use the html 5 standard when
rendering? I’m curious how they do this since each browser implements
like css styles very differently.

On Sat, 17 Dec 2011 02:11:33 +0900, Dan Q. wrote:

willing
like css styles very differently.
Each one does it differently, so you’d have to look at the individual
specs. I don’t remember the details anymore, but I remember when I was
researching this that wkhtmltopdf and princexml support different css
rules. One example I can remember is that until the most recent
release, princexml didn’t support the ‘nowrap’ property. Princexml
also
makes heavy use of some print media specific css things, such as @page,
and css can be used to change the flow of the page.

Not sure about html5!

-Kristina