Coming soon to a NetBeans IDE near you…

While I was writing the PDF to HTML5 conversion code, I went to a talk at Javaone2011 last month showing a plugin on an FxgConverter making JavaFX code which you could call from the NetBeans IDE. This free plugin does conversion of files into Java2D or JavaFX. We thought it would be really cool if you could add similar functionality in NetBeans to convert PDF files into JavaFX.

It turned out to  relatively straight-forward using a subset of the new code for PDF to HTML5 conversion. So here is a screenshot of our current development which is running on our machines a month later (it is our ‘fun’ end of the day project). It does not need JavaFX to do the conversion (you can see all the errors in the screenshot), but it does need JavaFX installed to run the Java code produced.

Fonts are substituted but correctly positioned and the images, shapes and text are all carried across and become JavaFX commands. There are some rough edges still (page shading is not carried across and rotated text on the right is wrong in the example), but we think it looks promising enough to warrant a 1.0 release.

 

Version 1.0 is now outWhat do you think?

Related Posts:

The following two tabs change content below.

Mark Stephens

System Architect and Lead Developer at IDRSolutions
Mark Stephens has been working with Java and PDF since 1999 and has diversified into HTML5, SVG and JavaFX. He also enjoys speaking at conferences and has been a Speaker at user groups, Business of Software, Seybold and JavaOne conferences. He has a very dry sense of humor and an MA in Medieval History for which he has not yet found a practical use.
Markee174

About Mark Stephens

Mark Stephens has been working with Java and PDF since 1999 and has diversified into HTML5, SVG and JavaFX. He also enjoys speaking at conferences and has been a Speaker at user groups, Business of Software, Seybold and JavaOne conferences. He has a very dry sense of humor and an MA in Medieval History for which he has not yet found a practical use.

5 thoughts on “Coming soon to a NetBeans IDE near you…

  1. So, just to make sure I understand, you’ve got a working prototype where you can display a PDF within a JavaFX scene?

    If so, that is very cool – keep up the great work 🙂

    — Jonathan

  2. Yes. The images, text and Vector commands are all translated into the matching JavaFX commands

  3. Ryan

    Very cool. I would like to be able to embed a PDF viewer into an app that can display or print to a printer (including headless mode) without needing to generate Java source code and compile for every PDF.

  4. There is a batch conversion tool now at http://www.jpedal.org/support_javafx.php

    The NetBeans plugin will be uploaded tomorrow and we also have an update out for our original JavaFX viewer which displays PDF pages inside a JavaFX viewer out this week. So you can display PDF in JavaFX or as JavaFX!

    JavaFX cannot be used for printing yet – you will still need Swing for that.

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes:

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>