1

Is there a Kivy alternative in Java?

In the past, I've used Kivy to design cross-platform GUI apps in python. I like Kivy because it's:

  1. Cross-platform. One app runs on Linux, Windows, MacOS, Android, and iOS
  2. Responsive. Apps look good on small phone screens and big desktop screens
  3. Material Design. Native widgets for Material Design UX
  4. Large community. Lots of people use it.

I don't like Kivy because:

  1. Security. Installing python dependencies is extremely insecure.

Unfortunately, I've become disenchanted with the python community because of their disregard for supply-chain security risks. The python package manager (pip) used to have a way for developers to sign their releases with PGP, but the PyPI team has been actively sabotaging & breaking this feature.

As far as I know, Java's Maven is the only programming language that includes a dependency manager that requires all packages to be signed and verifies the cryptographic signature of all dependencies after downloading them and before installing them.

For this reason, I'm looking to migrate from Python to Java for my next GUI project.

While Java is generally sold as being platform-independent, I haven't found any information on getting a cross-platform Java apps to run on Android and iOS (in addition to Linux, Windows, and MacOS).

Is there a kivy alternative for making cross-platform GUI apps in Java?

1 Answer 1

1

If you are willing to use Kotlin in place of Java there is an effort by the language originators to do Kotlin Multiplatform and handle the UI via Kotlin Multiplatform Compose

Pros:

  • Kotlin interoperates with Java
  • After starting with Java, Kotlin was adopted as a first-class language for Android application development in 2017 so there is a base Kotlin community
  • Uses Gradle / Maven style dependency management

Cons:

  • Web and iOS platform bindings are still in development.
  • As Java and Kotlin evolve over time language differences may grow

Side Notes

Kotlin Multiplatform Mobile (KMM) was started to be the platform agnostic business code sharing through to the mobile client leaving only the UI code for the respective native mobile platforms (Android, iOS). The audience for KMM and Kotlin Multiplatform Compose is still relatively new. Given that Web Compose efforts appear to be WASM based rather than HTML/JS, that may or may not be appropriate for your use case. Mobile also places additional restrictions on library code as their APIs are platform specific.

2
  • Does the Kotlin dependency manager require all packages to be cryptographically signed by developers before uploading? Where can I find that documentation? Mar 10 at 4:21
  • Kotlin projects use Gradle, but as to the requirement for signature, it doesn't appear to be on by default, gradle sigature verification Mar 10 at 4:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.