0

Is it possible to create a custom GUI in Java Swing? I’d like my application to be used on multiple operating systems, but I want it to have a custom and I don’t exactly know how to do it. Right now, I’m creating it using JLayeredPane and a bunch of JLabels with icons. It works fine right now, but I’m having trouble making the application resizable(I want it to get bigger so it will be better for larger monitors), and making a progress bar. I know the way I’m doing it is crazy inefficient, but I don’t know what else to do.

I’m also worried that by using so many images will slow down the application and possibly use more resources from the user’s device.

7
  • Can you provide code? It might be best to break your question into two separate questions. Firstly deal with the layout issues here and for the progress bar look here or create another question if that doesnt work for you. Feb 1, 2021 at 3:56
  • I don’t have any code issues, I am just asking if my current method is the best way to make a custom ui for my swing application... I am using JLabels with icons on them, and I don’t think that it is the best way to make a custom ui... Feb 1, 2021 at 3:59
  • The whole UI is literally JLabels with empty values, and icons on them. Feb 1, 2021 at 4:00
  • 2
    Swing and JavaFX are both designed for cross platform development. I strongly recommend you start by looking at Laying Out Components Within a Container. You may also want to look at Modifying the Look and Feel, but personally, I prefer the system look and feel, as it's easier for users to adapt to something they are use to Feb 1, 2021 at 4:01
  • @MadProgrammer I hope to have an option for themes so users can choose how they like it but I wanted to make my own first because personally, I hate the Windows 10 look... I mainly use Linux for that exact reason. Linux is faster as well... Feb 1, 2021 at 4:19

0

Your Answer

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

Browse other questions tagged or ask your own question.