How to build desktop app in 2024¶
Initially I have tried to make "Hello, World!" app using:
Electron
- no, it's too complex to work with background worker;Neutralinojs
- no, I have problems with samples compiling and running.
Other possible declined options:
Qt
is not an option, because I do not want to use C++;WinForms/WPF/UWA/UWP
is not an option, because I do not want to return to C#;Tkinter
orPyQt
is not an option because I do not want to use Python for such complex application.
Selected options:
AWT
is OK for first MVP. I already have some examples and small experience with it afterJava: The Complete Reference, Twelfth Edition 12th Edition by Herbert Schildt
;Swing
is "legacy" technology too, but it's OK for me. Some experience and basic examples from book as well. It's good for beginning.
So Swing
. But more knowledge is needed:
- Few free chapters of Java Swing by Robert Eckstein, Marc Loy, Dave Wood;
- 💖 StackOverflow: custom java Swing component Model, UIDelegate, component format - good relevant example of Zoom component for images viewing. Copy-pasted into project and refactored;
- StackOverflow: Proper model-view-controller design - two links to Martin Fowler in answers;
- 👍 Martin Fowler: Presentation Model - it will wait few more questions on StackOverflow;
- 👍 And this article too - Martin Fowler: GUI Architectures;
- Again StackOverflow: Advice welcomed on creating my own Swing component;
- StackOverflow: How to use BigDecimal in swing GUIs? - previous question from the same person;
- StackOverflow: How to determine the correct UI implementation for a custom component
- StackOverflow: Custom Swing component: questions on approach
- StackOverflow: How to add a progress bar?
- StackOverflow: Swing - Update Label - example of SwingWorker;
- StackOverflow: Custom UI in Java Swing - bad question style, links to already discovered questions;
- StackOverflow: custom UI component in java swing - it's really "basic" question;
- StackOverflow: Swing Components with custom UI are not painted correctly;
- StackOverflow: Is it possible to build custom GUI like this in Java? - "Oh dear, no-no-no!";
- Creating a Custom Swing Component - it's waste of time;
- CodeProject: UI Component Development in Java Swing - Part 1: Design - unfortunately, there is only first part;
- 💖 Java.net: How to Write a Custom Swing Component - it's really cool article, some concepts described better in a bit different way, unfortunetely example sources are missed in time;