How to get macOS Mojave Style Dark Mode in Java in a Swing Application?

Tags: , ,



I want to know if there is some way to get macOS Mojave style Dark Mode in a swing application in Java?

I want to get macOS Mojave Style Dark Mode on a JFrame in a Java Swing Application.

Please let me know.

Thanks

Asrar Bashir Sunge

Answer

I guess, you might give it a try to use Darcula:

https://github.com/Revivius/nb-darcula

https://github.com/bulenkov/Darcula

import com.bulenkov.darcula.*;
...
...
BasicLookAndFeel darculaLookAndFeel = new DarculaLaf();
try {
  UIManager.setLookAndFeel(darculaLookAndFeel);
} catch (UnsupportedLookAndFeelException ex) {
  // ups!
}

enter image description here



Source: stackoverflow