Java Reference
In-Depth Information
Stage {
title: "Application title"
width: msg.boundsInLocal.width
height: msg.boundsInLocal.height * 2
scene: Scene {
content: [msg]
2. Next, using the javafxpackager tool, build and package the application using the
following command (note that command has been wrapped for readability):
javafxpackager -src src -appClass myapplet.SimpleApplet
-appName applet-demo
-appVendor "Vladimir Vivien" -appVersion 1.0
-appC odebase "http://my.server/path /to/app/"
-appWidth 640 -appHeight 75
Upon completion, the packager tool will produce the following deployment artifacts in
the dist/ directory:
3. Next, open the generated file applet-demo.html. You can use it as is, modify its
content to fit your specific need, or copy the JavaScript snippet in the HTML file into
your own file. Optionally, you can edit the JNLP file, applet-demo_browser.jnlp, to
tweak the deployment information inside. Chances are, however, you will not need
to (see the recipe Packaging your app to be Web Start(ed) for information about
JNLP file).
4. Finally, upload the files applet-demo.jar, applet-demo.html, and applet-demo_
browser.jnpl onto a web server at a location matching the URL specified by flag
-codeBase in the javafxpackager command line. If these values do not match,
the applet will not work properly.
Search WWH ::

Custom Search