SVG To FXML Converter as Commandline util


There’ve been some requests from people to use the SVG to FXML converter outside my e(fx)clipse project. I’m happy to announce that the latest nightly builds provide a standalone version of the converter.

Useage is quite simple:

java -jar svg2fxml-0.1.0-SNAPSHOT.jar http://croczilla.com/bits_and_pieces/svg/samples/tiger/tiger.svg tiger.fxml

will produce an FXML which can be loaded into SceneBuilder:

Need to teach myself now how I can provide this as a netbeans module ;-) Any volunteers to provide an implementation and contribute it to e(fx)clipse.org?

10 thoughts on “SVG To FXML Converter as Commandline util

  1. gontard February 20, 2013 / 8:19 am

    Is there a way to use this jar api for generating a javafx.scene.Node without the fxml step ?

    • Tom Schindl February 20, 2013 / 8:47 am

      no and the algorithms used are not optimized for live processing and creation of Scene-Graph on the fly. What is your use case, do you want to use it transform SVGs on the fly?

      • gontard February 20, 2013 / 8:51 am

        Yes i would to load a svg file in javafx.scene.Node on the fly.

    • Tom Schindl February 20, 2013 / 9:20 am

      fairly all SVG-Elements beside Text and Filters are supported. Text can be implemented now with the JFX8 TextFlow element but most filters can not be implemented without new API in JavaFX itself, if you file a trac-ticket (http://efxclipse.org/trac) I can take a look what’s going wrong with the flag sample – most likely a bug. SVG is a really complex beast with all the Transforms, … going on so there’s not general guarantee that the converter works :-(

    • Tom Schindl July 16, 2014 / 12:34 pm

      it is part of our repo but we have not implemented many new features in the last few months – if you have concrete problems and a sample SVG to test – file a bugzilla but we are currently head down in other areas of e(fx)clipse so we won’t fix it anytime soon unless you provide a patch

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s