+ All Categories
Home > Documents > Zz Javafx Lecture

Zz Javafx Lecture

Date post: 17-Dec-2015
Category:
Upload: quoc-thinh
View: 32 times
Download: 5 times
Share this document with a friend
Description:
javafx lec
Popular Tags:
15
INTRODUCTION TO JAVAFX CS12420 – Software Development Andrei Stanica (modified ltt)
Transcript
  • INTRODUCTION TO JAVAFXCS12420 Software DevelopmentAndrei Stanica(modified ltt)

  • OverviewWhat is JavaFXHistoryWhy use itJavaFX or Swing/AWTExamples

  • What is JavaFXA media/graphics framework for creating GUIs in Java applicationsBased on Swing and AWTMore powerfulUsed to create both desktop and web applicationsLike Swing draws its own components, less communication with OSLightweight and hardware-acceleratedMakes use of FXML new XML-based mark-up language for defining UIs

  • HistoryFirst announced in May 2007 by then Sun MicrosystemsReleased in December 2008Originally brought as a response to Flash and ShockwaveBut also to improve ease of creating GUIs for Java applicationsLatest release is JavaFX 2.2

  • HistoryWith the latest release Oracle added numerous features:Linux and Mac OSX supportMulti-touch events and gesturesImage manipulation easier with built-in APIBundled with Java SE 7 update 6Big number of new and enhanced UI controls, charts and containersMany more

  • Why use it

  • Why use it

  • Why use itOracle provides you with JavaFX Scene BuilderVisual UI design toolNo need to spend n-hours anymore on trying to move a button a little bit to the leftAbility to apply CSS on the components of the UI opens a door for better looking applications that are more attractive to the end-userSoon 3D support (possibility of games cropping up) and iOS and Android support promised by Oracle

  • JavaFX Script and FXMLBefore version 2.0, JavaFX made use of JavaFX ScriptJavaFX Script proprietary scripting language deprecated

  • JavaFX Script and FXMLFrom 2.0 onwards, FXML has been introducedMore powerful and XML-basedAll developers have knowledge of XML

    FXML declarative XML-based language

  • JavaFX or Swing/AWTLess

    IDEs provide support for GUIs in Swing but in FX this is provided by Scene Builder which is part of distribution

  • JavaFX or Swing/AWTMore

    This is Scene Builder running

  • JavaFX or Swing/AWTGUIs are created a lot faster than in Swing and AWTMore sophisticated and aesthetically pleasing UIsEasy integration of sounds, images and videos and of web contentCode is simplified in JavaFX by separating the UI from the logic of the applicationJavaFX can be integrated in Swing applications, allowing for a smoother transition

  • ExamplesDemonstration of JavaFX (use chrome)http://www.oracle.com/technetwork/java/javafx/samples/index.html

    Java SE 7, JavaFX, JavaFX Scene Builder and examples to get you started can be found here:http://www.oracle.com/technetwork/java/javafx/downloads/index.html

  • Other Useful Links

    http://docs.oracle.com/javafx/2/overview/jfxpub-overview.htm description

    http://docs.oracle.com/javafx/2/api/index.html API

    FXML replaced JavaFX Script (which is now deprecated)*Announced at the JavaOne Worldwide Java Developer conferenceDidnt actually kick off on the right foot, not widely knownImproved a lot since 1.0*As future work, support for 3D graphics*JavaFX Script is a scripting language, initially called F3 for Form Follows Function

    *Devs know more about XML rather than a proprietary scripting language (JavaFX Script)**


Recommended