Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » e(fx)clipse » FXML to Java Code
FXML to Java Code [message #1695147] Tue, 12 May 2015 09:43 Go to next message
Jörg Wille is currently offline Jörg WilleFriend
Messages: 14
Registered: December 2011
Junior Member
I am developing a javafx android app using javafxports and trying to prevent loading of FXML documents for startup-performance reasons. I read an older blog entry "Convert FXML to Java as part of the build" by Tom using "org.eclipse.fx.core.fxml.ExtendedFXMLLoader" - but the link for the sample application is broken.
Is the ExtendedFXMLLoader and the FXML Compiler still part of e(fx)clips tooling and would it be a good choice for using it in this case?
Re: FXML to Java Code [message #1695196 is a reply to message #1695147] Tue, 12 May 2015 14:54 Go to previous messageGo to next message
Thomas Schindl is currently offline Thomas SchindlFriend
Messages: 6651
Registered: July 2009
Senior Member
Hi,

Yes our FXML => Java converter is still available. You should be able to
grab the latest release from
http://download.eclipse.org/efxclipse/compiler-released/1.2.0/org.eclipse.fx.fxml.compiler_1.2.0-SNAPSHOT.jar

Running it from the command line looks like this:

java -cp=${classpath-of-your-project} -jar
org.eclipse.fx.fxml.compiler_1.2.0-SNAPSHOT.jar
..../src/my/package/my.fxml .../src

We also have ant support built into the jar but could not find the
sample anymore.

Tom

On 12.05.15 11:43, Jörg Wille wrote:
> I am developing a javafx android app using javafxports and trying to
> prevent loading of FXML documents for startup-performance reasons. I
> read an older blog entry "Convert FXML to Java as part of the build" by
> Tom using "org.eclipse.fx.core.fxml.ExtendedFXMLLoader" - but the link
> for the sample application is broken. Is the ExtendedFXMLLoader and the
> FXML Compiler still part of e(fx)clips tooling and would it be a good
> choice for using it in this case?
Re: FXML to Java Code [message #1695702 is a reply to message #1695196] Mon, 18 May 2015 13:41 Go to previous messageGo to next message
Jörg Wille is currently offline Jörg WilleFriend
Messages: 14
Registered: December 2011
Junior Member
Thanks Tom,
good to hear that the fxml-compiler is available.
Running org.eclipse.fx.fxml.compiler_1.2.0-SNAPSHOT.jar complains of "no main manifest attribute" and checking the MANIFEST.MF shows:
Manifest-Version: 1.0
Ant-Version: Apache Ant 1.8.4
Created-By: 1.8.0-b132 (Oracle Corporation)

Could not find out main class by myself.
Btw, how feature-complete is the compiler? Can I throw about every fxml file on it and it will work or are there exceptions.
If it is working well, I actually would like to include it into the javafxport gradle plugin to enhance mobile builds.
Re: FXML to Java Code [message #1695707 is a reply to message #1695702] Mon, 18 May 2015 13:48 Go to previous messageGo to next message
Joachim Prinzbach is currently offline Joachim PrinzbachFriend
Messages: 2
Registered: May 2015
Junior Member
Hey Tom

am I missing something, or is the fxml compiler part not included in the 1.2.0 SNAPSHOT?
There is no packagee org.eclipse.fx.* in your JAR...

Cheers
Joachim
Re: FXML to Java Code [message #1695708 is a reply to message #1695702] Mon, 18 May 2015 13:53 Go to previous message
Joachim Prinzbach is currently offline Joachim PrinzbachFriend
Messages: 2
Registered: May 2015
Junior Member
When using the compiler in version 1.1.0 I do always get a NPE in FXMLSaxHandler.startElement(FXMLSaxHandler.java:339)
I believe that this is related to using custom components, are those one not supported?

Cheers
Joachim
Previous Topic:PartSashContainter - set partSize in px
Next Topic:Dynamic Part Rendering Problem
Goto Forum:
  


Current Time: Thu Apr 25 18:53:13 GMT 2024

Powered by FUDForum. Page generated in 0.03064 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top