When I run the getting started example: https://github.com/openjfx/samples/tree/master/HelloFX/Maven from the command line (OpenJDK 11, Maven 3.6.3) everything runs fine. When I open the same project in IntelliJ there is an error:
Error:(1, 26) java: cannot access javafx.application.Application bad class file: C:\Users\xxxxx\.m2\repository\org\openjfx\javafx-graphics\13\javafx-graphics-13-win.jar(javafx/application/Application.class)
class file has wrong version 55.0, should be 52.0
Please remove or make sure it appears in the correct subdirectory of the classpath.
The Maven example in the IDE subfolder https://github.com/openjfx/samples/tree/master/IDE/IntelliJ/Modular/Maven/hellofx runs fine regardless of running from IntelliJ or the command line.
Any ideas why this is? For my own projects I do not want separate versions for the command line and IDE.