# JavaFxDemo **Repository Path**: Gatico/java-fx-demo ## Basic Information - **Project Name**: JavaFxDemo - **Description**: javafx ,打包之后可以直接执行的exe - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 1 - **Created**: 2024-06-19 - **Last Updated**: 2024-11-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # HelloFXML A simple Hello World application with Java 11+, JavaFX 15+ (with FXML) and GraalVM. 环境参考这个网站 https://www.graalvm.org/jdk22/docs/getting-started/ 不懂可以联系我QQ:48909084 下载jdk https://www.graalvm.org/downloads-thanks/ 下载mvn插件 https://github.com/graalvm/graalvm-ce-builds/releases 配置JAVA_HOME ![输入图片说明](image.png) 安装mvn插件 gu -L install native-image-installable-svm-java11-windows-amd64-20.2.0.jar ## Documentation Read about this sample [here](https://docs.gluonhq.com/#_hellofxml_sample) ## Quick Instructions We use [GluonFX plugin](https://docs.gluonhq.com/) to build a native image for platforms including desktop, android and iOS. Please follow the prerequisites as stated [here](https://docs.gluonhq.com/#_requirements). ### Desktop Run the application on JVM/HotSpot: mvn gluonfx:run Run the application and explore all scenarios to generate config files for the native image with: mvn gluonfx:runagent Build a native image using: mvn gluonfx:build Run the native image app: mvn gluonfx:nativerun ### Android Build a native image for Android using: mvn gluonfx:build -Pandroid Package the native image as an 'apk' file: mvn gluonfx:package -Pandroid Install it on a connected android device: mvn gluonfx:install -Pandroid Run the installed app on a connected android device: mvn gluonfx:nativerun -Pandroid ### iOS Build a native image for iOS using: mvn gluonfx:build -Pios Install and run the native image on a connected iOS device: mvn gluonfx:nativerun -Pios Create an IPA file (for submission to TestFlight or App Store): mvn gluonfx:package -Pios