8 ms·
follow up question: why does swing use its own special snowflake design, when it could the OS's native design?
by gruez 9y ago
follow up question: why does swing use its own special snowflake design, when it could the OS's native design?
- westoncb 9y agoSwing uses a pluggable 'look and feel' system (essentially themes)—which does include a 'native' look and feel for various OSs, including Windows and macOS.
- AnIdiotOnTheNet 9y agoConsistent look & feel between platforms.
- hota_mazi 9y agoWhich means it sucks and looks weird on all platforms. The story of Swing.
- AnIdiotOnTheNet 9y agoWhich do you care more about: it works, or it looks good? There's a reason Java became such a big platform for business applications and it isn't because it cared about fashion fads.
- hota_mazi 9y ago> There's a reason Java became such a big platform for business applications and it isn't because it cared about fashion fads. There's a reason why Java completely failed on the desktop: Swing. > Which do you care more about: it works, or it looks good? Both. I care about both. And you should too. But Swing developers got used to only being able to have one. At most.
- erikbye 9y agoCompletely failed? JetBrains' IDEs seem awfully popular, and they are all Java and Swing.
- megaman22 9y agoJetbrains IDEs could almost have an NCurses GUI, and they would be worth using. How pretty they are is mostly orthogonal.
- hota_mazi 9y agoCan you name another very popular and very good looking Swing application? Even if you can, you can count them on one hand. Swing was a massive failure, and rightfully so, because Swing/JavaFX apps look, and more importantly, feel, like a broken mess. In contrast, SWT/JFace apps look a lot more native and feel extremely snappy. Apps build on the Eclipse RCP are in general pretty decent looking and they enable all the native controls and functionalities of the host platform.
- AnIdiotOnTheNet 9y ago> Both. I care about both. And you should too. Why? What value is looking good? There's value in a well designed responsive UX, but how it looks is completely meaningless to me because it doesn't help me get shit done.
- outworlder 9y agoIt is not only about looking good. Non-native widgets break user interaction is small but irritating ways. If you are going for non-native widgets, they should at least look good. Otherwise you get the worst of both worlds.
- kuschku 9y agoOr the story of Electron.
- hota_mazi 9y agoBecause Sun made the boneheaded decision (and never admitted it was dumb) to go for emulated widget controls instead of native ones. What this means is that they have had to reimplement and imitate the behavior of native controls on all platforms (realistically, Windows only) every time Microsoft came up with a new version. In contrast, IBM took the native approach with SWT / JFace, and the interfaces written with that library look and feel infinitely more native and performant than Swing and JavaFX ever did and ever will.
- lmz 9y agoThe toolkit based on native widgets existed before Swing. It was called AWT.
- n3dst4 9y agoAWT wasn't native either - it just had one ugly appearance and couldn't be themed. I seem to recall it kind of resembled Sun's CDE (Common Desktop Environment) so it would have look sort of at home on Solaris.
- pvg 9y agoAWT uses native widgets.
- hota_mazi 9y agoAWT isn't native, it uses peers. The fact that Swing ended up being such a massive failure was in good parts due to the fact that Swing is built on top of AWT.