Skip to content

Latest commit

 

History

History

2021_04_27_JavaClass-3

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 

Java Class - III (Java GUI Class - I)

April 27, 2021

Get the Java Class - III recording: Here

Get the Calculator project made during the class: Here

Java logo

Class content:

  • Installation instructions

  • Installation of Java 8

  • Installation of IntelliJ IDEA

  • Installation of Scene Builder + JFoenix

  • Why Java 8 why not the newer java version?

    For answer: Click here

  • Why JavaFx?: Click here

    1. JavaFX can be styled with CSS, whereas Swing cannot be. If we want to style Swing GUIs with CSS, we will need to use third party sources like flying-saucer. Being able to implement CSS is a unique functionality of JavaFX, and that alone lets programmers easily and swiftly create cool designs in applications.
    2. JavaFX makes programmers’ life easy by offering “JavaFX scene builder” with which programmers can create GUI controls like buttons via drag and drop.
    3. JavaFX supports Java Lambda expressions in action-triggering events unlike Swing. Using Lambda expressions, JavaFX promotes code readability and just needs fewer lines of code than Swing.
    4. JavaFX has built-in data visualization such as 2D charts
    5. JavaFX 3D API is an awesome API to create 3D objects in creating games or customizing charts in JavaFX.
    6. JavaFX is a good alternative GUI for Android and iOS, meaning JavaFX is portable now. Though JavaFX is not as good as native GUIs, it still performs smoothly on both Android and iOS platforms by using Gluon.
  • Why Desktop Application Development?

    For answer: Click here.

  • What is JavaFx?

    Answer: Click here

    1. Stage
    2. Scenes
    3. Layouts
    4. Controls
  • FXML and Controller classes

    1. Controller classes are only for writing logic of the UI components.
    2. Other classes may be used for other purposes like fetching data from APIs or connecting to a socket.
  • Nomenclature: Click here

    1. Class
    2. Methods
    3. Variables
  • Folder Structure

    • /src/main/java/ - Contains all your java code
    • /src/main/resources/ - Contains your css, images, and fxml files
  • What is Maven? A build automation tool or a package manager Dependencies repository : (https://mvnrepository.com/)

  • Add following line in pom.xml

    <packaging>jar</packaging>
  • Class outcome:

    Calculator in IntelliJ Idea
  • Further readings:

    1. JavaFX 8 docs
    2. Last year JavaFX class resources
    3. Getting started by JavaFX 8 by Oracle
  • Content contributors:

    1. Aritra Chatterjee
    2. Manish Kumar