Chika Okereke Chika has written much of the JavaFX converter and also helps with the HTML5 converter. When not experimenting with the new features of JavaFX, he is a keen basketball player (he is the tall guy you might see at Devoxx).

PDF to FXML conversion – First impressions of FXML

48 sec read

Creating the JavaFX converter was an interesting challenge and we will continue to refine the PDF to JavaFx conversion. My next challenge is to add the FXML version. I want to do this for several reasons:-
1. Increases the functionality of the conversion and offers alternatives.
2. It gets around the maximum file size issue in Java.
3. It looks like a really interesting technology!

JavaFXML is quite different in structure.  Upon creating a new FXML project, three files are automatically created as opposed to the one file created when creating a java file or a JavaFX file.

   – The first file contains the main method which makes the program runnable.

– The second file contains the xml equivalent of all the JavaFX commands. For example

<Button id="button" layoutX="126" layoutY="90" text="Click Me!" onAction="#handleButtonAction" fx:id="button" />

As opposed to

Button button = new Button();
button.setLayoutX(126);
button.setLayoutY(90);
button.setText("Click Me!");

– And the third file acts as an action listener as it has all the actions within it waiting to be executed depending on whether it is called up on.

Below is a diagram of my current understanding of the code, maybe you can correct me if am wrong?

During my quest to create a FXML converter, I will be sure to document/blog any interesting points I come across. Stay tuned…

IDRsolutions develop a Java PDF Viewer and SDK, an Adobe forms to HTML5 forms converter, a PDF to HTML5 converter and a Java ImageIO replacement. On the blog our team post anything interesting they learn about.

Chika Okereke Chika has written much of the JavaFX converter and also helps with the HTML5 converter. When not experimenting with the new features of JavaFX, he is a keen basketball player (he is the tall guy you might see at Devoxx).

Updates on Java PDF Viewer roadmap from IDRsolutions

My previous blog post (5 changes we are considering in 2016 for IDRsolutions), generated lots of feedback for us (for which we would like...
Mark Stephens
58 sec read

My key takeaways from NetBeans Day 2015

NetBeans Day 2015 had to be rescheduled to bigger rooms because of attendee demand. It was a very busy schedule. Here are my notes...
Mark Stephens
2 min read

An Introduction to JavaFX Panes with Code Examples

As a developer at IDR Solutions I spend a lot of my time working with JavaFX and Panes in our JavaFX PDF Viewer. I...
Sylwia Dorota Kedzia
1 min read

One Reply to “PDF to FXML conversion – First impressions of FXML”

  1. So, just to make sure I understand, you’ve got a wiknorg prototype where you can display a PDF within a JavaFX scene?If so, that is very cool keep up the great work Jonathan

Leave a Reply

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