PDF::HTMLDoc, release 0.1.0

March 5th, 2007 § 1 comment § permalink

The project has been approved at RubyForge, so it can be downloaded from there now or installed via the usual gem install htmldoc command. The documentation is accessible as well, and there is a Subversion repository for those interested in download the files directly.

As I said in the previous entry, I hope this library is useful to others as it was to me.


March 5th, 2007 § 0 comments § permalink

Anyone using Ruby and Rails knows that there are few decent reporting tools, and many of them are very hard to use. Since there’s no native solution, most developers resort to a combination of other tools to put their reports together.

In my last projects, I tested a lot of solutions and found one setup that I consider satisfactory: I’m using HTMLDOC to generate PDF reports from HTML input. HTMLDOC is an open-source application that converts HTML input to formatted HTML, PDF or PostScript output.

HTMLDOC is an excellent tool, but it’s an application, which means you need to invoke it and control its execution as a process. To make the job easier, I created a plugin/gem that allows me to use HTMLDOC via a Ruby class, with a couple of simple methods.

While I search for a permanent place for the project (RubyForge, for example), I’m making both the gem and the plugin available here. The usage information can be found in the README.txt file.

In order to use the class, you will obviously need the executable. Although HTMLDOC is open source, binaries are only available in paid versions. For Linux, the easiest option is to compile it yourself, which is quite simple. For Windows, old binaries can be found on the Internet. Obviously, they lack the most recent fixes. If you are deploying to Linux, though, that’s not much of a problem since you can test most of the options on Windows and run the most recent binary on Linux.

I hope this library will be as useful to others as it has been to be. If you have any comments, suggestions or fixes, please contact me.

Where am I?

You are currently viewing the archives for March, 2007 at Reflective Surface.