JavaFXSmartGraph icon indicating copy to clipboard operation
JavaFXSmartGraph copied to clipboard

Error when using SmartGraph

Open Mohammed-Ryiad-Eiadeh opened this issue 3 years ago • 1 comments

when I use this repository, I got this error, can you help me with that?

the error: "Exception in thread "main" java.lang.ExceptionInInitializerError at com.brunomnsilva.smartgraph.graphview.SmartGraphPanel.addEdge(SmartGraphPanel.java:506) at com.brunomnsilva.smartgraph.graphview.SmartGraphPanel.initNodes(SmartGraphPanel.java:433) at com.brunomnsilva.smartgraph.graphview.SmartGraphPanel.(SmartGraphPanel.java:199) at com.brunomnsilva.smartgraph.graphview.SmartGraphPanel.(SmartGraphPanel.java:163) at com.brunomnsilva.smartgraph.graphview.SmartGraphPanel.(SmartGraphPanel.java:148) at MainClass.Main.main(Main.java:49) Caused by: java.lang.IllegalStateException: Toolkit not initialized at com.sun.javafx.application.PlatformImpl.runLater(PlatformImpl.java:436) at com.sun.javafx.application.PlatformImpl.runLater(PlatformImpl.java:431) at com.sun.javafx.application.PlatformImpl.setPlatformUserAgentStylesheet(PlatformImpl.java:724) at com.sun.javafx.application.PlatformImpl.setDefaultPlatformUserAgentStylesheet(PlatformImpl.java:686) at javafx.scene.control.PopupControl.(PopupControl.java:89) ... 6 more"

Note: I use JDK 17

Mohammed-Ryiad-Eiadeh avatar Jun 06 '23 10:06 Mohammed-Ryiad-Eiadeh

You provide little to no information on how you're using this library.

This is a JavaFX library and uses such components. Are you using the library and running your app as a JavaFX program? I would expect to see the exception thrown like "Exception in Application start method", but I see a simple "Main.main" class in your output.

brunomnsilva avatar Jun 11 '23 22:06 brunomnsilva

Closing issue as the problem seems related to a incorrect javafx environment.

brunomnsilva avatar Apr 03 '24 14:04 brunomnsilva