This is a simple JavaFX Login Form with a TRON like effect. In this example I am using CSS to style the TextField and Button. Here is the snippet of the CSS and Effect code:
.text-field{
-fx-background-color: transparent;
-fx-border-color: #00CCFF;
-fx-text-fill: white;
}
.password-field{
-fx-background-color: transparent;
-fx-border-color: #00CCFF;
-fx-text-fill: white;
}
.button{
-fx-background-color: transparent;
-fx-border-color: white;
-fx-background-radius: 30;
-fx-border-radius: 30;
-fx-text-fill: white;
-fx-font-weight: bold;
-fx-font-size: 14px;
-fx-padding: 10 20 10 20;
}
DropShadow effect = new DropShadow(); effect.setColor(color); effect.setBlurType(BlurType.GAUSSIAN); effect.setSpread(spread); effect.setRadius(radius);
Reference: JavaFX 2 Form from our JCG partner Mark Anro Silva at the GlyphSoft blog.
Do you want to know how to develop your skillset to become a Java Rockstar?
Subscribe to our newsletter to start Rocking right now!
To get you started we give you our best selling eBooks for FREE!
1. JPA Mini Book
2. JVM Troubleshooting Guide
3. JUnit Tutorial for Unit Testing
4. Java Annotations Tutorial
5. Java Interview Questions
6. Spring Interview Questions
7. Android UI Design
and many more ....
I agree to the Terms and Privacy Policy
Thank you!
We will contact you soon.
Tags
JavaFX
👁 Photo of Mark Anro Silva
Mark Anro SilvaApril 4th, 2012Last Updated: October 21st, 2012
Mark Anro SilvaApril 4th, 2012Last Updated: October 21st, 2012
1 110 Less than a minute

This site uses Akismet to reduce spam. Learn how your comment data is processed.
I retired and thought I will keep myself busy by joining a course to do diploma in software development. I was struggling to grasp the concepts in Java and JavaFX since July 2019. This is THE BEST website to learn JavaFX.
Your simple explanation has helped me a lot….