scalafx.application

Type members

Classlikes

Contains implicit methods to convert from `javafx.application` Classes to their ScalaFX counterparts.

Contains implicit methods to convert from `javafx.application` Classes to their ScalaFX counterparts.

Companion
object
sealed abstract class ConditionalFeature(val delegate: ConditionalFeature) extends SFXEnumDelegate[ConditionalFeature]
Companion
object
object HostServices
Companion
class
class HostServices(val delegate: HostServices) extends SFXDelegate[HostServices]

This class provides HostServices for an Application. This includes methods to get the code base and document base for an Application, show a web page in a browser, and communicate with the enclosing web page using JavaScript if the Application is running in a browser.

This class provides HostServices for an Application. This includes methods to get the code base and document base for an Application, show a web page in a browser, and communicate with the enclosing web page using JavaScript if the Application is running in a browser.

Wraps a JavaFX HostServices.

Companion
object
object JFXApp
Companion
class
object JFXApp3
Companion
class
trait JFXApp3

ScalaFX applications can extend JFXApp3 to create properly initialized JavaFX applications.

ScalaFX applications can extend JFXApp3 to create properly initialized JavaFX applications.

On the back end JFXApp3 first calls javafx.application.Application.launch then executes body of its constructor when javafx.application.Application.start(primaryStage:Stage) is called. Here is an example use:

 object SimpleScalaFXApp extends JFXApp3 {
   override def start() : Unit = {
     stage = new PrimaryStage {
       title = "Simple ScalaFX App"
       scene = new Scene {
         root = new StackPane {
           padding = Insets(20)
           content = new Rectangle {
             width = 200
             height = 200
             fill = Color.DEEPSKYBLUE
           }
         }
       }
     }
   }
 }
Companion
object
object Platform

Application platform support, wrapper for javafx.application.Platform.

Application platform support, wrapper for javafx.application.Platform.

Deprecated classlikes

@deprecated("`JFXApp` depends on `DelayedInit` that is deprecated since Scala 2.11.0 and no longer works in Scala 3. Use `JFXApp3` instead.", since = "16.0.0-R23")
trait JFXApp extends DelayedInit

ScalaFX applications can extend JFXApp to create properly initialized JavaFX applications.

ScalaFX applications can extend JFXApp to create properly initialized JavaFX applications.

On the back end JFXApp first calls javafx.application.Application.launch then executes body of its constructor when javafx.application.Application.start(primaryStage:Stage) is called. Here is an example use:

 object SimpleScalaFXApp extends JFXApp {
    stage = new PrimaryStage {
      title = "Simple ScalaFX App"
      scene = new Scene {
        root = new StackPane {
          padding = Insets(20)
          content = new Rectangle {
            width = 200
            height = 200
            fill = Color.DEEPSKYBLUE
          }
        }
      }
    }
 }
Companion
object
Deprecated
[Since version 16.0.0-R23]

JFXApp depends on DelayedInit that is deprecated since Scala 2.11.0 and no longer works in Scala 3. Use JFXApp3 instead.