Tuesday Jul 03, 2012

The Enterprise Side of JavaFX: Part Two

A new article, part of a three-part series, now up on the front page of otn/java, by Java Champion Adam Bien, titled “The Enterprise Side of JavaFX,” shows developers how to implement the LightView UI dashboard with JavaFX 2. Bien explains that “the RESTful back end of the LightView application comes with a rudimentary HTML page that is used to start/stop the monitoring service, set the snapshot interval, and activate/deactivate the GlassFish monitoring capabilities.”

He explains that “the configuration view implemented in the org.lightview.view.Browser component is needed only to start or stop the monitoring process or set the monitoring interval.”

Bien concludes his article with a general summary of the principles applied:

“JavaFX encourages encapsulation without forcing you to build models for each visual component. With the availability of bindable properties, the boundary between the view and the model can be reduced to an expressive set of bindable properties. Wrapping JavaFX components with ordinary Java classes further reduces the complexity. Instead of dealing with low-level JavaFX mechanics all the time, you can build simple components and break down the complexity of the presentation logic into understandable pieces. CSS skinning further helps with the separation of the code that is needed for the implementation of the presentation logic and the visual appearance of the application on the screen. You can adjust significant portions of an application's look and feel directly in CSS files without touching the actual source code.”

Check out the article here.

Wednesday May 23, 2012

Best Practices for JavaFX 2.0 Enterprise Applications, Part Two

Java Champion, Oracle Java Evangelist, and JavaFX expert Jim Weaver, has published Part Two of his article, "Best Practices for JavaFX 2.0 Enterprise Applications" on otn/java. Weaver continues to explore the possibilities of the TweetBrowser application, focusing now on new techniques and best practices that include:

* Leveraging a JavaFX cascading style sheet
* Implementing springs and struts in the UI
* Using a ternary operation in binding expressions
* Defining JavaFX properties
* Leveraging a Popup to implement a dialog box
* Using WebView to display a Web page

As Weaver emphasizes, there is a vast array of techniques and best practices that can be used in JavaFX applications. For example:

The JavaFX cascading style sheet (CSS) enables users to modify the appearance of an application.

The springs and struts concept enables a fixed horizontal strut and a variable horizontal spring so that an application can appear the way developers want it to appear, regardless of the size of the scene or the type of platform.

Go here to learn more about the rich possibilities of JavaFX 2.0 and enterprise applications.

Thursday Mar 01, 2012

Laying Out a User Interface with JavaFX 2.0

Java Champion and JavaFX expert Jim Weaver has a new article up on otn/java, titled “Laying Out a User Interface with JavaFX 2.0,” in which he shows developers how to use the layout capabilities of JavaFX 2.0 to make nodes in a scene graph appear where they belong and with the appropriate size.

He provides an overview of the LayoutSansTearsSolution application, shows how to make use of the SceneBuilder and BorderPaneBuilder classes, and helps readers understand the behavior of resizable nodes. Weaver explains the distinction between clamped and unbounded nodes and, finally, shows how to use CSS style sheet properties to modify the layout.

From the article:

“JavaFX has very powerful features for laying out a user interface... These features enable your applications to appear the way you want them to appear, regardless of the size of the scene or the type of platform. Understanding the behavior of each type of layout class, as well as concepts such as clamped versus unbounded nodes, will go a long way toward helping you make the UI appear exactly the way you want it.”

Read the complete article here.

About

Insider News from the Java Team at Oracle!

duke
javeone logo
Links


Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
2
5
6
7
12
13
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today