JFXGraph… graphing with JavaFX

Firstly, happy new year! This is my first post for 2009, and so far the new year has been going great!

So strait into the good stuff…

As you may have seen in a previous post of mine a bar graph type of application that demonstrated the integration of Java with JavaFX.

I decided to further develop the graphing application to be far more robust.

Introducing JFXGraph the bar graphing application that makes graphing data easy (well that’s the idea).

Its really a very simple application, made up of a few classes and some CSS files.

Firstly, here is a few screen shots of the application running:

There are a few features here:

  • Columns may be added dynamically
  • Automatic height adjustment of the Y-axis when new columns added (if required)
  • Smooth growing animation of bars
  • Y-axis lines extending from the bar to the Y-axis (onmouseover each bar) for ease of view
  • Entire graph is draggable via mouse

The swing button, “Add New Column” in the top left corner is just a helper button that adds a new column (up to 5 in total) to the graph so the user can see how it looks when new data is added.

The code is quite simple, there are only 2 classes that this application uses:
BarGraph, and BarGraphColumn. They are pretty self explanatory, and the code can be made available upon request (just shoot me an email…).

Below is a JNLP launcher that will allow you to see it running in its current state (I change it around a fair bit as I think of new features, bugs, etc…)

4 Responses to "JFXGraph… graphing with JavaFX"

  • Balu says:
  • Mark says:
  • Raj says:
  • Mark says:
Leave a Comment