• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

JavaFx worth learning

 
Greenhorn
Posts: 1
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello, is JavaFx worth learning in 2022 I’m a beginner in java programming, is it worth learning JavaFx or should i learn spring or other java framework
 
Ranch Hand
Posts: 49
Firefox Browser Java Windows
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
For me, it's important to have a skill set that a lot of employers are looking for. That's why my vote would be Spring/Spring Boot. But nothing wrong with digging into JavaFX.
 
Bartender
Posts: 5567
213
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi Oscar,

welcome to the Ranch and enjoy the stay!

With hindsight, I think that having some knowlegde of CSS (Cascading StyleSheets) comes in handy when it comes to JavaFX. The GUI is certainly very nice, so if it is for a hobby, then I would say: go for it. My only problem is that JavaFX is even more verbose than Java, but if verbosity is a problem, then don't use Java in the first place.
 
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Depends on what goals you have in mind, honestly.
 
Marshal
Posts: 79978
397
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Oscar Onyenacho wrote:. . . I’m a beginner in java programming, is it worth learning JavaFx or should i learn spring or other java framework

No. Don't learn any of them if you are a beginner. Learn core Java® and object‑oriented programming and the Streams API and the Collections Framework.
Only when you are familiar with those features should you try learning GUIs or Spring, etc.
 
Bartender
Posts: 669
15
TypeScript Fedora
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
No, companies aren't making desktop applications with java
 
Lou Hamers
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yeah Campbell's answer is probably the best one, for someone just starting off. You really need to grasp the fundamentals, and apparently it's easy to forget this once you're past that curve.

Anything UI (web or desktop) has its own learning curve. This is really yet another desktop or web question (which has an "it depends" answer) but it's better to examine that once you've grasped the basics, otherwise you'll probably be frustrated.
 
Rancher
Posts: 326
14
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Al Hobbs wrote:No, companies aren't making desktop applications with java


From experience I have to disagree with this one. In fact: In professional/controlled environments Java is in fact quite often used for both server-side backends as well as client-side front-ends. Over my almost 10 years as customer service agent I worked with a lot of Java based tools, most used Swing as UI framework. There's also quite some middleware integration done with Java - like Java based web-applications running on application servers using JSP.
The reason WHY? In difference to a regular private user in the open internet company networks are managed by central IT department and often only have limited access to the internet (you're supposed to work and get your job done - not browse the internet) - so security is often way tighter than on a private pc and hence the potential security risks implied by using Java and have it run with access to system resources are only limited.

Just for one tool I use daily: ReplyOne by Attensity: It's a Java Swing based e-mail client based around the idea of collaborative work using a shared mailbox. Yes, there're about millions of such solutions out there - but with JavaMailAPI (which is the base for pretty much ANY mailing app for android btw) you can do anything e-mail related with java.
Antoher in-house tool I used to work with was some tech-stuff used internal by 1&1.
There're several other Java-based tools. And these are only the client-side ones I know of and have worked with. Look over at the server-side backends there's a whole lot more based on Java.
 
Al Hobbs
Bartender
Posts: 669
15
TypeScript Fedora
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've never seen any job posting mentioning javafx or swing.  For somebody just starting out, learning javafx or swing is not going to help their career.
 
Piet Souris
Bartender
Posts: 5567
213
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As remarked, we don't know OP's background, so we can only give some points of view.

End of march, I started a course about javascript, with zero previous knowledge. After a month, I had to send in my first assignment, where I had to implement a calculator. They provided a css-file, but the content was completely incomprehensible to me. So I had to put in quite some effort to get the job done. Possibilities are that OP's situation is similar.

I'm currently having a lot of fun with websites where you have to mimick a given webpage, just by creating a suitable css.

Anyway, when I started with java (just for fun, not professionally), around 2011, I found a tutorial that used Swing (from chapter 6) and tought me quite a bit. Nowadays, it uses javafx. Thouroughly recommended. This is the link: David J. Eck
 
Lou Hamers
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Matthew Bendford wrote:

Al Hobbs wrote:No, companies aren't making desktop applications with java


From experience I have to disagree with this one. In fact: In professional/controlled environments Java is in fact quite often used for both server-side backends as well as client-side front-ends.



Thanks for bringing this up (I actually develop and work on one of these unadvertised "back office business desktop applications"). I don't usually argue the point much; it's tiring pushing back against the "every UI has to be in a browser" mindset. It's a shame because desktop applications tend to offer a better experience for complex activities if they're done well. (Unfortunately were some poorly developed Java UIs back when they were more common and that gave the entire platform a bad name.)

I guess web stuff is popular because it's very common that users need to visit, perform some brief simple task, and then leave. Since that's common, web stuff became common, and now we can't deny that desktop development is niche next to building yet another web application. If you're looking to get a job as a developer, you'll have a lot more choices if you're developing a browser thing.

As for JavaFX specifically, I see it used in niche fields like machine learning utilities, visualization and graphics for science applications, back office power-user applications, small-scale indy games, and I think I've seen some blockchain related stuff before.

I also strongly suspect based on this forum that schools tend to use it for assignments a lot. So that would be a possible argument to learn JavaFX early on while you're still in school, once you've grasped the basics of Java first of course. Another argument would be if you want or need a UI for something you're working on alone (if the end product consists of no UI at all), a desktop app makes a hell of a lot more sense than running a local web server or something like that.
 
Sheriff
Posts: 28331
97
Eclipse IDE Firefox Browser MySQL Database
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I looked at the tutorial which Piet posted, and I noticed that it's not until Chapter 6 that it introduces GUI programming.

This is a good thing, because there's a lot of basics which need to be learned before you start learning about GUIs. We don't know about the OP but I'm sure that a lot of beginners search the web and find random JavaFx tutorials which assume (without saying so) that you're already a reasonably competent Java programmer.

This is usually a disaster, because right away you get an error message which you have no clue what it's even talking about. Then you show up on this forum and people start suggesting that you really ought to learn Java basics before diving headfirst into the alligator-infested swamp. So if you're going to learn JavaFx then I agree with Piet regarding tutorials.
 
Lou Hamers
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Clapham wrote:
there's a lot of basics which need to be learned before you start learning about GUIs.



Yeah I think everyone agrees on this point for sure. But I have to confess, there might be some exceptions to that rule from my own experience. Unless my memory from 25-30 years ago is terrible, I remember jumping into UI (or at least graphics) development very quickly, sort of.

I started out on a very visual path when first learning... C/C++ graphics development with a DOS Borland IDE, DJGPP, Allegro, and some books to learn from. I remember my first "IDE" if we can call it that was from a disk that came free with a book. (Not quite one of the old timers punch card stories, I know.)

That's a little different from starting with Java and JFX early on (Java itself I would say is easier to learn, and "UI" for me back then was mostly a DYI activity); but here's the thing: if I didn't have that visual-feedback of cool graphics stuff and interactivity early on, my interest in development may have faded before I got off the ground.

So I'm going to suggest that if you have the aptitude and interest for it and you're a self-starter, starting with UI development very early on (not on day 1 of course) may not be such a bad idea. I'm certain I went through some rounds of the basic non UI learning before I got that far, but it must have been brief because I know I'd have gotten bored, and beyond doing some book-learning, I can't even remember doing it!
 
Rancher
Posts: 517
15
Notepad Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Writing a desktop GUI is much simpler than a web app with GUI (a Spring Boot app). And, it will give you an opportunity to learn about the GUI component layout, the listener methods, the data flow between a database and the user interface - you will need these concepts when you write a web app (and more). Writing a web app would be very challenging if you are newbie - there are more concepts you will need to learn. Once, you get the hang out of the various aspects of GUI programming all the knowledge and concepts come in handy when writing web apps. That said, you can still create a new IDE, or a text editor, or a iTunes like desktop app and that would be fun too.
 
Lou Hamers
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yeah! And who wants to build yet another web app anyway? Boring! Too many of those things! How am I supposed to make nice looking software when we're stuck with all that useless clutter up there?

And what a waste of space the top controls of a browser are for a single page web application. It serves no purpose at all, except to mess the user up when they hit the back button!

A browser is just another (crummy) virtual machine runtime which runs a (crummy) old scripting language that nobody really wants to use. (Don't try to deny it, JavaScripters!) Back in my day, everything was a desktop application. We didn't have any of this HTTP trendy protocol stuff flying around delivering viruses. We installed everything ourselves, from a 3.5" floppy! Or was it a 5.25"?

(Here comes the punch card guy to upstage - there's at least one in every crowd of developers.)

Ahem... yes, learn JavaFX.
 
Paul Clapham
Sheriff
Posts: 28331
97
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Lou Hamers wrote:We installed everything ourselves, from a 3.5" floppy! Or was it a 5.25"?



The 8" floppies could be put into a box which held (I think) 10 of them, and then (if you had the kind of hardware which could work with that box) you could install a considerable amount of data (for those days) into your system.
 
Creator of Enthuware JWS+ V6
Posts: 3412
320
Android Eclipse IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Congratulations Oscar Onyenacho,

Your question has made it to our Journal

Have a Cow!
 
Lou Hamers
Bartender
Posts: 303
12
IntelliJ IDE Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Paul Clapham wrote:

Lou Hamers wrote:We installed everything ourselves, from a 3.5" floppy! Or was it a 5.25"?



The 8" floppies could be put into a box which held (I think) 10 of them, and then (if you had the kind of hardware which could work with that box) you could install a considerable amount of data (for those days) into your system.



Well, not the "punch card guy" I called for, but I didn't even know 8" floppies existed so I think you win the prize.

Yeah I've met and worked with quite a few "punch card guys" - not sure if that's a common thing for others to encounter or maybe I'm just in the right place for it.
 
Paul Clapham
Sheriff
Posts: 28331
97
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Lou Hamers wrote:Well, not the "punch card guy" I called for, but I didn't even know 8" floppies existed so I think you win the prize.



I did use punch cards, but that was back when I was in university. I used them both for class and for a summer job.

20220910_193132.jpg
8" floppy
8" floppy
 
Greenhorn
Posts: 3
2
  • Likes 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There's much you learn using JavaFX that translates to other languages and frameworks so the experience learning it may make sense if you have the time. I recommend you create a UI for something that you really, really like and  learn how it's done in JavaFX. I recommend visiting the gluonhq.com and get scenebuilder; many more resources there. I recommend the books "Learn JavaFX 17: Building User Experience and Interfaces with Java Building User Experience and Interfaces with Java" (Sharan/Späth) and "The Definitive Guide to Modern Java Clients with JavaFX 17: Cross-Platform Mobile and Cloud Development Cross-Platform Mobile and Cloud Development" (several authors). I'm not done going through those since I'm learning as time permits. I like aviation and been putting together a UI to display aircraft location signals. I used the Gluon Maps framework (it's very good); it uses OpenStreetMap in turn. Good luck!
demo.png
[Thumbnail for demo.png]
 
Paul Clapham
Sheriff
Posts: 28331
97
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Rick Mediavilla wrote:I recommend you create a UI for something that you really, really like and  learn how it's done in JavaFX.



Yes! Excellent advice! (It's what I did to get started with Swing a long time ago.) I gave you a cow for it.
 
Rick Mediavilla
Greenhorn
Posts: 3
2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
My first cow! Thanks!
 
Bartender
Posts: 209
14
Mac OS X IntelliJ IDE
  • Likes 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
JavaFx might not be very popular when you look at jobs ads but it's quite nice to use and, as somebody has mentioned, the skills are transferable. That said, you can make super cool command line apps and tools too, one of my first projects when I first started learning Java was a MUD game (basically a text-based MMORPG). It was quite rubbish but I learned a lot in the process (Java, design patterns, networking).
Don't touch Spring or any other web framework until you cover the basics of not just Java but also boring stuff (like HTTP).
 
Marshal
Posts: 8969
646
Mac OS X Spring VI Editor BSD Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
@OP

Welcome to the Ranch.

Anything you learn is a step forward (and not backwards). Glad you found this forum by the way.

 
Liutauras Vilda
Marshal
Posts: 8969
646
Mac OS X Spring VI Editor BSD Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Oscar, cowgratulations, your topic has been published in our CodeRanch monthly journal: https://coderanch.com/wiki/754594/CodeRanch-Journal-September
 
Greenhorn
Posts: 2
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Matthew Bendford wrote:

Al Hobbs wrote:No, companies aren't making desktop applications with java


From experience I have to disagree with this one. In fact: In professional/controlled environments Java is in fact quite often used for both server-side backends as well as client-side front-ends. Over my almost 10 years as customer service agent I worked with a lot of Java based tools, most used Swing as UI framework. There's also quite some middleware integration done with Java - like Java based web-applications running on application servers using JSP.
The reason WHY? In difference to a regular private user in the open internet company networks are managed by central IT department and often only have limited access to the internet (you're supposed to work and get your job done - not browse the internet) - so security is often way tighter than on a private pc and hence the potential security risks implied by using Java and have it run with access to system resources are only limited. We also developed various sports betting apps and were assisted by Cogniteq, as we lacked experience with such topics.

Just for one tool I use daily: ReplyOne by Attensity: It's a Java Swing based e-mail client based around the idea of collaborative work using a shared mailbox. Yes, there're about millions of such solutions out there - but with JavaMailAPI (which is the base for pretty much ANY mailing app for android btw) you can do anything e-mail related with java.
Antoher in-house tool I used to work with was some tech-stuff used internal by 1&1.
There're several other Java-based tools. And these are only the client-side ones I know of and have worked with. Look over at the server-side backends there's a whole lot more based on Java.

 We once developed a system for a company where security was critical. Limited internet access and strict security rules meant that Java, with its ability to strictly isolate and control access to system resources, was an ideal choice. As a result, we were able to ensure reliable and secure operation of the application in a corporate environment.

Java is truly a great fit for professional environments where high reliability and security are required. Experience with Java, including the use of technologies such as JavaMailAPI, shows that it is a powerful tool for creating both client and server applications.
 
Campbell Ritchie
Marshal
Posts: 79978
397
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
DL: Welcome to the Ranch
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you're just starting out with Java, JavaFX can be a great way to learn GUI development and get a feel for building desktop applications. However, if you're more interested in web development or building scalable apps, Spring might be a better long-term investment. It really depends on what kind of projects you want to work on—JavaFX is great for UI, while Spring is more focused on backend and web apps. Both are valuable, but your goals will guide your choice!
 
Campbell Ritchie
Marshal
Posts: 79978
397
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
TG, welcome to the Ranch
 
catch it before it slithers away! Oh wait, it's a tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic