[英]How to use the SceneBuilder with IntelliJ on Mac
I'm trying to use the SceneBuilder with IntelliJ on Mac. 我正在尝试在Mac上使用带有IntelliJ的SceneBuilder。 So I downloaded the .dmg file from there http://gluonhq.com/products/downloads/
所以我从那里下载了.dmg文件http://gluonhq.com/products/downloads/
Now I supplied the following path to the SceneBuilder in IntelliJ: 现在我向IntelliJ中的SceneBuilder提供了以下路径:
/Applications/SceneBuilder.app/Contents/MacOS/SceneBuilder
When I tried to open a .fxml
, I get the error 当我尝试打开
.fxml
,我收到错误
Failed to start SceneBuilder:
/Applications/SceneBuilder.app/Contents/MacOS/SceneBuilder/Contents/MacOS/scenebuilder-launcher.sh
It seems like IntelliJ is looking for this sh-script but I have no clue where it is to be honest. 似乎IntelliJ正在寻找这个sh-script,但我不知道诚实的地方。 I have looked over several webpages on the net but no one helped me actually...
我在网上查看了几个网页,但实际上没有人帮我...
So how do I fix my problem or how can use the scene builder in IntelliJ? 那么如何解决我的问题或如何在IntelliJ中使用场景构建器?
Thanks 谢谢
I've solved the problem. 我已经解决了这个问题。
1. First go to: 1.首先去:
Eclipse (Or IntelliJ) -> Preferences -> JavaFX -> Then type/choose "/Applications/SceneBuilder.app" -> Press Ok Eclipse(或IntelliJ) - > Preferences - > JavaFX - >然后输入/选择“/Applications/SceneBuilder.app” - >按Ok
2. Then, go to: 然后,转到:
Applications -> Right click on SceneBuilder -> Click on "Show package contents" --> Contents -> MacOS -> Rename the file "SceneBuilder" as "scenebuilder-launcher.sh" 应用程序 - >右键单击SceneBuilder - >单击“显示包内容” - >目录 - > MacOS - >将文件“SceneBuilder”重命名为“scenebuilder-launcher.sh”
There you go! 你去!
Look at the path it is trying to open.. I suggest you to convert your configured SceneBuilder path to: 看看它试图打开的路径..我建议你将配置好的SceneBuilder路径转换为:
/Applications/SceneBuilder.app/
Edit: Quick fix would be to download the old SceneBuilder 2 here: http://www.oracle.com/technetwork/java/javafxscenebuilder-1x-archive-2199384.html and extract its sh
start script to the correct folder. 编辑:快速解决将是下载老SceneBuilder 2浏览: http://www.oracle.com/technetwork/java/javafxscenebuilder-1x-archive-2199384.html并提取其
sh
启动脚本,以正确的文件夹。
This worked for me. 这对我有用。
Downloaded the .dmg for the Mac at http://gluonhq.com/open-source/scene-builder/ 在http://gluonhq.com/open-source/scene-builder/下载了Mac的.dmg
Install SceneBuilder which will then be located under Applications. 安装SceneBuilder,然后它将位于Applications下。
In IntelliJ 在IntelliJ中
Ensured that the path was correct by going to the following: 通过以下方式确保路径正确:
IntelliJ IDEA -> Preferences -> Languages and Frameworks -> JavaFX IntelliJ IDEA - >首选项 - >语言和框架 - > JavaFX
The value for "Path to SceneBuilder" should be /Applications/SceneBuilder.app “PathBuilder路径”的值应为/Applications/SceneBuilder.app
As per Rilcy88 按照Rilcy88
Renamed SceneBuilder to scenebuilder-launcher.sh under Applications -> Contents -> MacOS. 在应用程序 - >目录 - > MacOS下将SceneBuilder重命名为scenebuilder-launcher.sh。
In the project, I was able to right click on my .fxml file and selected "Open in Scenbuilder" with no problems. 在项目中,我能够右键单击我的.fxml文件并选择“在Scenbuilder中打开”,没有任何问题。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.