Bad news for Netbeans?

October 30, 2009 | In Uncategorized | No Comments

The latest document from Oracle on the merger doesn’t look that good for Netbeans. Glassfish will get resources and be more integrated with Weblogic. MySQL will get more resources. Solaris, Sparc, storage too.

But for Netbeans:

“As such, NetBeans is expected to provide an additional open
source option”. No commitment.

More at Adam Bien.

Docbook, Maven, SVG and fonts

October 5, 2009 | In Uncategorized | No Comments

I wrote in my last post about using Maven to build good-looking and maintainable documentation. I had issues with raster images getting rendered in the wrong resolution with Apache FOP. I tried RenderX XEP and it rendered in the correct resolution, but the images still look a bit blurred in the resulting PDF. Also the personal edition adds a footer on every page. Side note: I don’t mind paying for software, but it is always a hassle with license files and registrations. The benefits must be big for me to include a tool like this in my toolbox.

SVG

Since raster images was problematic I thought about using a vector format instead. I used OmniGraffle Professional to generate SVG illustrations. OmniGraffle is a really nice program. This worked pretty well with FOP (it is using Apache Batik behind the scene, I think). But I could not get font rendering to work inside SVG. It is replacing the fonts I used with Times.

I have set up FOP to use some fonts I like. It looks like this in the pom.xml:

<font>
  <name>FrutigerLinotype-Roman</name>
  <style>normal</style>
  <weight>normal</weight>
  <embedFile>${basedir}/src/fonts/frutiger.ttf</embedFile>
  <metricsFile>${basedir}/target/fonts/frutiger-metrics.xml</metricsFile>
</font>

In the SVG I used the same fonts and font names. A wierd thing s that it works fine when I used Batik in form of Squiggle, which is a Swing SVG viewer, written with Batik.

With XEP the result was worse. It lost gradients and some other artifacts from the SVG. No on the other hand, it actually found the fonts. So again XEP and Apache FOP had different problems. I don’t think XEP is using Batik to render the SVG into PDF.

Current state of “Documentation Nirvana”

  • Tool chain is working good. Maven was a big win. Self contained project , easy to check out from Mercurial and just run.
  • Raster images looks wierd in all my tests. This is almost a show stopper. Screenshots are necessary in my documents.
  • Vector images work better. If I stick to Helvetica I think it is good enough.

I would welcome comments!

Docbook and Apache FOP

October 2, 2009 | In Uncategorized | 2 Comments

I have taken up Docbook again. It was too much configuration and fixing when I tried it a few years ago. But now I found a Maven plugin that makes it really easy. Fonts go in one directory, custom XSL in another, images and docbook files in a third. Then all I have to do is

mvn clean generate-resources pre-site

to generate a shiny PDF in target. The plugin is called docbkx-maven-plugin.

This was actually close to documentation editing nirvana. But I have a really annoying issue. If I include raster files they get rendered in the wrong resolution. FOP is shoing them as larger and pixelized. I thought there might be something wrong with my settings or the plugin so I tried a commercial offering from OxygenXml.com. They also use Apache FOP as the default FO processor.

They replied to my support request (really good support, and it was only pre-sale questions):

It is a problem of the FOP processor which scales the images to a larger size ignoring the actual image size and the width and height set by the user. You should use a different FO engine like XEP for RenderX. […]

RenderX costs $360.

I have googled a lot and this seems to be a really old issue in Apache FOP. Anyone knows if there is a solution? Are they working on the issue?

Entries and comments feeds. Valid XHTML and CSS. ^Top^