JavaFX Look And Feel for Swing

I played a bit today with JavaFX and one thing that comes straight when using it is the clean UI and Look And Feel. Obviously, since is a modern toolkit, lot of attention has been put in the way things look by default. For example, here’s a simple button:

JFXHelloWorld

I think it looks great. Still being a Swing user, though, I feel often the pain of not having a great looking UI by default. Literally, any time you need to do anything Swing, you end up rewriting most the UI code because it’s so old-fashioned looking.

Today I decided to start a simple experiment then. Instead of writing yet another LookAndFeel from scratch (something that is fun to do, anyway), why not having a Look and Feel based on JavaFX? Here it is:

SwingFX

Well, it’s still pretty bare bone… I even don’t have the nice border yet 🙂 Also, the code is really a complicated mess, given I did everything in an half hour of coding, so I won’t release this yet. But maybe I can really make this a Summer project. What do you think?

Advertisements

5 responses to “JavaFX Look And Feel for Swing

  1. Pingback: Java desktop links of the week, July 22 « Jonathan Giles

  2. I think having a JavaFX look and feel would be great! My first use case would be to switch our legacy Swing application to use that look and feel and to start new developments using JavaFX components, and slowly migrate existing components to JavaFX. Without the look and feel, I don’t think our application is ever going to use JavaFX, which is sad.

  3. This could interesting for us as well. We starting to port our Application from Swing to FX. In the meantime could this solution be nice.

  4. Hi,
    I would like to request if not much asked a simple go through the AwesomeFont use !!
    I’ve been trying to run it for the last 15 hours without any success, so I’m begging for a little help, as if yu’re trying to teach someone that is 5 years old !!
    meaning what to import in my project and what to write in my fxml application !!
    And thx again ^^

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s