Ask Your Question

package javafx.scene.control not found in Fedora 29

asked 2018-11-05 12:19:55 -0500

medeoTL gravatar image

I'm trying to build this code

import javafx.application.Application;
import javafx.scene.Scene;
import javafx.scene.control.Button;
import javafx.scene.control.Label;
import javafx.stage.Stage;

public class ButtonExperiment extends Application  {

    public void start(Stage primaryStage) throws Exception {
        primaryStage.setTitle("HBox Experiment 1");

        Button button = new Button("My Button");

        Scene scene = new Scene(button, 200, 100);


    public static void main(String[] args) {

but I get this error:

package javafx.scene.control does not exist

I'm using openjava 8

[medeo@medeo-E540 ~]$ java -version
openjdk version "1.8.0_181"
OpenJDK Runtime Environment (build 1.8.0_181-b15)
OpenJDK 64-Bit Server VM (build 25.181-b15, mixed mode)

and I think I've installed all the necessari open JavaFX (aka openjfx):

dnf list java*
Last metadata expiration check: 1 day, 8:31:13 ago on Sun 04 Nov 2018 10:38:02 CET.
Installed Packages
java-1.8.0-openjdk.x86_64                                   1:     @updates
java-1.8.0-openjdk-devel.x86_64                             1:     @updates
java-1.8.0-openjdk-headless.x86_64                          1:     @updates
java-1.8.0-openjdk-openjfx.x86_64                           1:     @updates
java-1.8.0-openjdk-openjfx-devel.x86_64                     1:     @updates
java-9-openjdk-headless.x86_64                              1:          @fedora 
java-gnome.x86_64                                           4.1.3-18.fc29              @fedora 
javapackages-filesystem.noarch                              5.3.0-1.fc29               @fedora 
javapackages-tools.noarch                                   5.3.0-1.fc29               @fedora 
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2018-11-17 14:23:05 -0500

bluexin gravatar image

A bug report is filed under

edit flag offensive delete link more

answered 2018-12-04 02:40:25 -0500

medeoTL gravatar image

With recent updates of openjfx (8.0.152 19.b05.fc29) code compile correctly, thanks

edit flag offensive delete link more

Question Tools


Asked: 2018-11-05 12:19:55 -0500

Seen: 370 times

Last updated: Nov 05 '18