I am working on a desktop application using JavaFX, FXMLs (using Scene Builder) and JDBC on IntelliJ IDEA Ultimate. I added Gluon library to the Scene Builder successfully but when I exported the FXML file to IntelliJ it did not recognize the Gluon components, the problem obviously is adding Gluon Library to IntelliJ which I couldn't do. Question is, How to add Gluon library to IntelliJ? I checked several forums and I didn't figure it out.
Asked
Active
Viewed 1,729 times
2
-
https://www.jetbrains.com/help/idea/library.html#define-a-project-library Is this what you are looking for? – b3p0 Feb 20 '20 at 09:28
-
@b3p0 sort of, I'm currently stuck on importing it but I found it through your way – Thorvald Feb 20 '20 at 09:40
-
What exactly are you stuck on? Follow the guide and choose the correct .jar file. There's also a [Gluon plugin for IntelliJ](https://gluonhq.com/the-new-gluon-plugin-for-intellij-idea/) which might help. – b3p0 Feb 20 '20 at 09:46
-
1@b3p0 i imported both `com.gluonhq.charm.down.common.JavaFXPlatform` and `com.gluonhq.charm.down.android.AndroidPlatform` but it still can't recognize the components – Thorvald Feb 20 '20 at 10:46
-
Are you using Maven or Gradle for managing the dependencies? – Boris Feb 20 '20 at 10:48
-
@Boris I am using Maven for this particular project – Thorvald Feb 20 '20 at 11:09
-
Please add the corresponding POM configuration to the question then. – Boris Feb 20 '20 at 11:31
-
@Boris I can't find it in my hierarchy – Thorvald Feb 20 '20 at 11:53
-
Then how did you add Gluon library to the Scene Builder? – Boris Feb 20 '20 at 12:12
-
@Boris I added it through the standalone Scene builder not through IntelliJ, when I save the file as FXML and add it to the project's in IntelliJ it does not recognize "Avatar" and "AutoCompleteTextField" components – Thorvald Feb 20 '20 at 12:15
-
Provide screenshots describing the problem you see. – Andrey Feb 20 '20 at 12:43
1 Answers
3
To use Gluon Mobile classes from the com.gluonhq.charm.glisten.control
package, for example, Avatar and AutoCompleteTextField you have to include the Charm Glisten dependency from the Gluon Nexus repository:
<dependencies>
<dependency>
<groupId>com.gluonhq</groupId>
<artifactId>charm-glisten</artifactId>
<version>6.0.2</version>
</dependency>
</dependencies>
<repositories>
<repository>
<id>gluon-nexus-repository</id>
<url>http://nexus.gluonhq.com/nexus/content/repositories/releases/</url>
</repository>
</repositories>

Boris
- 22,667
- 16
- 50
- 71